java.lang.Object | |
↳ | android.telecom.TelecomManager |
Provides access to information about active calls and registration/call-management functionality. Apps can use methods in this class to determine the current call state.
Apps do not instantiate this class directly; instead, they retrieve a reference to an instance
through Context.getSystemService(Context.TELECOM_SERVICE)
.
Note that access to some telecom information is permission-protected. Your app cannot access the protected information or gain access to protected functionality unless it has the appropriate permissions declared in its manifest file. Where permissions apply, they are noted in the method descriptions.
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
String | ACTION_SHOW_CALL_SETTINGS |
The Intent action used to show the call settings page.
|
|||||||||
char | DTMF_CHARACTER_PAUSE | The dual tone multi-frequency signaling character sent to indicate the dialing system should pause for a predefined period. | |||||||||
char | DTMF_CHARACTER_WAIT | The dual-tone multi-frequency signaling character sent to indicate the dialing system should wait for user confirmation before proceeding. | |||||||||
String | EXTRA_CALL_DISCONNECT_CAUSE |
Optional extra for ACTION_PHONE_STATE_CHANGED
containing the disconnect code.
|
|||||||||
String | EXTRA_CALL_DISCONNECT_MESSAGE |
Optional extra for ACTION_PHONE_STATE_CHANGED
containing the disconnect message.
|
|||||||||
String | EXTRA_START_CALL_WITH_SPEAKERPHONE |
Optional extra for ACTION_CALL containing a boolean that
determines whether the speakerphone should be automatically turned on for an outgoing call.
|
|||||||||
String | GATEWAY_ORIGINAL_ADDRESS |
An optional ACTION_CALL intent extra corresponding to the
original address to dial for the call.
|
|||||||||
String | GATEWAY_PROVIDER_PACKAGE |
An optional ACTION_CALL intent extra denoting the
package name of the app specifying an alternative gateway for the call.
|
|||||||||
int | PRESENTATION_ALLOWED | Property is displayed normally. | |||||||||
int | PRESENTATION_PAYPHONE | Property should be displayed as a pay phone. | |||||||||
int | PRESENTATION_RESTRICTED | Property was blocked. | |||||||||
int | PRESENTATION_UNKNOWN | Presentation was not specified or is unknown. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Removes the missed-call notification if one is present.
| |||||||||||
Processes the specified dial string as an MMI code.
| |||||||||||
Returns whether there is an ongoing phone call (can be in dialing, ringing, active or holding
states).
| |||||||||||
Brings the in-call screen to the foreground if there is an ongoing call.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
The Intent
action used to show the call settings page.
The dual tone multi-frequency signaling character sent to indicate the dialing system should pause for a predefined period.
The dual-tone multi-frequency signaling character sent to indicate the dialing system should wait for user confirmation before proceeding.
Optional extra for ACTION_PHONE_STATE_CHANGED
containing the disconnect code.
Optional extra for ACTION_PHONE_STATE_CHANGED
containing the disconnect message.
Optional extra for ACTION_CALL
containing a boolean that
determines whether the speakerphone should be automatically turned on for an outgoing call.
An optional ACTION_CALL
intent extra corresponding to the
original address to dial for the call. This is used when an alternative gateway address is
provided to recall the original address.
The value is a Uri
.
(See GATEWAY_PROVIDER_PACKAGE
for details)
An optional ACTION_CALL
intent extra denoting the
package name of the app specifying an alternative gateway for the call.
The value is a string.
(The following comment corresponds to the all GATEWAY_* extras)
An app which sends the ACTION_CALL
intent can specify an
alternative address to dial which is different from the one specified and displayed to
the user. This alternative address is referred to as the gateway address.
Property is displayed normally.
Property should be displayed as a pay phone.
Property was blocked.
Presentation was not specified or is unknown.
Removes the missed-call notification if one is present.
Requires that the method-caller be set as the system dialer app.
Processes the specified dial string as an MMI code. MMI codes are any sequence of characters entered into the dialpad that contain a "*" or "#". Some of these sequences launch special behavior through handled by Telephony. This method uses the default subscription.
Requires that the method-caller be set as the system dialer app.
dialString | The digits to dial. |
---|
Returns whether there is an ongoing phone call (can be in dialing, ringing, active or holding states).
Requires permission: READ_PHONE_STATE
Brings the in-call screen to the foreground if there is an ongoing call. If there is currently no ongoing call, then this method does nothing.
Requires that the method-caller be set as the system dialer app or have the
READ_PHONE_STATE
permission.
showDialpad | Brings up the in-call dialpad as part of showing the in-call screen. |
---|