Stay organized with collections
Save and categorize content based on your preferences.
TelephonyCallback.RegistrationFailedListener
public
static
interface
TelephonyCallback.RegistrationFailedListener
android.telephony.TelephonyCallback.RegistrationFailedListener
|
Interface for registration failures listener.
Summary
Public methods |
abstract
void
|
onRegistrationFailed(CellIdentity cellIdentity, String chosenPlmn, int domain, int causeCode, int additionalCauseCode)
Report that Registration or a Location/Routing/Tracking Area update has failed.
|
Public methods
onRegistrationFailed
public abstract void onRegistrationFailed (CellIdentity cellIdentity,
String chosenPlmn,
int domain,
int causeCode,
int additionalCauseCode)
Report that Registration or a Location/Routing/Tracking Area update has failed.
Indicate whenever a registration procedure, including a location, routing, or tracking
area update fails. This includes procedures that do not necessarily result in a change of
the modem's registration status. If the modem's registration status changes, that is
reflected in the onNetworkStateChanged() and subsequent
get{Voice/Data}RegistrationState().
Because registration failures are ephemeral, this callback is not sticky.
Registrants will not receive the most recent past value when registering.
The calling app should have carrier privileges
(see TelephonyManager.hasCarrierPrivileges
) if it does not have the
Manifest.permission.READ_PRECISE_PHONE_STATE
and
Manifest.permission.ACCESS_FINE_LOCATION
.
If the calling app doesn't have Manifest.permission.ACCESS_FINE_LOCATION
,
it will receive CellIdentity
without location-sensitive information included.
Requires Manifest.permission.READ_PRECISE_PHONE_STATE
and Manifest.permission.ACCESS_FINE_LOCATION
Parameters |
cellIdentity |
CellIdentity : the CellIdentity, which must include the globally unique
identifier
for the cell (for example, all components of the CGI or ECGI).
This value cannot be null . |
chosenPlmn |
String : a 5 or 6 digit alphanumeric PLMN (MCC|MNC) among those
broadcast by the
cell that was chosen for the failed registration attempt.
This value cannot be null . |
domain |
int : DOMAIN_CS, DOMAIN_PS or both in case of a combined procedure.
Value is NetworkRegistrationInfo.DOMAIN_UNKNOWN , NetworkRegistrationInfo.DOMAIN_CS , NetworkRegistrationInfo.DOMAIN_PS , or NetworkRegistrationInfo.DOMAIN_CS_PS |
causeCode |
int : the primary failure cause code of the procedure.
For GSM/UMTS (MM), values are in TS 24.008 Sec 10.5.95
For GSM/UMTS (GMM), values are in TS 24.008 Sec 10.5.147
For LTE (EMM), cause codes are TS 24.301 Sec 9.9.3.9
For NR (5GMM), cause codes are TS 24.501 Sec 9.11.3.2
Integer.MAX_VALUE if this value is unused. |
additionalCauseCode |
int : the cause code of any secondary/combined procedure
if appropriate. For UMTS, if a combined attach succeeds for
PS only, then the GMM cause code shall be included as an
additionalCauseCode. For LTE (ESM), cause codes are in
TS 24.301 9.9.4.4. Integer.MAX_VALUE if this value is unused. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# TelephonyCallback.RegistrationFailedListener\n\nAdded in [API level 31](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\nTelephonyCallback.RegistrationFailedListener\n============================================\n\n*** ** * ** ***\n\n[Kotlin](/reference/kotlin/android/telephony/TelephonyCallback.RegistrationFailedListener \"View this page in Kotlin\") \\|Java\n\n\n`\npublic\nstatic\n\n\ninterface\nTelephonyCallback.RegistrationFailedListener\n`\n\n\n`\n\n\n`\n\n|----------------------------------------------------------------|\n| android.telephony.TelephonyCallback.RegistrationFailedListener |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nInterface for registration failures listener.\n\nSummary\n-------\n\n| ### Public methods ||\n|------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract void` | ` `[onRegistrationFailed](/reference/android/telephony/TelephonyCallback.RegistrationFailedListener#onRegistrationFailed(android.telephony.CellIdentity,%20java.lang.String,%20int,%20int,%20int))`(`[CellIdentity](/reference/android/telephony/CellIdentity)` cellIdentity, `[String](/reference/java/lang/String)` chosenPlmn, int domain, int causeCode, int additionalCauseCode) ` Report that Registration or a Location/Routing/Tracking Area update has failed. |\n\nPublic methods\n--------------\n\n### onRegistrationFailed\n\nAdded in [API level 31](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract void onRegistrationFailed (CellIdentity cellIdentity, \n String chosenPlmn, \n int domain, \n int causeCode, \n int additionalCauseCode)\n```\n\nReport that Registration or a Location/Routing/Tracking Area update has failed.\n\nIndicate whenever a registration procedure, including a location, routing, or tracking\narea update fails. This includes procedures that do not necessarily result in a change of\nthe modem's registration status. If the modem's registration status changes, that is\nreflected in the onNetworkStateChanged() and subsequent\nget{Voice/Data}RegistrationState().\n\nBecause registration failures are ephemeral, this callback is not sticky.\nRegistrants will not receive the most recent past value when registering.\n\nThe calling app should have carrier privileges\n(see [TelephonyManager.hasCarrierPrivileges](/reference/android/telephony/TelephonyManager#hasCarrierPrivileges())) if it does not have the\n[Manifest.permission.READ_PRECISE_PHONE_STATE](/reference/android/Manifest.permission#READ_PRECISE_PHONE_STATE) and\n[Manifest.permission.ACCESS_FINE_LOCATION](/reference/android/Manifest.permission#ACCESS_FINE_LOCATION).\n\nIf the calling app doesn't have [Manifest.permission.ACCESS_FINE_LOCATION](/reference/android/Manifest.permission#ACCESS_FINE_LOCATION),\nit will receive [CellIdentity](/reference/android/telephony/CellIdentity) without location-sensitive information included.\n\n\u003cbr /\u003e\n\n\nRequires [Manifest.permission.READ_PRECISE_PHONE_STATE](/reference/android/Manifest.permission#READ_PRECISE_PHONE_STATE) and [Manifest.permission.ACCESS_FINE_LOCATION](/reference/android/Manifest.permission#ACCESS_FINE_LOCATION)\n\n\u003cbr /\u003e\n\n| Parameters ||\n|-----------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `cellIdentity` | `CellIdentity`: the CellIdentity, which must include the globally unique identifier for the cell (for example, all components of the CGI or ECGI). This value cannot be `null`. \u003cbr /\u003e |\n| `chosenPlmn` | `String`: a 5 or 6 digit alphanumeric PLMN (MCC\\|MNC) among those broadcast by the cell that was chosen for the failed registration attempt. This value cannot be `null`. \u003cbr /\u003e |\n| `domain` | `int`: DOMAIN_CS, DOMAIN_PS or both in case of a combined procedure. Value is [NetworkRegistrationInfo.DOMAIN_UNKNOWN](/reference/android/telephony/NetworkRegistrationInfo#DOMAIN_UNKNOWN), [NetworkRegistrationInfo.DOMAIN_CS](/reference/android/telephony/NetworkRegistrationInfo#DOMAIN_CS), [NetworkRegistrationInfo.DOMAIN_PS](/reference/android/telephony/NetworkRegistrationInfo#DOMAIN_PS), or [NetworkRegistrationInfo.DOMAIN_CS_PS](/reference/android/telephony/NetworkRegistrationInfo#DOMAIN_CS_PS) \u003cbr /\u003e |\n| `causeCode` | `int`: the primary failure cause code of the procedure. For GSM/UMTS (MM), values are in TS 24.008 Sec 10.5.95 For GSM/UMTS (GMM), values are in TS 24.008 Sec 10.5.147 For LTE (EMM), cause codes are TS 24.301 Sec 9.9.3.9 For NR (5GMM), cause codes are TS 24.501 Sec 9.11.3.2 Integer.MAX_VALUE if this value is unused. \u003cbr /\u003e |\n| `additionalCauseCode` | `int`: the cause code of any secondary/combined procedure if appropriate. For UMTS, if a combined attach succeeds for PS only, then the GMM cause code shall be included as an additionalCauseCode. For LTE (ESM), cause codes are in TS 24.301 9.9.4.4. Integer.MAX_VALUE if this value is unused. \u003cbr /\u003e |"]]