|
JCAT v0.3.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A JcatCall object extends the JccCall object . It provides advanced features such as
transfer, conference etc. The JcatCall object has the same finite state machine as the
JccCall
object.
Field Summary |
Fields inherited from interface javax.csapi.cc.jcc.JccCall |
ACTIVE, IDLE, INVALID |
Method Summary | |
void |
addTerminalConnectionListener(JcatTerminalConnectionListener termconnlistener)
Adds a JcatTerminalConnectionListener to the call. |
JcatConnection |
blindTransfer(java.lang.String dialledDigits)
This method transfers all participants currently on this Call, with the exception of the transfer controller participant, to another telephone address. |
void |
conference(JcatCall othercall)
Merges two JcatCalls together, resulting in the union of the participants of both calls being placed on a single JcatCall. |
JcatConnection[] |
connect(JcatTerminal term,
JcatAddress addr,
java.lang.String dialedDigits)
Places a telephone call from an originating endpoint to a destination address string. |
JcatConnection[] |
consult(JcatTerminalConnection termconn,
java.lang.String dialedDigits)
Creates a consultation between this idle JcatCall and an active JcatCall. |
void |
consultTransfer(JcatCall otherCall)
This method moves all participants from one JcatCall to another, with the exception of a selected common participant. |
JcatTerminalConnection |
getConferenceController()
Returns the JcatTerminalConnection which currently acts as the conference controller. |
boolean |
getConferenceEnable()
Return true if conferencing is enabled, false otherwise. |
JcatTerminalConnection |
getTransferController()
Returns the JcatTerminalConnection which currently acts as the transfer controller. |
boolean |
getTransferEnable()
Return true if transferring is enabled, false otherwise. |
void |
removeTerminalConnectionListener(JcatTerminalConnectionListener terminalConnectionListener)
Removes the terminal connection listener. |
void |
setConferenceController(JcatTerminalConnection tc)
Sets the JcatTerminalConnection which acts as the conference controller
for the JcatCall. |
void |
setConferenceEnable(boolean enabled)
Controls whether the JcatCall is permitted or able to perform the conferencing feature. |
void |
setTransferController(JcatTerminalConnection termconn)
Sets the JcatTerminalConnection which acts as the transfer controller for the JcatCall. |
void |
setTransferEnable(boolean enable)
Controls whether the JcatCall is permitted or able to perform the transferring feature. |
Methods inherited from interface javax.csapi.cc.jcc.JccCall |
addCallListener, addConnectionListener, connect, createConnection, getConnections, getProvider, getState, release, removeCallListener, removeConnectionListener, routeCall, superviseCall |
Method Detail |
public void addTerminalConnectionListener(JcatTerminalConnectionListener termconnlistener) throws MethodNotSupportedException, ResourceUnavailableException
JcatTerminalConnectionListener
to the call.
termconnlistener
- the JcatTerminalConnectionListener to be added to the call.
MethodNotSupportedException
- The implementation does not support this method.
ResourceUnavailableException
- The resource limit for the number of
listeners has been exceeded.public JcatConnection blindTransfer(java.lang.String dialledDigits) throws InvalidArgumentException, InvalidStateException, InvalidPartyException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
JcatTerminalConnection
which must be in the
JcatTerminalConnection.TALKING
state. Applications may control which JcatTerminalConnection
acts as the transfer controller via the setTransferController(JcatTerminalConnection)
method.
If no transfer controller is set, the implementation chooses a suitable JcatTerminalConnection when
the transfer feature is invoked. When the transfer feature is invoked, the transfer controller moves
into the JcatTerminalConnection.DROPPED
state. If it is the only JcatTerminalConnection
associated with its JcatConnection, then its JcatConnection moves into the
JccConnection.DISCONNECTED
state as well.
JccConnection.IDLE
before
this method returns, appropriate events should reflect this. This new JcatConnection will progress
as any normal destination JcatConnection on a telephone call.
Pre-Conditions:
Post-Conditions:
dialledDigits
- The destination telephone address string to where the Call is being transferred.
InvalidArgumentException
- The JcatTerminalConnection provided as controlling the transfer is
not valid or part of this JcatCall.
InvalidStateException
- Either the JcatProvider is not JccProvider.IN_SERVICE
, the
JcatCall is not JccCall.ACTIVE
, or the transfer controller is not JcatTerminalConnection.TALKING
.
InvalidPartyException
- The destination address is not valid and/or complete.
MethodNotSupportedException
- This method is not supported by the implementation.
PrivilegeViolationException
- The application does not have the proper authority to invoke this method.
ResourceUnavailableException
- An internal resource necessary for the successful invocation of this
method is not available.public void conference(JcatCall othercall) throws InvalidArgumentException, InvalidStateException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
JcatTerminalConnection.HELD
state. The two conference
controlling JcatTerminalConnections are merged into one as a result of this method.
Applications may control which JcatTerminalConnection acts as the conference controller via
the setConferenceController(JcatTerminalConnection)
method. If no conference
controller is set, the implementation chooses a suitable JcatTerminalConnection when the
conferencing feature is invoked.
JccCall.INVALID
state.
The conference controller terminalConnections are merged into one on this JcatCall. That is,
the existing terminalConnection controller on this JcatCall is left unchanged, while the
terminalConnection on the second JcatCall is removed from that JcatCall.
Pre-Conditions:
Post-Conditions:
othercall
- - The JcatCall which is to be merged with the existing JcatCall.
InvalidArgumentException
- - The JcatTerminalConnection provided (implicitly) as controlling the transfer is not valid or part of this Call.
InvalidStateException
- - One of the objects is not in the prescribed state.
MethodNotSupportedException
- - This method is not supported by the implementation.
PrivilegeViolationException
- - The application does not have the proper authority to invoke this method.
ResourceUnavailableException
- - An internal resource necessary for the successful invocation of this method is not available.public JcatConnection[] connect(JcatTerminal term, JcatAddress addr, java.lang.String dialedDigits) throws ResourceUnavailableException, PrivilegeViolationException, InvalidPartyException, InvalidStateException, MethodNotSupportedException
JccCall.IDLE
state (and therefore have no existing associated
connections. The successful effect of this method is to place the telephone call and
create and return at most two connections associated with this call.
JcatAddress.getTerminals()
and the originating terminal must appear on the
address (via JcatTerminal.getAddresses()
). If not, an InvalidArgumentException
is thrown. The third argument is a destination string whose value represents the
address to which the telephone call is placed.
term
- originating terminal for the telephone call.addr
- The originating Address for this call.dialedDigits
- The destination address string for this call.
ResourceUnavailableException
- An internal resource necessary for placing
the call is unavailable.
PrivilegeViolationException
- The application does not have the proper
authority to place a call.
InvalidPartyException
- Either the originator or the destination does not
represent a valid party required to place a call.
InvalidStateException
- Some object required by this method is not in a valid
state as designated by the pre-conditions for this method.
MethodNotSupportedException
- The implementation does not support this method.public JcatConnection[] consult(JcatTerminalConnection termconn, java.lang.String dialedDigits) throws InvalidArgumentException, InvalidPartyException, InvalidStateException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
JccCall.IDLE
state which is associated with a particular
existing JcatCall and often created for a particular purpose. For example, the
consultation JcatCall may be used simply to "consult" with another party or to
conference or transfer with its associated JcatCall. This method establishes a special
relationship between the two JcatCalls which extends down to the telephony platform
level. Most often, this feature is directly provided by the underlying telephony platform.
JccCall.IDLE
state.
JccCall.ACTIVE
state. The second piece of information given by the
JcatTerminalConnection argument is the originating endpoint from which to place a
telephone call on this idle JcatCall.
In other words, the JcatAddress and JcatTerminal associated with the JcatTerminalConnection
argument are used as the originating endpoint for the telephone call. The state of the
JcatTerminalConnection must be JcatTerminalConnection.TALKING
and this method first
moves it into the JcatTerminalConnection.HELD
in order to place a telephone call on
this idle call.
connect(JcatTerminal,JcatAddress,String)
method.
termconn
- originating terminal for the telephone call.dialedDigits
- The destination address string for this call.
InvalidArgumentException
- The JcatTerminalConnection provided as controlling the
transfer is not valid or part of this call.
InvalidStateException
- Some object required by this method is not in a valid state
as designated by the pre-conditions for this method.
InvalidPartyException
MethodNotSupportedException
- This method is not supported by the implementation.
PrivilegeViolationException
- The application does not have the proper authority to
invoke this method.
ResourceUnavailableException
- An internal resource necessary for the successful
invocation of this method is not available.public void consultTransfer(JcatCall otherCall) throws InvalidArgumentException, InvalidPartyException, InvalidStateException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
JcatTerminalConnection.TALKING
or JcatTerminalConnection.HELD
state.
Applications may control which JcatTerminalConnection acts as the transfer controller via the
setTransferController(JcatTerminalConnection)
method. If no transfer controller is set,
the implementation chooses a suitable JcatTerminalConnection when the transfer feature is invoked.
JccCall.INVALID
state.
The transfer controller JcatTerminalConnections are dropped from both Calls. They move into the
JcatTerminalConnection.DROPPED
state.
Pre-Conditions:
Post-Conditions:
otherCall
- - The other JcatCall which to transfer to this JcatCall.
InvalidArgumentException
- The JcatTerminalConnection controlling the transfer is not valid or does not exist or the other call is not valid.
InvalidStateException
- Either the provider is not "in service", the Call is not "active", or the transfer controllers are not "talking" or "held".
InvalidPartyException
- The other Call given as the argument is not a valid Call to conference with.
MethodNotSupportedException
- This method is not supported by the implementation.
PrivilegeViolationException
- The application does not have the proper authority to invoke this method.
ResourceUnavailableException
- An internal resource necessary for the successful invocation of this method is not available.public JcatTerminalConnection getConferenceController()
When a JcatCall is initially created, the conference controller is set to null. This method returns non-null only if the application has previously set the conference controller. If the current conference controller leaves the JcatCall, the conference controller is reset to null.
public boolean getConferenceEnable()
setConferenceEnable(boolean)
method.
public JcatTerminalConnection getTransferController()
When a JcatCall is initially created, the transfer controller is set to null. This method returns non-null only if the application has previously set the transfer controller. If the current transfer controller leaves the telephone call, the transfer controller is reset to null.
public boolean getTransferEnable()
public void removeTerminalConnectionListener(JcatTerminalConnectionListener terminalConnectionListener)
JcatTerminalConnectionEvent.TERMINALCONNECTION_EVENT_TRANSMISSION_ENDED
is the last
event sent on this listener.
terminalConnectionListener
- listener to be addedpublic void setConferenceController(JcatTerminalConnection tc) throws InvalidArgumentException, InvalidStateException, MethodNotSupportedException, ResourceUnavailableException
JcatTerminalConnection
which acts as the conference controller
for the JcatCall. The conference controller represents the participant in the
JcatCall around which a conference takes place.
Typically, when two JcatCalls are conferenced together, a single participant is
part of both JcatCalls. This participant is represented by a JcatTerminalConnection
on each JcatCall, each of which shares the same JcatTerminal. If the designated
JcatTerminalConnection is not part of this JcatCall, exception InvalidArgumentException
is thrown.
If the JcatTerminalConnection leaves the JcatCall in the
future, the implementation resets the conference controller to null.
tc
- the JcatTerminalConnection to set as the conference controller.
InvalidArgumentException
- The TerminalConnection controlling the transfer is not valid or does not exist or the other Call is not valid.
InvalidStateException
- Either the Provider is not "in service", the Call is not "active", or the transfer controllers are not "talking" or "held".
MethodNotSupportedException
- This method is not supported by the implementation.
ResourceUnavailableException
- An internal resource necessary for the successful invocation of this method is not available.public void setConferenceEnable(boolean enabled) throws InvalidArgumentException, InvalidStateException, MethodNotSupportedException, ResourceUnavailableException
JccCall.IDLE
state.
Setting this parameter is a "request"; the call will be routed such that a resource capable of conferencing is part of the path. Note that this does not mean that three party calls are not supported if ConferenceEnable=false since we consider a conference to be call with more than three parties.
enabled
- set to true or false depending on whether conferencing feature is enabled or not.
InvalidArgumentException
- - The TerminalConnection controlling the transfer is not valid or does not exist or the other Call is not valid.
InvalidStateException
- - Either the Provider is not "in service", the Call is not "active", or the transfer controllers are not "talking" or "held".
MethodNotSupportedException
- - This method is not supported by the implementation.
ResourceUnavailableException
- - An internal resource necessary for the successful invocation of this method is not available.public void setTransferController(JcatTerminalConnection termconn) throws InvalidArgumentException, InvalidStateException, MethodNotSupportedException, ResourceUnavailableException
termconn
- JcatTerminalConnection to set as the transfer controller.
InvalidArgumentException
- - The TerminalConnection controlling the transfer is not valid or does not exist or the other Call is not valid.
InvalidStateException
- - Either the Provider is not "in service", the Call is not "active", or the transfer controllers are not "talking" or "held".
MethodNotSupportedException
- - This method is not supported by the implementation.
ResourceUnavailableException
- - An internal resource necessary for the successful invocation of this method is not available.public void setTransferEnable(boolean enable) throws InvalidArgumentException, InvalidStateException, MethodNotSupportedException, ResourceUnavailableException
JccCall.IDLE
state.
enable
- true/false depending on whether transferring feature is enabled.
InvalidArgumentException
- - The TerminalConnection controlling the transfer is not valid or does not exist or the other Call is not valid.
InvalidStateException
- - Either the Provider is not "in service", the Call is not "active", or the transfer controllers are not "talking" or "held".
MethodNotSupportedException
- - This method is not supported by the implementation.
ResourceUnavailableException
- - An internal resource necessary for the successful invocation of this method is not available.
|
JCAT v0.3.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright - 2001, 2003 Sun Microsystems