Methods Summary |
---|
public void | answerRingingCall()Answer the currently-ringing call.
If there's already a current active call, that call will be
automatically put on hold. If both lines are currently in use, the
current active call will be ended.
TODO: provide a flag to let the caller specify what policy to use
if both lines are in use. (The current behavior is hardwired to
"answer incoming, end ongoing", which is how the CALL button
is specced to behave.)
TODO: this should be a oneway call (especially since it's called
directly from the key queue thread).
|
public void | answerRingingCallForSubscriber(int subId)Answer the currently-ringing call on particular subId .
If there's already a current active call, that call will be
automatically put on hold. If both lines are currently in use, the
current active call will be ended.
TODO: provide a flag to let the caller specify what policy to use
if both lines are in use. (The current behavior is hardwired to
"answer incoming, end ongoing", which is how the CALL button
is specced to behave.)
TODO: this should be a oneway call (especially since it's called
directly from the key queue thread).
|
public void | call(java.lang.String callingPackage, java.lang.String number)Place a call to the specified number.
|
public int | checkCarrierPrivilegesForPackage(java.lang.String pkgname)Similar to above, but check for pkg whose name is pkgname.
|
public void | dial(java.lang.String number)Dial a number. This doesn't place the call. It displays
the Dialer screen.
|
public boolean | disableDataConnectivity()Disallow mobile data connections.
|
public void | disableLocationUpdates()Disable location update notifications.
|
public void | disableLocationUpdatesForSubscriber(int subId)Disable location update notifications.
|
public boolean | enableDataConnectivity()Allow mobile data connections.
|
public void | enableLocationUpdates()Enable location update notifications.
|
public void | enableLocationUpdatesForSubscriber(int subId)Enable location update notifications.
|
public void | enableVideoCalling(boolean enable)Enables or disables video calling.
|
public boolean | endCall()End call if there is a call in progress, otherwise does nothing.
|
public boolean | endCallForSubscriber(int subId)End call on particular subId or go to the Home screen
|
public int | getActivePhoneType()Returns the current active phone type as integer.
Returns TelephonyManager.PHONE_TYPE_CDMA if RILConstants.CDMA_PHONE
and TelephonyManager.PHONE_TYPE_GSM if RILConstants.GSM_PHONE
|
public int | getActivePhoneTypeForSubscriber(int subId)Returns the current active phone type as integer for particular subId.
Returns TelephonyManager.PHONE_TYPE_CDMA if RILConstants.CDMA_PHONE
and TelephonyManager.PHONE_TYPE_GSM if RILConstants.GSM_PHONE
|
public java.util.List | getAllCellInfo()Returns the all observed cell information of the device.
|
public int | getCalculatedPreferredNetworkType()
|
public int | getCallState()
|
public int | getCallStateForSubscriber(int subId)Returns the call state for a subId.
|
public java.util.List | getCarrierPackageNamesForIntent(android.content.Intent intent)Returns the package name of the carrier apps that should handle the input intent.
|
public int | getCarrierPrivilegeStatus()Has the calling application been granted special privileges by the carrier.
If any of the packages in the calling UID has carrier privileges, the
call will return true. This access is granted by the owner of the UICC
card and does not depend on the registered carrier.
TODO: Add a link to documentation.
|
public int | getCdmaEriIconIndex()Returns the CDMA ERI icon index to display
|
public int | getCdmaEriIconIndexForSubscriber(int subId)Returns the CDMA ERI icon index to display on particular subId.
|
public int | getCdmaEriIconMode()Returns the CDMA ERI icon mode,
0 - ON
1 - FLASHING
|
public int | getCdmaEriIconModeForSubscriber(int subId)Returns the CDMA ERI icon mode on particular subId,
0 - ON
1 - FLASHING
|
public java.lang.String | getCdmaEriText()Returns the CDMA ERI text,
|
public java.lang.String | getCdmaEriTextForSubscriber(int subId)Returns the CDMA ERI text for particular subId,
|
public java.lang.String | getCdmaMdn(int subId)Return MDN string for CDMA phone.
|
public java.lang.String | getCdmaMin(int subId)Return MIN string for CDMA phone.
|
public android.os.Bundle | getCellLocation()
|
public int | getDataActivity()
|
public boolean | getDataEnabled(int subId)Get the user enabled state of Mobile Data.
|
public int | getDataNetworkType()Returns the network type for data transmission
|
public int | getDataNetworkTypeForSubscriber(int subId)Returns the data network type of a subId
|
public int | getDataState()
|
public int | getDefaultSim()get default sim
|
public java.lang.String | getDeviceId()Returns the unique device ID of phone, for example, the IMEI for
GSM and the MEID for CDMA phones. Return null if device ID is not available.
Requires Permission:
{@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
|
public java.lang.String | getLine1AlphaTagForDisplay(int subId)Returns the displayed alphatag of the dialing number if it was set
previously via {@link #setLine1NumberForDisplay}. Otherwise returns null.
|
public java.lang.String | getLine1NumberForDisplay(int subId)Returns the displayed dialing number string if it was set previously via
{@link #setLine1NumberForDisplay}. Otherwise returns null.
|
public int | getLteOnCdmaMode()Return if the current radio is LTE on CDMA. This
is a tri-state return value as for a period of time
the mode may be unknown.
|
public int | getLteOnCdmaModeForSubscriber(int subId)Return if the current radio is LTE on CDMA. This
is a tri-state return value as for a period of time
the mode may be unknown.
|
public java.lang.String[] | getMergedSubscriberIds()
|
public java.util.List | getNeighboringCellInfo(java.lang.String callingPkg)Returns the neighboring cell information of the device.
|
public int | getNetworkType()Returns the network type for data transmission
|
public int | getNetworkTypeForSubscriber(int subId)Returns the network type of a subId.
|
public java.lang.String[] | getPcscfAddress(java.lang.String apnType)Get P-CSCF address from PCO after data connection is established or modified.
|
public int | getPreferredNetworkType()
|
public int | getRadioAccessFamily(int phoneId)Get phone radio type and access technology.
|
public int | getTetherApnRequired()Check TETHER_DUN_REQUIRED and TETHER_DUN_APN settings, net.tethering.noprovisioning
SystemProperty, and config_tether_apndata to decide whether DUN APN is required for
tethering.
|
public int | getVoiceMessageCount()Returns the unread count of voicemails
|
public int | getVoiceMessageCountForSubscriber(int subId)Returns the unread count of voicemails for a subId.
|
public int | getVoiceNetworkType()Returns the network type for voice
|
public int | getVoiceNetworkTypeForSubscriber(int subId)Returns the voice network type of a subId
|
public boolean | handlePinMmi(java.lang.String dialString)Handles PIN MMI commands (PIN/PIN2/PUK/PUK2), which are initiated
without SEND (so dial is not appropriate).
|
public boolean | handlePinMmiForSubscriber(int subId, java.lang.String dialString)Handles PIN MMI commands (PIN/PIN2/PUK/PUK2), which are initiated
without SEND (so dial is not appropriate) for
a particular subId.
|
public boolean | hasIccCard()Return true if an ICC card is present
|
public boolean | hasIccCardUsingSlotId(int slotId)Return true if an ICC card is present for a subId.
|
public boolean | iccCloseLogicalChannel(int channel)Closes a previously opened logical channel to the ICC card.
Input parameters equivalent to TS 27.007 AT+CCHC command.
|
public byte[] | iccExchangeSimIO(int fileID, int command, int p1, int p2, int p3, java.lang.String filePath)Returns the response APDU for a command APDU sent through SIM_IO.
|
public android.telephony.IccOpenLogicalChannelResponse | iccOpenLogicalChannel(java.lang.String AID)Opens a logical channel to the ICC card.
Input parameters equivalent to TS 27.007 AT+CCHO command.
|
public java.lang.String | iccTransmitApduBasicChannel(int cla, int instruction, int p1, int p2, int p3, java.lang.String data)Transmit an APDU to the ICC card over the basic channel.
Input parameters equivalent to TS 27.007 AT+CSIM command.
|
public java.lang.String | iccTransmitApduLogicalChannel(int channel, int cla, int instruction, int p1, int p2, int p3, java.lang.String data)Transmit an APDU to the ICC card over a logical channel.
Input parameters equivalent to TS 27.007 AT+CGLA command.
|
public int | invokeOemRilRequestRaw(byte[] oemReq, byte[] oemResp)Returns the result and response from RIL for oem request
|
public boolean | isDataConnectivityPossible()Report whether data connectivity is possible.
|
public boolean | isIdle()Check if the phone is idle.
|
public boolean | isIdleForSubscriber(int subId)Check if the phone is idle on a particular subId.
|
public boolean | isImsRegistered()Get IMS Registration Status
|
public boolean | isOffhook()Check if we are in either an active or holding call
|
public boolean | isOffhookForSubscriber(int subId)Check if a particular subId has an active or holding call
|
public boolean | isRadioOn()Check to see if the radio is on or not.
|
public boolean | isRadioOnForSubscriber(int subId)Check to see if the radio is on or not on particular subId.
|
public boolean | isRinging()Check if an incoming phone call is ringing or call waiting.
|
public boolean | isRingingForSubscriber(int subId)Check if an incoming phone call is ringing or call waiting
on a particular subId.
|
public boolean | isSimPinEnabled()Check if the SIM pin lock is enabled.
|
public boolean | isVideoCallingEnabled()Whether video calling has been enabled by the user.
|
public boolean | needMobileRadioShutdown()Check if any mobile Radios need to be shutdown.
|
public boolean | needsOtaServiceProvisioning()Returns true if OTA service provisioning needs to run.
Only relevant on some technologies, others will always
return false.
|
public java.lang.String | nvReadItem(int itemID)Read one of the NV items defined in {@link RadioNVItems} / {@code ril_nv_items.h}.
Used for device configuration by some CDMA operators.
|
public boolean | nvResetConfig(int resetType)Perform the specified type of NV config reset. The radio will be taken offline
and the device must be rebooted after the operation. Used for device
configuration by some CDMA operators.
|
public boolean | nvWriteCdmaPrl(byte[] preferredRoamingList)Update the CDMA Preferred Roaming List (PRL) in the radio NV storage.
Used for device configuration by some CDMA operators.
|
public boolean | nvWriteItem(int itemID, java.lang.String itemValue)Write one of the NV items defined in {@link RadioNVItems} / {@code ril_nv_items.h}.
Used for device configuration by some CDMA operators.
|
public java.lang.String | sendEnvelopeWithStatus(java.lang.String content)Send ENVELOPE to the SIM and returns the response.
|
public void | setCellInfoListRate(int rateInMillis)Sets minimum time in milli-seconds between onCellInfoChanged
|
public void | setDataEnabled(int subId, boolean enable)User enable/disable Mobile Data.
|
public void | setImsRegistrationState(boolean registered)Set IMS registration state
|
public boolean | setLine1NumberForDisplayForSubscriber(int subId, java.lang.String alphaTag, java.lang.String number)Set the line 1 phone number string and its alphatag for the current ICCID
for display purpose only, for example, displayed in Phone Status. It won't
change the actual MSISDN/MDN. To unset alphatag or number, pass in a null
value.
|
public boolean | setOperatorBrandOverride(java.lang.String brand)Override the operator branding for the current ICCID.
Once set, whenever the SIM is present in the device, the service
provider name (SPN) and the operator name will both be replaced by the
brand value input. To unset the value, the same function should be
called with a null brand value.
Requires Permission:
{@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
or has to be carrier app - see #hasCarrierPrivileges.
|
public boolean | setPreferredNetworkType(int networkType)Set the preferred network type.
Used for device configuration by some CDMA operators.
|
public boolean | setRadio(boolean turnOn)Set the radio to on or off
|
public void | setRadioCapability(android.telephony.RadioAccessFamily[] rafs)Set phone radio type and access technology.
|
public boolean | setRadioForSubscriber(int subId, boolean turnOn)Set the radio to on or off on particular subId.
|
public boolean | setRadioPower(boolean turnOn)Set the radio to on or off unconditionally
|
public boolean | setRoamingOverride(java.util.List gsmRoamingList, java.util.List gsmNonRoamingList, java.util.List cdmaRoamingList, java.util.List cdmaNonRoamingList)Override the roaming indicator for the current ICCID.
Using this call, the carrier app (see #hasCarrierPrivileges) can override
the platform's notion of a network operator being considered roaming or not.
The change only affects the ICCID that was active when this call was made.
If null is passed as any of the input, the corresponding value is deleted.
Requires that the caller have carrier privilege. See #hasCarrierPrivileges.
|
public boolean | setVoiceMailNumber(int subId, java.lang.String alphaTag, java.lang.String number)Sets the voicemail number for a particular subscriber.
|
public void | shutdownMobileRadios()Shutdown Mobile Radios
|
public void | silenceRinger()Silence the ringer if an incoming call is currently ringing.
(If vibrating, stop the vibrator also.)
It's safe to call this if the ringer has already been silenced, or
even if there's no incoming call. (If so, this method will do nothing.)
TODO: this should be a oneway call too (see above).
(Actually *all* the methods here that return void can
probably be oneway.)
|
public boolean | supplyPin(java.lang.String pin)Supply a pin to unlock the SIM. Blocks until a result is determined.
|
public boolean | supplyPinForSubscriber(int subId, java.lang.String pin)Supply a pin to unlock the SIM for particular subId.
Blocks until a result is determined.
|
public int[] | supplyPinReportResult(java.lang.String pin)Supply a pin to unlock the SIM. Blocks until a result is determined.
Returns a specific success/error code.
|
public int[] | supplyPinReportResultForSubscriber(int subId, java.lang.String pin)Supply a pin to unlock the SIM. Blocks until a result is determined.
Returns a specific success/error code.
|
public boolean | supplyPuk(java.lang.String puk, java.lang.String pin)Supply puk to unlock the SIM and set SIM pin to new pin.
Blocks until a result is determined.
|
public boolean | supplyPukForSubscriber(int subId, java.lang.String puk, java.lang.String pin)Supply puk to unlock the SIM and set SIM pin to new pin.
Blocks until a result is determined.
|
public int[] | supplyPukReportResult(java.lang.String puk, java.lang.String pin)Supply puk to unlock the SIM and set SIM pin to new pin.
Blocks until a result is determined.
Returns a specific success/error code
|
public int[] | supplyPukReportResultForSubscriber(int subId, java.lang.String puk, java.lang.String pin)Supply puk to unlock the SIM and set SIM pin to new pin.
Blocks until a result is determined.
Returns a specific success/error code
|
public void | toggleRadioOnOff()Toggles the radio on or off.
|
public void | toggleRadioOnOffForSubscriber(int subId)Toggles the radio on or off on particular subId.
|
public void | updateServiceLocation()Request to update location information in service state
|
public void | updateServiceLocationForSubscriber(int subId)Request to update location information for a subscrition in service state
|