|
JCAT v0.3.1 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A JcatTerminalConnection object maintains a state that reflects the relationship between a JcatTerminal and a JcatConnection. A JcatTerminalConnection object state is distinct from the JcatConnection object states. The JcatConnection object states describe the relationship between an entire JcatAddress endpoint and a JcatCall, whereas the JcatTerminalConnection state describes the relationship between one of the JcatTerminal objects at the endpoint JcatAddress on the JcatCall with respect to its JcatConnection. Different JcatTerminals on a JcatCall, which are associated with the same, JcatConnection may be in different states. Furthermore, the state of the JcatTerminalConnection has a dependency and specific relationship to the state of its JcatConnection.
The TerminalConnection object has the following states:
IDLE | This state is the initial state for a JcatTerminalConnection object. A JcatTerminalConnection object does not stay in the IDLE state for long, quickly transitioning to other states. |
RINGING | This state indicates the JcatTerminal is ringing and that the JcatTerminal has an incoming call. |
DROPPED |
This state indicates that a particular JcatTerminal has permanently left the call. When a JcatTerminalConnection object moves into the DROPPED state, it is no longer associated with its JcatConnection and JcatTerminal objects. That is, both of these objects lose their references to the JcatTerminalConnection. However, the JcatTerminalConnection still maintains its references to the JcatConnection and JcatTerminal object for application reference. |
BRIDGED |
This state indicates that a JcatTerminal is currently bridged into a Call. A JcatTerminal may typically join a JcatCall when it is bridged. A bridged JcatTerminal is part of the call, but not active. Typically, some hardware resource is occupied while a JcatTerminal is bridged into a JcatCall. |
TALKING |
This state indicates that the JcatTerminal is actively part of a JcatCall, is typically "off-hook", and the party is communicating on the call. |
INUSE |
This state indicates that a JcatTerminal hardware resource is currently in use. The terminal is not available for the JcatCall associated with this JcatTerminalConnection, that is the JcatTerminal may not join the call. This state is similar to the BRIDGED state except that the JcatTerminal may not join the JcatCall. |
HELD |
This state indicates that a JcatTerminal is part of a JcatCall, but is on hold. Other JcatTerminal objects, which are on the same JcatCall and associated with the same JcatConnection may or may not also be in this state. |
JcatConnection State | JcatTerminalConnectionState |
JccConnection.IDLE |
Zero or more JcatTerminalConnection objects may exist for this JcatConnection,
and each must be in the IDLE state.
|
JccConnection.AUTHORIZE_CALL_ATTEMPT , JccConnection.ADDRESS_COLLECT ,
JccConnection.ADDRESS_ANALYZE , JccConnection.CALL_DELIVERY |
Zero or more JcatTerminalConnection objects may exist for this JcatConnection,
and each must be in the IDLE state.
|
JccConnection.ALERTING |
Zero or more JcatTerminalConnections may exist for this JcatConnection, and each
must be in the RINGING state.
|
JccConnection.CONNECTED |
Zero or more JcatTerminalConnections may exist for this JcatConnection, and each must
be in the BRIDGED or INUSE state (passive) or in the TALKING
or HELD (active) state. Note that when JcatTerminalConnections transition into
the DROPPED state they are no longer associated with the JcatConnection.
|
JccConnection.FAILED |
No TerminalConnections may exist for this Connection. Note that all TerminalConnections
previously associated with this Connection will move into the DROPPED state.
|
JcatConnection.SUSPENDED |
Zero or more JcatTerminalConnections may exist for this JcatConnection, and each must be
in the HELD state.
|
JccConnection.DISCONNECTED |
Zero or more JcatTerminalConnections may exist for this JcatConnection, and each must be
in the DROPPED state.
|
Field Summary | |
static int |
BRIDGED
This state indicates that a JcatTerminal is currently bridged into a Call. |
static int |
DROPPED
This state indicates that a particular JcatTerminal has permanently left the call. |
static int |
HELD
This state indicates that a JcatTerminal is part of a JcatCall, but is on hold. |
static int |
IDLE
This state is the initial state for a JcatTerminalConnection object. |
static int |
INUSE
This state indicates that a JcatTerminal hardware resource is currently in use. |
static int |
RINGING
This state indicates the JcatTerminal is ringing and that the JcatTerminal has an incoming JcatCall. |
static int |
TALKING
This state indicates that the JcatTerminal is actively part of a JcatCall. |
Method Summary | |
void |
answer()
Answers an incoming telephone call on this Terminal Connection. |
JcatConnection |
getConnection()
Returns the JcatConnection object associated with this JcatTerminalConnection. |
int |
getState()
Returns the state of the JcatTerminalConnection object. |
JcatTerminal |
getTerminal()
Returns the JcatTerminal associated with this JcatTerminalConnection object. |
void |
hold()
Places a JcatTerminalConnection on hold with respect to the JcatCall of which it is a part. |
void |
join()
Makes a currently bridged JcatTerminalConnection active on a JcatCall. |
void |
leave()
Places a currently active JcatTerminalConnection in a bridged state on a JcatCall. |
void |
unhold()
Takes a JcatTerminalConnection off hold with respect to the JcatCall of which it is a part. |
Field Detail |
public static final int IDLE
public static final int RINGING
public static final int DROPPED
public static final int BRIDGED
public static final int TALKING
public static final int INUSE
public static final int HELD
Method Detail |
public void answer()
TALKING
.
RINGING
state when this operation
is invoked. This implies that the associated Connection object is in the
JccConnection.ALERTING
state. There may be more than one Terminal
Connection on the Connection which are in the RINGING state.
BRIDGED
or INUSE
state or the DROPPED
state. If a Terminal
Connection moves into the BRIDGED or INUSE state, it remains part of the telephone
call, but not actively so. It may have the ability to join the call in the
future. If a Terminal Connection moves into the DROPPED state, it is removed from
the telephone call. The appropriate events are delivered to the application indicates
into which of these two states the other Terminal Connection objects have moved.
JcatTerminalConnectionListener
and JccConnectionListener
interface as a result of the successful outcome of this operation:
JcatTerminalConnectionEvent.TERMINALCONNECTION_TALKING
for the
Terminal Connection which invoked this operation.
JccConnectionEvent.CONNECTION_CONNECTED
for the Connection
associated with the Terminal Connection.
JcatTerminalConnectionEvent.TERMINALCONNECTION_BRIDGED
,
JcatTerminalConnectionEvent.TERMINALCONNECTION_INUSE
or
JcatTerminalConnectionEvent.TERMINALCONNECTION_DROPPED
for other
Terminal Connections associated with the Connection.
public JcatConnection getConnection()
public int getState()
public JcatTerminal getTerminal()
public void hold() throws InvalidStateException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
TALKING
state. This operation returns when the Terminal
Connection has moved to the HELD
state, or until an error occurs and
an exception is thrown.
InvalidStateException
MethodNotSupportedException
PrivilegeViolationException
ResourceUnavailableException
JcatCall
public void join() throws InvalidStateException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
BRIDGED
state. This operation
returns when the JcatTerminalConnection has moved to the TALKING
state or until an error occurs and an exception is thrown.
InvalidStateException
MethodNotSupportedException
PrivilegeViolationException
ResourceUnavailableException
JcatCall
public void leave() throws InvalidStateException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
TALKING
state. There are two
possible outcomes of this operation depending upon the number of remaining, active
JcatTerminalConnection objects on the Call. If there are other active terminal
connections, then this JcatTerminalConnection moves into the BRIDGED
state and this operation returns. If there are no other active
JcatTerminalConnection objects, then this JcatTerminalConnection moves into the
DROPPED
state. Its associated JcatConnection moves into the
JccConnection.DISCONNECTED
state, i.e. the entire endpoint leaves the
telephone call. This operation waits until one of these two outcomes occurs or
until an error occurs and an exception is thrown.
InvalidStateException
MethodNotSupportedException
PrivilegeViolationException
ResourceUnavailableException
public void unhold() throws InvalidStateException, MethodNotSupportedException, PrivilegeViolationException, ResourceUnavailableException
HELD
state. This operation returns successfully when the
JcatTerminalConnection moves into the TALKING
state or until an error occurs
and an exception is thrown.
InvalidStateException
MethodNotSupportedException
PrivilegeViolationException
ResourceUnavailableException
|
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