Methods Summary |
---|
public void | dispose()
|
protected void | dump(java.io.FileDescriptor fd, java.io.PrintWriter pw, java.lang.String[] args)
if (mContext.checkCallingOrSelfPermission(android.Manifest.permission.DUMP)
!= PackageManager.PERMISSION_GRANTED) {
pw.println("Permission Denial: can't dump PhoneSubInfo from from pid="
+ Binder.getCallingPid()
+ ", uid=" + Binder.getCallingUid());
return;
}
pw.println("Phone Subscriber Info:");
pw.println(" Phone Type = " + mPhone.getPhoneName());
pw.println(" Device ID = " + mPhone.getDeviceId());
|
protected void | finalize()
try {
super.finalize();
} catch (Throwable throwable) {
loge("Error while finalizing:", throwable);
}
if (DBG) log("PhoneSubInfo finalized");
|
public java.lang.String | getCompleteVoiceMailNumber()Retrieves the complete voice mail number.
mContext.enforceCallingOrSelfPermission(CALL_PRIVILEGED,
"Requires CALL_PRIVILEGED");
String number = mPhone.getVoiceMailNumber();
if (VDBG) log("VM: PhoneSubInfo.getCompleteVoiceMailNUmber: " + number);
return number;
|
public java.lang.String | getDeviceId()Retrieves the unique device ID, e.g., IMEI for GSM phones and MEID for CDMA phones.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getDeviceId();
|
public java.lang.String | getDeviceSvn()Retrieves the software version number for the device, e.g., IMEI/SV
for GSM phones.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getDeviceSvn();
|
public java.lang.String | getGroupIdLevel1()Retrieves the Group Identifier Level1 for GSM phones.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getGroupIdLevel1();
|
public java.lang.String | getIccSerialNumber()Retrieves the serial number of the ICC, if applicable.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getIccSerialNumber();
|
public java.lang.String | getIccSimChallengeResponse(int subId, int appType, java.lang.String data)Returns the response of the SIM application on the UICC to authentication
challenge/response algorithm. The data string and challenge response are
Base64 encoded Strings.
Can support EAP-SIM, EAP-AKA with results encoded per 3GPP TS 31.102.
// FIXME: use subId!!
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE,
"Requires READ_PRIVILEGED_PHONE_STATE");
UiccCard uiccCard = mPhone.getUiccCard();
if (uiccCard == null) {
Rlog.e(LOG_TAG, "getIccSimChallengeResponse() UiccCard is null");
return null;
}
UiccCardApplication uiccApp = uiccCard.getApplicationByType(appType);
if (uiccApp == null) {
Rlog.e(LOG_TAG, "getIccSimChallengeResponse() no app with specified type -- " +
appType);
return null;
} else {
Rlog.e(LOG_TAG, "getIccSimChallengeResponse() found app " + uiccApp.getAid()
+ "specified type -- " + appType);
}
int authContext = uiccApp.getAuthContext();
if (data.length() < 32) {
/* must use EAP_SIM context */
Rlog.e(LOG_TAG, "data is too small to use EAP_AKA, using EAP_SIM instead");
authContext = UiccCardApplication.AUTH_CONTEXT_EAP_SIM;
}
if(authContext == UiccCardApplication.AUTH_CONTEXT_UNDEFINED) {
Rlog.e(LOG_TAG, "getIccSimChallengeResponse() authContext undefined for app type " +
appType);
return null;
}
return uiccApp.getIccRecords().getIccSimChallengeResponse(authContext, data);
|
public java.lang.String | getImei()Retrieves the IMEI.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getImei();
|
public java.lang.String | getIsimChallengeResponse(java.lang.String nonce)Returns the response of ISIM Authetification through RIL.
Returns null if the Authentification hasn't been successed or isn't present iphonesubinfo.
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE,
"Requires READ_PRIVILEGED_PHONE_STATE");
IsimRecords isim = mPhone.getIsimRecords();
if (isim != null) {
return isim.getIsimChallengeResponse(nonce);
} else {
return null;
}
|
public java.lang.String | getIsimDomain()Returns the IMS home network domain name that was loaded from the ISIM.
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE,
"Requires READ_PRIVILEGED_PHONE_STATE");
IsimRecords isim = mPhone.getIsimRecords();
if (isim != null) {
return isim.getIsimDomain();
} else {
return null;
}
|
public java.lang.String | getIsimImpi()Returns the IMS private user identity (IMPI) that was loaded from the ISIM.
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE,
"Requires READ_PRIVILEGED_PHONE_STATE");
IsimRecords isim = mPhone.getIsimRecords();
if (isim != null) {
return isim.getIsimImpi();
} else {
return null;
}
|
public java.lang.String[] | getIsimImpu()Returns the IMS public user identities (IMPU) that were loaded from the ISIM.
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE,
"Requires READ_PRIVILEGED_PHONE_STATE");
IsimRecords isim = mPhone.getIsimRecords();
if (isim != null) {
return isim.getIsimImpu();
} else {
return null;
}
|
public java.lang.String | getIsimIst()Returns the IMS Service Table (IST) that was loaded from the ISIM.
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE,
"Requires READ_PRIVILEGED_PHONE_STATE");
IsimRecords isim = mPhone.getIsimRecords();
if (isim != null) {
return isim.getIsimIst();
} else {
return null;
}
|
public java.lang.String[] | getIsimPcscf()Returns the IMS Proxy Call Session Control Function(PCSCF) that were loaded from the ISIM.
mContext.enforceCallingOrSelfPermission(READ_PRIVILEGED_PHONE_STATE,
"Requires READ_PRIVILEGED_PHONE_STATE");
IsimRecords isim = mPhone.getIsimRecords();
if (isim != null) {
return isim.getIsimPcscf();
} else {
return null;
}
|
public java.lang.String | getLine1AlphaTag()Retrieves the alpha identifier for line 1.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getLine1AlphaTag();
|
public java.lang.String | getLine1Number()Retrieves the phone number string for line 1.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getLine1Number();
|
public java.lang.String | getMsisdn()Retrieves the MSISDN string.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getMsisdn();
|
public java.lang.String | getNai()Retrieves the NAI.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getNai();
|
public java.lang.String | getSubscriberId()Retrieves the unique subscriber ID, e.g., IMSI for GSM phones.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getSubscriberId();
|
public java.lang.String | getVoiceMailAlphaTag()Retrieves the alpha identifier associated with the voice mail number.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
return mPhone.getVoiceMailAlphaTag();
|
public java.lang.String | getVoiceMailNumber()Retrieves the voice mail number.
mContext.enforceCallingOrSelfPermission(READ_PHONE_STATE, "Requires READ_PHONE_STATE");
String number = PhoneNumberUtils.extractNetworkPortion(mPhone.getVoiceMailNumber());
if (VDBG) log("VM: PhoneSubInfo.getVoiceMailNUmber: " + number);
return number;
|
private void | log(java.lang.String s)
Rlog.d(LOG_TAG, s);
|
private void | loge(java.lang.String s, java.lang.Throwable e)
Rlog.e(LOG_TAG, s, e);
|