Call States
The CloudonixCallState_e
enum is used to report the state of the call, for example as passed to the onCallState()
event listener. The following list enumerates the possible call state values and how they should be handled:
CallState_Starting
- The initial event sent when a call is created by calling thedial()
method. The client should record the call ID (“key”) to enable future operations on the call in progress.CallState_Calling
- An outgoing call has started after calling adial()
method.CallState_Incoming
- An incoming call was detected. The client should record the call ID (“key”) to enable future operations on the call in progress, and show the incoming call screen.CallState_Connecting
- A call (either incoming or outgoing) is in the process of being answered.CallState_Ringing
- The outgoing call is ringing on the remote side.. No early media (ringing tone) is received from the remote side, so the application should emulate a ring-back tone to the user. Please note thatCallState_Ringing
andCallState_Early
have no particular order - depending on the server configuration,CallState_Early
may be received before or afterCallState_Ringing
and the application should make sure to only emulate ring-back ifCallState_Ringing
is received beforeCallState_Early
and only untilCallState_Early
orCallState_Confirmed
is received.CallState_Early
- The outgoing call is ringing on the remote side and early media (ringing tone) is being played from the remote side. If the application is emulating a ring-back tone, it should stop playing that now.CallState_Confirmed
- The call is fully connected. The client should change the UI from “call is trying to connect” to “call is connected”. Also after this event the SDK will send any DTMF signals queued and allow the user to send new DTMF signals.CallState_LocalHold
- The call is now on hold by the user. The client should change the UI to let the user know that the call is “on hold”.CallState_RemoteHold
- The call is now on hold by the remote end. The client should change the UI to let the user know that the call is “on hold”.CallState_LocalRemoteHold
- The call is now on hold by both the user and the remote end. The client should change the UI to let the user know that the call is “on hold”.CallState_MediaActive
- The call that was on hold is now no longer on hold. The client should change the UI to let the user know that the call is no longer “on hold”.CallState_Media_Disrupted
- The SDK has detected that call media has not been received for at least a second. When media is resumed, the SDK will sendCallState_MediaActive
.CallState_Renewing_Media
- The call media is being renewed by the SDK, either by resetting the media after a long disruption (as controller by theMEDIA_RESET_TIMEOUT
configuration flag) or during an IP address change.CallState_Disconnected
- A call in progress was disconnected. The client should call hangup() on the call represented by the submitted key, hide any call UI and forget about the current call ID.CallState_DisconnectedMediaChanged
- A call in progress disconnected due to failing to change media codecs. SeeCallState_Disconnected
.CallState_DisconnectedDueToBusy
- A call in progress failed to connect due to busy signal. SeeCallState_Disconnected
.CallState_DisconnectedDueToNetworkChange
- A call in progress failed to connect due to network change on the client before connecting. SeeCallState_Disconnected
.CallState_DisconnectedDueToNoMedia
- A call in progress disconnected due missing media from the remote, or failure to reconnect the media after media loss. SeeCallState_Disconnected
.CallState_DisconnectedDueToTimeout
- A call in progress disconnected due to session timeout, likely caused by network failure. SeeCallState_Disconnected
.