Example usage for Java android.telephony TelephonyManager fields, constructors, methods, implement or subclass
The text is from its open source code.
String | ACTION_PHONE_STATE_CHANGED Broadcast intent action indicating that the call state on the device has changed. |
String | ACTION_RESPOND_VIA_MESSAGE The Phone app sends this intent when a user opts to respond-via-message during an incoming call. |
String | EXTRA_STATE The lookup key used with the #ACTION_PHONE_STATE_CHANGED broadcast for a String containing the new call state. |
String | EXTRA_STATE_IDLE Value used with #EXTRA_STATE corresponding to #CALL_STATE_IDLE . |
String | EXTRA_STATE_RINGING Value used with #EXTRA_STATE corresponding to #CALL_STATE_RINGING . |
String | EXTRA_STATE_OFFHOOK Value used with #EXTRA_STATE corresponding to #CALL_STATE_OFFHOOK . |
String | EXTRA_INCOMING_NUMBER Extra key used with the #ACTION_PHONE_STATE_CHANGED broadcast for a String containing the incoming or outgoing phone number. |
int | PHONE_TYPE_NONE No phone radio. |
int | PHONE_TYPE_GSM Phone radio is GSM. |
int | PHONE_TYPE_CDMA Phone radio is CDMA. |
int | PHONE_TYPE_SIP Phone is via SIP. |
int | NETWORK_TYPE_UNKNOWN Network type is unknown |
int | NETWORK_TYPE_GPRS Current network is GPRS |
int | NETWORK_TYPE_EDGE Current network is EDGE |
int | NETWORK_TYPE_UMTS Current network is UMTS |
int | NETWORK_TYPE_CDMA Current network is CDMA: Either IS95A or IS95B |
int | NETWORK_TYPE_EVDO_0 Current network is EVDO revision 0 |
int | NETWORK_TYPE_EVDO_A Current network is EVDO revision A |
int | NETWORK_TYPE_1xRTT Current network is 1xRTT |
int | NETWORK_TYPE_HSDPA Current network is HSDPA |
int | NETWORK_TYPE_HSUPA Current network is HSUPA |
int | NETWORK_TYPE_HSPA Current network is HSPA |
int | NETWORK_TYPE_IDEN Current network is iDen |
int | NETWORK_TYPE_EVDO_B Current network is EVDO revision B |
int | NETWORK_TYPE_LTE Current network is LTE |
int | NETWORK_TYPE_EHRPD Current network is eHRPD |
int | NETWORK_TYPE_HSPAP Current network is HSPA+ |
int | NETWORK_TYPE_GSM Current network is GSM |
int | NETWORK_TYPE_TD_SCDMA Current network is TD_SCDMA |
int | NETWORK_TYPE_IWLAN Current network is IWLAN |
int | SIM_STATE_UNKNOWN SIM card state: Unknown. |
int | SIM_STATE_ABSENT SIM card state: no SIM card is available in the device |
int | SIM_STATE_PIN_REQUIRED SIM card state: Locked: requires the user's SIM PIN to unlock |
int | SIM_STATE_PUK_REQUIRED SIM card state: Locked: requires the user's SIM PUK to unlock |
int | SIM_STATE_NETWORK_LOCKED SIM card state: Locked: requires a network PIN to unlock |
int | SIM_STATE_READY SIM card state: Ready |
int | CALL_STATE_IDLE Device call state: No activity. |
int | CALL_STATE_RINGING Device call state: Ringing. |
int | CALL_STATE_OFFHOOK Device call state: Off-hook. |
int | DATA_ACTIVITY_NONE Data connection activity: No traffic. |
int | DATA_ACTIVITY_IN Data connection activity: Currently receiving IP PPP traffic. |
int | DATA_ACTIVITY_OUT Data connection activity: Currently sending IP PPP traffic. |
int | DATA_ACTIVITY_INOUT Data connection activity: Currently both sending and receiving IP PPP traffic. |
int | DATA_ACTIVITY_DORMANT Data connection is active, but physical link is down |
int | DATA_DISCONNECTED Data connection state: Disconnected. |
int | DATA_CONNECTING Data connection state: Currently setting up a data connection. |
int | DATA_CONNECTED Data connection state: Connected. |
int | DATA_SUSPENDED Data connection state: Suspended. |
TelephonyManager | from(Context context) |
List | getAllCellInfo() Requests all available cell information from all radios on the device including the camped/registered, serving, and neighboring cells. |
int | getCallState() Returns the state of all calls on the device. |
CellLocation | getCellLocation() Returns the current location of the device. |
Class> | getClass() Returns the runtime class of this Object . |
int | getDataActivity() Returns a constant indicating the type of activity on a data connection (cellular). |
int | getDataState() Returns a constant indicating the current data connection state (cellular). |
TelephonyManager | getDefault() |
String | getDeviceId() Returns the unique device ID, for example, the IMEI for GSM and the MEID or ESN for CDMA phones. |
String | getDeviceSoftwareVersion() Returns the software version number for the device, for example, the IMEI/SV for GSM phones. |
String | getLine1AlphaTag() Returns the alphabetic identifier associated with the line 1 number. |
String | getLine1Number() Returns the phone number string for line 1, for example, the MSISDN for a GSM phone. |
List | getNeighboringCellInfo() Returns the neighboring cell information of the device. |
String | getNetworkCountryIso() Returns the ISO-3166 country code equivalent of the MCC (Mobile Country Code) of the current registered operator or the cell nearby, if available. |
String | getNetworkOperator() Returns the numeric name (MCC+MNC) of current registered operator. |
String | getNetworkOperatorName() Returns the alphabetic name of current registered operator. |
int | getNetworkType() Return the current data network type. |
int | getPhoneCount() Returns the number of phones available. |
int | getPhoneType() Returns a constant indicating the device phone type. |
int | getSimCount() |
String | getSimCountryIso() Returns the ISO-3166 country code equivalent for the SIM provider's country code. |
String | getSimOperator() Returns the MCC+MNC (mobile country code + mobile network code) of the provider of the SIM. |
String | getSimOperatorName() Returns the Service Provider Name (SPN). |
String | getSimSerialNumber() Returns the serial number of the SIM, if applicable. |
int | getSimState() Returns a constant indicating the state of the default SIM card. |
int | getSimState(int slotIndex) Returns a constant indicating the state of the device SIM card in a slot. |
int | getSubIdForPhoneAccount(PhoneAccount phoneAccount) Returns the subscription ID for the given phone account. |
String | getSubscriberId() Returns the unique subscriber ID, for example, the IMSI for a GSM phone. |
String | getVoiceMailAlphaTag() Retrieves the alphabetic identifier associated with the voice mail number. |
String | getVoiceMailNumber() Returns the voice mail number. |
boolean | hasIccCard() |
boolean | isNetworkRoaming() Returns true if the device is considered roaming on the current network, for GSM purposes. |
boolean | isVoiceCapable() |
void | listen(PhoneStateListener listener, int events) Registers a listener object to receive notification of changes in specified telephony states. |