|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object OEM com.motorola.oem.call.Call
public class Call
The Call class is used for organization and management of MO/MT voice and data calls.
Note: This class is implemented as a singleton and is accessible by the static method: getInstance()
.
Field Summary | |
---|---|
static int |
CALL_DIRECTION_MO
Current call direction - Outgoing(Mobile Originated) |
static int |
CALL_DIRECTION_MT
Current call direction - Incoming(Mobile Terminated) |
static int |
CALL_SESSION_TABLE_ERROR
Current data call profile failure. |
static int |
CALL_STATE_ACTIVE
Current call state - Active |
static int |
CALL_STATE_ALERTING
Current call state - Alerting |
static int |
CALL_STATE_CONNECTING
Current call state - Connecting |
static int |
CALL_STATE_IDLE
Current call state - Idle |
static int |
CALL_STATE_RELEASING
Current call state - Releasing |
static int |
CALL_STATE_UNKNOWN
Current call state - Unknown |
static int |
CALL_TYPE_DATA
Current call type - Data Call |
static int |
CALL_TYPE_VOICE
Current call type - Voice Call |
static int |
DATA_CALL_FAIL_PUSH
Current data call open/read/write failure. |
static int |
DATA_CALL_PATH_CLOSE
Current data call path is closed. |
static int |
DATA_CALL_PATH_OPEN
Current data call path is open. |
static int |
DATA_CALL_SUCCESS_PUSH
Current data call open/read/write successful operation. |
static int |
ERROR_CALL_IN_PROCESS
There is a call in process already. |
static int |
ERROR_CALL_MEMORY_FAILURE
Invalid call number. |
static int |
ERROR_CALL_NO_ACTIVE_CALL
There is no active call. |
static int |
ERROR_CALL_NO_INCOMING_CALL
There is no incoming call. |
static int |
ERROR_CALL_NOT_INITIALIZED
Current call profile initialization failure. |
static int |
ERROR_CALL_NUMBER_INVALID
Memory failure. |
static int |
ERROR_CALL_TABLE_FAILURE
Current call profile failure (not relevant for this version). |
static int |
ERROR_CALL_TIMER_FAILURE
Timer expiration failure (not relevant for this version). |
static int |
ERROR_CALL_TYPE_INVALID
Invalid call type. |
Method Summary | |
---|---|
void |
answer()
Answers a call. |
void |
configureMoDataCallconn(DataCallConfig cnfg)
Configures the next MO data call connection. |
void |
dial(java.lang.String destNumber,
int callType)
Sets up a Mobile Originated (MO) call. |
int |
getCallDirection()
Gets the current call direction (MO or MT) |
int |
getCallExitCause()
Gets the current(released) call's exit cause. |
java.lang.String |
getCallNumber()
Gets the current call's phone number. |
int |
getCallState()
Gets the current call state. |
int |
getCallType()
Gets the current call type (Voice or Data). |
DataCallConnection |
getDataCallconn()
Gets the current data call connection object. |
static Call |
getInstance()
Returns a reference to the class's single instance. |
DataCallConfig |
getMoDataCallConfig()
Gets the current (MO) data call configuration object. |
int |
getPlatformCallStatus()
Gets the current call's state on the platform. |
void |
release()
Releases a call. |
void |
setCallAlertListener(CallAlertListener listener)
Sets a listener for call alerts. |
void |
setCallStateListener(CallStateListener listener)
Sets a listener for call state changes. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int ERROR_CALL_IN_PROCESS
public static final int ERROR_CALL_MEMORY_FAILURE
public static final int ERROR_CALL_NUMBER_INVALID
public static final int ERROR_CALL_TYPE_INVALID
public static final int ERROR_CALL_NO_INCOMING_CALL
public static final int ERROR_CALL_NOT_INITIALIZED
public static final int ERROR_CALL_NO_ACTIVE_CALL
public static final int ERROR_CALL_TABLE_FAILURE
public static final int ERROR_CALL_TIMER_FAILURE
public static final int CALL_SESSION_TABLE_ERROR
public static final int DATA_CALL_FAIL_PUSH
public static final int DATA_CALL_SUCCESS_PUSH
public static final int DATA_CALL_PATH_OPEN
public static final int DATA_CALL_PATH_CLOSE
public static final int CALL_STATE_IDLE
public static final int CALL_STATE_CONNECTING
public static final int CALL_STATE_ALERTING
public static final int CALL_STATE_ACTIVE
public static final int CALL_STATE_RELEASING
public static final int CALL_STATE_UNKNOWN
public static final int CALL_DIRECTION_MT
public static final int CALL_DIRECTION_MO
public static final int CALL_TYPE_VOICE
public static final int CALL_TYPE_DATA
Method Detail |
---|
public static Call getInstance() throws CallException
CallException
- Failed to construct the Call object.public void setCallAlertListener(CallAlertListener listener)
Sets a listener for call alerts.
CallAlertListener.onCallAlert(int)
will be called upon a call alert.
public void setCallStateListener(CallStateListener listener)
Sets a listener for call state changes.
CallStateListener.onCallStateChanged(int)
will be called upon a call state change.
public void dial(java.lang.String destNumber, int callType) throws CallException
destNumber
- Destination phone numbercallType
- MO call type (voice or data call)
CallException
- Invalid parameters, Sim error or platform error
java.lang.SecurityException
CALL_TYPE_VOICE
,
CALL_TYPE_DATA
public void answer() throws CallException
CallException
- There is no alerting call to answer or a platform error while trying to answer.java.lang.SecurityException
public void release() throws CallException
CallException
- There is no call to release or a platform error while trying to release the call.public void configureMoDataCallconn(DataCallConfig cnfg) throws CallException
DataCallConfig
.
cnfg
- Object holding the configuration values to be set
CallException
- MO data call configuration has failedpublic DataCallConfig getMoDataCallConfig()
public DataCallConnection getDataCallconn() throws CallException
CallException
- There is no active call or active data connection for the callpublic int getCallDirection() throws CallException
CallException
- There is no active callCALL_DIRECTION_MT
,
CALL_DIRECTION_MO
public int getCallState()
CALL_STATE_IDLE
,
CALL_STATE_CONNECTING
,
CALL_STATE_ALERTING
,
CALL_STATE_ACTIVE
,
CALL_STATE_RELEASING
public int getCallType() throws CallException
CallException
- There is no active callCALL_TYPE_VOICE
,
CALL_TYPE_DATA
public java.lang.String getCallNumber() throws CallException
CallException
- No active call or caller ID is restricted/not available/not specified/not recognizedpublic int getPlatformCallStatus()
Note: The platform's call states are: call state is idle - 0 call state MT establishing - 1 call state MO connecting - 2 call state MT offering for data calls - 3 call state MT accepted for data calls - 4 call state MT alerting - 5 call state MT connecting - 6 call state MT call control by SIM - 7 call state connected - 8 call state multiparty active - 9 call state hold request - 10 call state multiparty hold request - 11 call state held - 12 call state multiparty held - 13 call state unhold request - 14 call state multiparty retrieve request - 15 call state join request - 16 call state split request - 17 call state transfer request - 18 call state MO mode change request - 19 call state MT mode change request - 20 call state reestablishing - 21 call state releasing - 22 call state redial - 23 call state resource pending - 24
public int getCallExitCause()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |