summaryrefslogtreecommitdiffstats
path: root/telephony/java
diff options
context:
space:
mode:
authorWink Saville <wink@google.com>2014-10-23 10:44:45 -0700
committerWink Saville <wink@google.com>2014-10-23 21:54:09 -0700
commit63f03dd94c43c22f2c77306059b5748e5e1e0e3c (patch)
tree33f7e7e60dfb17a98e387a8c8bed02f76a7151b6 /telephony/java
parentee57224c0f96b4a4e26fe89f40509b32ea4b3602 (diff)
downloadframeworks_base-63f03dd94c43c22f2c77306059b5748e5e1e0e3c.zip
frameworks_base-63f03dd94c43c22f2c77306059b5748e5e1e0e3c.tar.gz
frameworks_base-63f03dd94c43c22f2c77306059b5748e5e1e0e3c.tar.bz2
Change subId to int from long
Change-Id: Idae6335e63e7b1e4e714bc17e71b1a4705e38474
Diffstat (limited to 'telephony/java')
-rw-r--r--telephony/java/android/telephony/PhoneNumberUtils.java22
-rw-r--r--telephony/java/android/telephony/PhoneStateListener.java8
-rw-r--r--telephony/java/android/telephony/SubInfoRecord.java8
-rw-r--r--telephony/java/android/telephony/SubscriptionManager.java68
-rw-r--r--telephony/java/android/telephony/TelephonyManager.java84
-rw-r--r--telephony/java/com/android/internal/telephony/CallerInfo.java8
-rw-r--r--telephony/java/com/android/internal/telephony/CallerInfoAsyncQuery.java6
-rw-r--r--telephony/java/com/android/internal/telephony/DcParamObject.java8
-rw-r--r--telephony/java/com/android/internal/telephony/IMms.aidl8
-rw-r--r--telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl28
-rw-r--r--telephony/java/com/android/internal/telephony/ISms.aidl34
-rwxr-xr-xtelephony/java/com/android/internal/telephony/ISub.aidl36
-rw-r--r--telephony/java/com/android/internal/telephony/ITelephony.aidl68
-rw-r--r--telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl24
14 files changed, 205 insertions, 205 deletions
diff --git a/telephony/java/android/telephony/PhoneNumberUtils.java b/telephony/java/android/telephony/PhoneNumberUtils.java
index 27e9baf..897702d 100644
--- a/telephony/java/android/telephony/PhoneNumberUtils.java
+++ b/telephony/java/android/telephony/PhoneNumberUtils.java
@@ -1570,7 +1570,7 @@ public class PhoneNumberUtils
* listed in the RIL / SIM, otherwise return false.
* @hide
*/
- public static boolean isEmergencyNumber(long subId, String number) {
+ public static boolean isEmergencyNumber(int subId, String number) {
// Return true only if the specified number *exactly* matches
// one of the emergency numbers listed by the RIL / SIM.
return isEmergencyNumberInternal(subId, number, true /* useExactMatch */);
@@ -1620,7 +1620,7 @@ public class PhoneNumberUtils
* same digits as any of those emergency numbers.
* @hide
*/
- public static boolean isPotentialEmergencyNumber(long subId, String number) {
+ public static boolean isPotentialEmergencyNumber(int subId, String number) {
// Check against the emergency numbers listed by the RIL / SIM,
// and *don't* require an exact match.
return isEmergencyNumberInternal(subId, number, false /* useExactMatch */);
@@ -1669,7 +1669,7 @@ public class PhoneNumberUtils
* @return true if the number is in the list of emergency numbers
* listed in the RIL / sim, otherwise return false.
*/
- private static boolean isEmergencyNumberInternal(long subId, String number,
+ private static boolean isEmergencyNumberInternal(int subId, String number,
boolean useExactMatch) {
return isEmergencyNumberInternal(subId, number, null, useExactMatch);
}
@@ -1698,7 +1698,7 @@ public class PhoneNumberUtils
* otherwise false
* @hide
*/
- public static boolean isEmergencyNumber(long subId, String number, String defaultCountryIso) {
+ public static boolean isEmergencyNumber(int subId, String number, String defaultCountryIso) {
return isEmergencyNumberInternal(subId, number,
defaultCountryIso,
true /* useExactMatch */);
@@ -1750,7 +1750,7 @@ public class PhoneNumberUtils
* any of those emergency numbers.
* @hide
*/
- public static boolean isPotentialEmergencyNumber(long subId, String number,
+ public static boolean isPotentialEmergencyNumber(int subId, String number,
String defaultCountryIso) {
return isEmergencyNumberInternal(subId, number,
defaultCountryIso,
@@ -1794,7 +1794,7 @@ public class PhoneNumberUtils
* @return true if the number is an emergency number for the specified country.
* @hide
*/
- private static boolean isEmergencyNumberInternal(long subId, String number,
+ private static boolean isEmergencyNumberInternal(int subId, String number,
String defaultCountryIso,
boolean useExactMatch) {
// If the number passed in is null, just return false:
@@ -1911,7 +1911,7 @@ public class PhoneNumberUtils
* is currently in.
* @hide
*/
- public static boolean isLocalEmergencyNumber(Context context, long subId, String number) {
+ public static boolean isLocalEmergencyNumber(Context context, int subId, String number) {
return isLocalEmergencyNumberInternal(subId, number,
context,
true /* useExactMatch */);
@@ -1965,7 +1965,7 @@ public class PhoneNumberUtils
*
* @hide
*/
- public static boolean isPotentialLocalEmergencyNumber(Context context, long subId,
+ public static boolean isPotentialLocalEmergencyNumber(Context context, int subId,
String number) {
return isLocalEmergencyNumberInternal(subId, number,
context,
@@ -2014,7 +2014,7 @@ public class PhoneNumberUtils
* local country, based on the CountryDetector.
* @hide
*/
- private static boolean isLocalEmergencyNumberInternal(long subId, String number,
+ private static boolean isLocalEmergencyNumberInternal(int subId, String number,
Context context,
boolean useExactMatch) {
String countryIso;
@@ -2057,7 +2057,7 @@ public class PhoneNumberUtils
* to read the VM number.
* @hide
*/
- public static boolean isVoiceMailNumber(long subId, String number) {
+ public static boolean isVoiceMailNumber(int subId, String number) {
String vmNumber;
try {
@@ -2796,7 +2796,7 @@ public class PhoneNumberUtils
/**
* Returns Default voice subscription Id.
*/
- private static long getDefaultVoiceSubId() {
+ private static int getDefaultVoiceSubId() {
return SubscriptionManager.getDefaultVoiceSubId();
}
//==== End of utility methods used only in compareStrictly() =====
diff --git a/telephony/java/android/telephony/PhoneStateListener.java b/telephony/java/android/telephony/PhoneStateListener.java
index ec34ce8..2f1a8da 100644
--- a/telephony/java/android/telephony/PhoneStateListener.java
+++ b/telephony/java/android/telephony/PhoneStateListener.java
@@ -227,7 +227,7 @@ public class PhoneStateListener {
* @hide
*/
/** @hide */
- protected long mSubId = SubscriptionManager.INVALID_SUB_ID;
+ protected int mSubId = SubscriptionManager.INVALID_SUB_ID;
private final Handler mHandler;
@@ -252,10 +252,10 @@ public class PhoneStateListener {
/**
* Create a PhoneStateListener for the Phone using the specified subscription.
* This class requires Looper.myLooper() not return null. To supply your
- * own non-null Looper use PhoneStateListener(long subId, Looper looper) below.
+ * own non-null Looper use PhoneStateListener(int subId, Looper looper) below.
* @hide
*/
- public PhoneStateListener(long subId) {
+ public PhoneStateListener(int subId) {
this(subId, Looper.myLooper());
}
@@ -264,7 +264,7 @@ public class PhoneStateListener {
* and non-null Looper.
* @hide
*/
- public PhoneStateListener(long subId, Looper looper) {
+ public PhoneStateListener(int subId, Looper looper) {
if (DBG) log("ctor: subId=" + subId + " looper=" + looper);
mSubId = subId;
mHandler = new Handler(looper) {
diff --git a/telephony/java/android/telephony/SubInfoRecord.java b/telephony/java/android/telephony/SubInfoRecord.java
index f2df079..4a3d67e 100644
--- a/telephony/java/android/telephony/SubInfoRecord.java
+++ b/telephony/java/android/telephony/SubInfoRecord.java
@@ -29,7 +29,7 @@ public class SubInfoRecord implements Parcelable {
* Subscription Identifier, this is a device unique number
* and not an index into an array
*/
- public long subId;
+ public int subId;
/** The GID for a SIM that maybe associated with this subscription, empty if unknown */
public String iccId;
/**
@@ -91,7 +91,7 @@ public class SubInfoRecord implements Parcelable {
this.mnc = 0;
}
- public SubInfoRecord(long subId, String iccId, int slotId, String displayName, int nameSource,
+ public SubInfoRecord(int subId, String iccId, int slotId, String displayName, int nameSource,
int color, String number, int displayFormat, int roaming, int[] iconRes,
int mcc, int mnc) {
this.subId = subId;
@@ -136,7 +136,7 @@ public class SubInfoRecord implements Parcelable {
public static final Parcelable.Creator<SubInfoRecord> CREATOR = new Parcelable.Creator<SubInfoRecord>() {
@Override
public SubInfoRecord createFromParcel(Parcel source) {
- long subId = source.readLong();
+ int subId = source.readInt();
String iccId = source.readString();
int slotId = source.readInt();
String displayName = source.readString();
@@ -162,7 +162,7 @@ public class SubInfoRecord implements Parcelable {
@Override
public void writeToParcel(Parcel dest, int flags) {
- dest.writeLong(subId);
+ dest.writeInt(subId);
dest.writeString(iccId);
dest.writeInt(slotId);
dest.writeString(displayName);
diff --git a/telephony/java/android/telephony/SubscriptionManager.java b/telephony/java/android/telephony/SubscriptionManager.java
index c96c383..c3ad826 100644
--- a/telephony/java/android/telephony/SubscriptionManager.java
+++ b/telephony/java/android/telephony/SubscriptionManager.java
@@ -57,21 +57,21 @@ public class SubscriptionManager implements BaseColumns {
public static final int DEFAULT_SLOT_ID = Integer.MAX_VALUE;
/** Indicates the user should be asked which subscription to use. */
- public static final long ASK_USER_SUB_ID = -1001;
+ public static final int ASK_USER_SUB_ID = -1001;
/** An invalid subscription identifier */
- public static final long INVALID_SUB_ID = -1000;
+ public static final int INVALID_SUB_ID = -1000;
/** Indicates the caller wants the default sub id. */
- public static final long DEFAULT_SUB_ID = Long.MAX_VALUE;
+ public static final int DEFAULT_SUB_ID = Integer.MAX_VALUE;
/** Minimum possible subid that represents a subscription */
/** @hide */
- public static final long MIN_SUB_ID_VALUE = 0;
+ public static final int MIN_SUB_ID_VALUE = 0;
/** Maximum possible subid that represents a subscription */
/** @hide */
- public static final long MAX_SUB_ID_VALUE = DEFAULT_SUB_ID - 1;
+ public static final int MAX_SUB_ID_VALUE = DEFAULT_SUB_ID - 1;
/** @hide */
@@ -265,7 +265,7 @@ public class SubscriptionManager implements BaseColumns {
* @param subId The unique SubInfoRecord index in database
* @return SubInfoRecord, maybe null
*/
- public static SubInfoRecord getSubInfoForSubscriber(long subId) {
+ public static SubInfoRecord getSubInfoForSubscriber(int subId) {
if (!isValidSubId(subId)) {
logd("[getSubInfoForSubscriberx]- invalid subId");
return null;
@@ -475,7 +475,7 @@ public class SubscriptionManager implements BaseColumns {
* @return the number of records updated
* @hide
*/
- public static int setColor(int color, long subId) {
+ public static int setColor(int color, int subId) {
if (VDBG) logd("[setColor]+ color:" + color + " subId:" + subId);
int size = sSimBackgroundDarkRes.length;
if (!isValidSubId(subId) || color < 0 || color >= size) {
@@ -505,7 +505,7 @@ public class SubscriptionManager implements BaseColumns {
* @return the number of records updated
* @hide
*/
- public static int setDisplayName(String displayName, long subId) {
+ public static int setDisplayName(String displayName, int subId) {
return setDisplayName(displayName, subId, NAME_SOURCE_UNDEFINDED);
}
@@ -518,7 +518,7 @@ public class SubscriptionManager implements BaseColumns {
* @return the number of records updated or -1 if invalid subId
* @hide
*/
- public static int setDisplayName(String displayName, long subId, long nameSource) {
+ public static int setDisplayName(String displayName, int subId, long nameSource) {
if (VDBG) {
logd("[setDisplayName]+ displayName:" + displayName + " subId:" + subId
+ " nameSource:" + nameSource);
@@ -550,7 +550,7 @@ public class SubscriptionManager implements BaseColumns {
* @return the number of records updated
* @hide
*/
- public static int setDisplayNumber(String number, long subId) {
+ public static int setDisplayNumber(String number, int subId) {
if (number == null || !isValidSubId(subId)) {
logd("[setDisplayNumber]- fail");
return -1;
@@ -578,7 +578,7 @@ public class SubscriptionManager implements BaseColumns {
* @return the number of records updated
* @hide
*/
- public static int setDisplayNumberFormat(int format, long subId) {
+ public static int setDisplayNumberFormat(int format, int subId) {
if (VDBG) logd("[setDisplayNumberFormat]+ format:" + format + " subId:" + subId);
if (format < 0 || !isValidSubId(subId)) {
logd("[setDisplayNumberFormat]- fail, return -1");
@@ -607,7 +607,7 @@ public class SubscriptionManager implements BaseColumns {
* @return the number of records updated
* @hide
*/
- public static int setDataRoaming(int roaming, long subId) {
+ public static int setDataRoaming(int roaming, int subId) {
if (VDBG) logd("[setDataRoaming]+ roaming:" + roaming + " subId:" + subId);
if (roaming < 0 || !isValidSubId(subId)) {
logd("[setDataRoaming]- fail");
@@ -633,7 +633,7 @@ public class SubscriptionManager implements BaseColumns {
* @return slotId as a positive integer or a negative value if an error either
* SIM_NOT_INSERTED or INVALID_SLOT_ID.
*/
- public static int getSlotId(long subId) {
+ public static int getSlotId(int subId) {
if (!isValidSubId(subId)) {
logd("[getSlotId]- fail");
}
@@ -654,13 +654,13 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static long[] getSubId(int slotId) {
+ public static int[] getSubId(int slotId) {
if (!isValidSlotId(slotId)) {
logd("[getSubId]- fail");
return null;
}
- long[] subId = null;
+ int[] subId = null;
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -675,7 +675,7 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static int getPhoneId(long subId) {
+ public static int getPhoneId(int subId) {
if (!isValidSubId(subId)) {
logd("[getPhoneId]- fail");
return INVALID_PHONE_ID;
@@ -732,8 +732,8 @@ public class SubscriptionManager implements BaseColumns {
* getDefaultDataSubId().
* @hide
*/
- public static long getDefaultSubId() {
- long subId = INVALID_SUB_ID;
+ public static int getDefaultSubId() {
+ int subId = INVALID_SUB_ID;
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -749,8 +749,8 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static long getDefaultVoiceSubId() {
- long subId = INVALID_SUB_ID;
+ public static int getDefaultVoiceSubId() {
+ int subId = INVALID_SUB_ID;
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -766,7 +766,7 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static void setDefaultVoiceSubId(long subId) {
+ public static void setDefaultVoiceSubId(int subId) {
if (VDBG) logd("setDefaultVoiceSubId sub id = " + subId);
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -791,8 +791,8 @@ public class SubscriptionManager implements BaseColumns {
/**
* @return subId of the DefaultSms subscription or the value INVALID_SUB_ID if an error.
*/
- public static long getDefaultSmsSubId() {
- long subId = INVALID_SUB_ID;
+ public static int getDefaultSmsSubId() {
+ int subId = INVALID_SUB_ID;
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -808,7 +808,7 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static void setDefaultSmsSubId(long subId) {
+ public static void setDefaultSmsSubId(int subId) {
if (VDBG) logd("setDefaultSmsSubId sub id = " + subId);
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -831,8 +831,8 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static long getDefaultDataSubId() {
- long subId = INVALID_SUB_ID;
+ public static int getDefaultDataSubId() {
+ int subId = INVALID_SUB_ID;
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -848,7 +848,7 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static void setDefaultDataSubId(long subId) {
+ public static void setDefaultDataSubId(int subId) {
if (VDBG) logd("setDataSubscription sub id = " + subId);
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -919,7 +919,7 @@ public class SubscriptionManager implements BaseColumns {
/**
* @return true if a valid subId else false
*/
- public static boolean isValidSubId(long subId) {
+ public static boolean isValidSubId(int subId) {
return subId > INVALID_SUB_ID ;
}
@@ -928,7 +928,7 @@ public class SubscriptionManager implements BaseColumns {
* usable subId means its neither a INVALID_SUB_ID nor a DEFAUL_SUB_ID.
* @hide
*/
- public static boolean isUsableSubIdValue(long subId) {
+ public static boolean isUsableSubIdValue(int subId) {
return subId >= MIN_SUB_ID_VALUE && subId <= MAX_SUB_ID_VALUE;
}
@@ -952,7 +952,7 @@ public class SubscriptionManager implements BaseColumns {
/** @hide */
public static void putPhoneIdAndSubIdExtra(Intent intent, int phoneId) {
- long[] subIds = SubscriptionManager.getSubId(phoneId);
+ int[] subIds = SubscriptionManager.getSubId(phoneId);
if (subIds != null && subIds.length > 0) {
putPhoneIdAndSubIdExtra(intent, phoneId, subIds[0]);
} else {
@@ -961,7 +961,7 @@ public class SubscriptionManager implements BaseColumns {
}
/** @hide */
- public static void putPhoneIdAndSubIdExtra(Intent intent, int phoneId, long subId) {
+ public static void putPhoneIdAndSubIdExtra(Intent intent, int phoneId, int subId) {
if (VDBG) logd("putPhoneIdAndSubIdExtra: phoneId=" + phoneId + " subId=" + subId);
intent.putExtra(PhoneConstants.SUBSCRIPTION_KEY, subId);
intent.putExtra(PhoneConstants.PHONE_KEY, phoneId);
@@ -975,8 +975,8 @@ public class SubscriptionManager implements BaseColumns {
* is never null but the length maybe 0.
* @hide
*/
- public static long[] getActiveSubIdList() {
- long[] subId = null;
+ public static int[] getActiveSubIdList() {
+ int[] subId = null;
try {
ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -988,7 +988,7 @@ public class SubscriptionManager implements BaseColumns {
}
if (subId == null) {
- subId = new long[0];
+ subId = new int[0];
}
return subId;
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index 7b5234a..a3546ed 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -588,7 +588,7 @@ public class TelephonyManager {
/** {@hide} */
public String getDeviceSoftwareVersion(int slotId) {
// FIXME methods taking slot id should not use subscription, instead us Uicc directly
- long[] subId = SubscriptionManager.getSubId(slotId);
+ int[] subId = SubscriptionManager.getSubId(slotId);
if (subId == null || subId.length == 0) {
return null;
}
@@ -624,7 +624,7 @@ public class TelephonyManager {
/** {@hide} */
public String getDeviceId(int slotId) {
// FIXME methods taking slot id should not use subscription, instead us Uicc directly
- long[] subId = SubscriptionManager.getSubId(slotId);
+ int[] subId = SubscriptionManager.getSubId(slotId);
if (subId == null || subId.length == 0) {
return null;
}
@@ -658,7 +658,7 @@ public class TelephonyManager {
*/
/** {@hide} */
public String getImei(int slotId) {
- long[] subId = SubscriptionManager.getSubId(slotId);
+ int[] subId = SubscriptionManager.getSubId(slotId);
try {
return getSubscriberInfo().getImeiForSubscriber(subId[0]);
} catch (RemoteException ex) {
@@ -684,7 +684,7 @@ public class TelephonyManager {
*/
/** {@hide}*/
public String getNai(int slotId) {
- long[] subId = SubscriptionManager.getSubId(slotId);
+ int[] subId = SubscriptionManager.getSubId(slotId);
try {
return getSubscriberInfo().getNaiForSubscriber(subId[0]);
} catch (RemoteException ex) {
@@ -748,7 +748,7 @@ public class TelephonyManager {
* @param subId for which the location updates are enabled
*/
/** @hide */
- public void enableLocationUpdates(long subId) {
+ public void enableLocationUpdates(int subId) {
try {
getITelephony().enableLocationUpdatesForSubscriber(subId);
} catch (RemoteException ex) {
@@ -770,7 +770,7 @@ public class TelephonyManager {
}
/** @hide */
- public void disableLocationUpdates(long subId) {
+ public void disableLocationUpdates(int subId) {
try {
getITelephony().disableLocationUpdatesForSubscriber(subId);
} catch (RemoteException ex) {
@@ -835,7 +835,7 @@ public class TelephonyManager {
*/
/** {@hide} */
@SystemApi
- public int getCurrentPhoneType(long subId) {
+ public int getCurrentPhoneType(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
try{
ITelephony telephony = getITelephony();
@@ -1047,7 +1047,7 @@ public class TelephonyManager {
* @param subId
*/
/** {@hide} */
- public String getNetworkOperatorName(long subId) {
+ public String getNetworkOperatorName(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
return getTelephonyProperty(phoneId, TelephonyProperties.PROPERTY_OPERATOR_ALPHA, "");
}
@@ -1074,7 +1074,7 @@ public class TelephonyManager {
* @param subId
*/
/** {@hide} */
- public String getNetworkOperator(long subId) {
+ public String getNetworkOperator(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
return getTelephonyProperty(phoneId, TelephonyProperties.PROPERTY_OPERATOR_NUMERIC, "");
}
@@ -1098,7 +1098,7 @@ public class TelephonyManager {
* @param subId
*/
/** {@hide} */
- public boolean isNetworkRoaming(long subId) {
+ public boolean isNetworkRoaming(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
return Boolean.parseBoolean(getTelephonyProperty(phoneId,
TelephonyProperties.PROPERTY_OPERATOR_ISROAMING, null));
@@ -1127,7 +1127,7 @@ public class TelephonyManager {
* @param subId for which Network CountryIso is returned
*/
/** {@hide} */
- public String getNetworkCountryIso(long subId) {
+ public String getNetworkCountryIso(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
return getTelephonyProperty(phoneId, TelephonyProperties.PROPERTY_OPERATOR_ISO_COUNTRY, "");
}
@@ -1199,7 +1199,7 @@ public class TelephonyManager {
* @see #NETWORK_TYPE_HSPAP
*/
/** {@hide} */
- public int getNetworkType(long subId) {
+ public int getNetworkType(int subId) {
try {
ITelephony telephony = getITelephony();
if (telephony != null) {
@@ -1253,7 +1253,7 @@ public class TelephonyManager {
* @param subId for which network type is returned
*/
/** {@hide} */
- public int getDataNetworkType(long subId) {
+ public int getDataNetworkType(int subId) {
try{
ITelephony telephony = getITelephony();
if (telephony != null) {
@@ -1285,7 +1285,7 @@ public class TelephonyManager {
*
*/
/** {@hide} */
- public int getVoiceNetworkType(long subId) {
+ public int getVoiceNetworkType(int subId) {
try{
ITelephony telephony = getITelephony();
if (telephony != null) {
@@ -1442,7 +1442,7 @@ public class TelephonyManager {
*/
/** {@hide} */
// FIXME Input argument slotId should be of type int
- public boolean hasIccCard(long slotId) {
+ public boolean hasIccCard(int slotId) {
try {
return getITelephony().hasIccCardUsingSlotId(slotId);
@@ -1487,7 +1487,7 @@ public class TelephonyManager {
/** {@hide} */
// FIXME the argument to pass is subId ??
public int getSimState(int slotId) {
- long[] subId = SubscriptionManager.getSubId(slotId);
+ int[] subId = SubscriptionManager.getSubId(slotId);
if (subId == null || subId.length == 0) {
return SIM_STATE_ABSENT;
}
@@ -1527,7 +1527,7 @@ public class TelephonyManager {
* @see #getSimState
*/
public String getSimOperator() {
- long subId = SubscriptionManager.getDefaultDataSubId();
+ int subId = SubscriptionManager.getDefaultDataSubId();
if (!SubscriptionManager.isUsableSubIdValue(subId)) {
subId = SubscriptionManager.getDefaultSmsSubId();
if (!SubscriptionManager.isUsableSubIdValue(subId)) {
@@ -1552,7 +1552,7 @@ public class TelephonyManager {
* @param subId for which SimOperator is returned
*/
/** {@hide} */
- public String getSimOperator(long subId) {
+ public String getSimOperator(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
String operator = getTelephonyProperty(phoneId,
TelephonyProperties.PROPERTY_ICC_OPERATOR_NUMERIC, "");
@@ -1581,7 +1581,7 @@ public class TelephonyManager {
* @param subId for which SimOperatorName is returned
*/
/** {@hide} */
- public String getSimOperatorName(long subId) {
+ public String getSimOperatorName(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
return getTelephonyProperty(phoneId, TelephonyProperties.PROPERTY_ICC_OPERATOR_ALPHA, "");
}
@@ -1599,7 +1599,7 @@ public class TelephonyManager {
* @param subId for which SimCountryIso is returned
*/
/** {@hide} */
- public String getSimCountryIso(long subId) {
+ public String getSimCountryIso(int subId) {
int phoneId = SubscriptionManager.getPhoneId(subId);
return getTelephonyProperty(phoneId, TelephonyProperties.PROPERTY_ICC_OPERATOR_ISO_COUNTRY,
"");
@@ -1625,7 +1625,7 @@ public class TelephonyManager {
* {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
*/
/** {@hide} */
- public String getSimSerialNumber(long subId) {
+ public String getSimSerialNumber(int subId) {
try {
return getSubscriberInfo().getIccSerialNumberForSubscriber(subId);
} catch (RemoteException ex) {
@@ -1661,7 +1661,7 @@ public class TelephonyManager {
*
*/
/** {@hide} */
- public int getLteOnCdmaMode(long subId) {
+ public int getLteOnCdmaMode(int subId) {
try {
return getITelephony().getLteOnCdmaModeForSubscriber(subId);
} catch (RemoteException ex) {
@@ -1701,7 +1701,7 @@ public class TelephonyManager {
* @param subId whose subscriber id is returned
*/
/** {@hide} */
- public String getSubscriberId(long subId) {
+ public String getSubscriberId(int subId) {
try {
return getSubscriberInfo().getSubscriberIdForSubscriber(subId);
} catch (RemoteException ex) {
@@ -1740,7 +1740,7 @@ public class TelephonyManager {
* @param subscription whose subscriber id is returned
*/
/** {@hide} */
- public String getGroupIdLevel1(long subId) {
+ public String getGroupIdLevel1(int subId) {
try {
return getSubscriberInfo().getGroupIdLevel1ForSubscriber(subId);
} catch (RemoteException ex) {
@@ -1772,7 +1772,7 @@ public class TelephonyManager {
* @param subId whose phone number for line 1 is returned
*/
/** {@hide} */
- public String getLine1NumberForSubscriber(long subId) {
+ public String getLine1NumberForSubscriber(int subId) {
String number = null;
try {
number = getITelephony().getLine1NumberForDisplay(subId);
@@ -1824,7 +1824,7 @@ public class TelephonyManager {
* @param number The dialing number
* @hide
*/
- public void setLine1NumberForDisplayForSubscriber(long subId, String alphaTag, String number) {
+ public void setLine1NumberForDisplayForSubscriber(int subId, String alphaTag, String number) {
try {
getITelephony().setLine1NumberForDisplayForSubscriber(subId, alphaTag, number);
} catch (RemoteException ex) {
@@ -1856,7 +1856,7 @@ public class TelephonyManager {
* nobody seems to call this.
*/
/** {@hide} */
- public String getLine1AlphaTagForSubscriber(long subId) {
+ public String getLine1AlphaTagForSubscriber(int subId) {
String alphaTag = null;
try {
alphaTag = getITelephony().getLine1AlphaTagForDisplay(subId);
@@ -1899,7 +1899,7 @@ public class TelephonyManager {
* @param subId for which msisdn is returned
*/
/** {@hide} */
- public String getMsisdn(long subId) {
+ public String getMsisdn(int subId) {
try {
return getSubscriberInfo().getMsisdnForSubscriber(subId);
} catch (RemoteException ex) {
@@ -1929,7 +1929,7 @@ public class TelephonyManager {
* @param subId whose voice mail number is returned
*/
/** {@hide} */
- public String getVoiceMailNumber(long subId) {
+ public String getVoiceMailNumber(int subId) {
try {
return getSubscriberInfo().getVoiceMailNumberForSubscriber(subId);
} catch (RemoteException ex) {
@@ -1961,7 +1961,7 @@ public class TelephonyManager {
* @param subId
*/
/** {@hide} */
- public String getCompleteVoiceMailNumber(long subId) {
+ public String getCompleteVoiceMailNumber(int subId) {
try {
return getSubscriberInfo().getCompleteVoiceMailNumberForSubscriber(subId);
} catch (RemoteException ex) {
@@ -1991,7 +1991,7 @@ public class TelephonyManager {
* @param subId whose voice message count is returned
*/
/** {@hide} */
- public int getVoiceMessageCount(long subId) {
+ public int getVoiceMessageCount(int subId) {
try {
return getITelephony().getVoiceMessageCountForSubscriber(subId);
} catch (RemoteException ex) {
@@ -2023,7 +2023,7 @@ public class TelephonyManager {
* voice mail number is returned
*/
/** {@hide} */
- public String getVoiceMailAlphaTag(long subId) {
+ public String getVoiceMailAlphaTag(int subId) {
try {
return getSubscriberInfo().getVoiceMailAlphaTagForSubscriber(subId);
} catch (RemoteException ex) {
@@ -2120,7 +2120,7 @@ public class TelephonyManager {
* @param subId whose call state is returned
*/
/** {@hide} */
- public int getCallState(long subId) {
+ public int getCallState(int subId) {
try {
return getITelephony().getCallStateForSubscriber(subId);
} catch (RemoteException ex) {
@@ -2271,7 +2271,7 @@ public class TelephonyManager {
* Returns the CDMA ERI icon index to display for a subscription
*/
/** {@hide} */
- public int getCdmaEriIconIndex(long subId) {
+ public int getCdmaEriIconIndex(int subId) {
try {
return getITelephony().getCdmaEriIconIndexForSubscriber(subId);
} catch (RemoteException ex) {
@@ -2299,7 +2299,7 @@ public class TelephonyManager {
* 1 - FLASHING
*/
/** {@hide} */
- public int getCdmaEriIconMode(long subId) {
+ public int getCdmaEriIconMode(int subId) {
try {
return getITelephony().getCdmaEriIconModeForSubscriber(subId);
} catch (RemoteException ex) {
@@ -2324,7 +2324,7 @@ public class TelephonyManager {
*
*/
/** {@hide} */
- public String getCdmaEriText(long subId) {
+ public String getCdmaEriText(int subId) {
try {
return getITelephony().getCdmaEriTextForSubscriber(subId);
} catch (RemoteException ex) {
@@ -2696,7 +2696,7 @@ public class TelephonyManager {
/**
* Returns Default subscription.
*/
- private static long getDefaultSubscription() {
+ private static int getDefaultSubscription() {
return SubscriptionManager.getDefaultSubId();
}
@@ -2938,7 +2938,7 @@ public class TelephonyManager {
* @return the response of SIM Authentication, or null if not available
* @hide
*/
- public String getIccSimChallengeResponse(long subId, int appType, String data) {
+ public String getIccSimChallengeResponse(int subId, int appType, String data) {
try {
return getSubscriberInfo().getIccSimChallengeResponse(subId, appType, data);
} catch (RemoteException ex) {
@@ -3119,7 +3119,7 @@ public class TelephonyManager {
/** @hide */
@SystemApi
- public String getCdmaMdn(long subId) {
+ public String getCdmaMdn(int subId) {
try {
return getITelephony().getCdmaMdn(subId);
} catch (RemoteException ex) {
@@ -3137,7 +3137,7 @@ public class TelephonyManager {
/** @hide */
@SystemApi
- public String getCdmaMin(long subId) {
+ public String getCdmaMin(int subId) {
try {
return getITelephony().getCdmaMin(subId);
} catch (RemoteException ex) {
@@ -3468,7 +3468,7 @@ public class TelephonyManager {
* @param enable true means enabling the simplified UI.
* @hide
*/
- public void enableSimplifiedNetworkSettingsForSubscriber(long subId, boolean enable) {
+ public void enableSimplifiedNetworkSettingsForSubscriber(int subId, boolean enable) {
try {
getITelephony().enableSimplifiedNetworkSettingsForSubscriber(subId, enable);
} catch (RemoteException ex) {
@@ -3501,7 +3501,7 @@ public class TelephonyManager {
* @return true if the simplified UI is enabled.
* @hide
*/
- public boolean getSimplifiedNetworkSettingsEnabledForSubscriber(long subId) {
+ public boolean getSimplifiedNetworkSettingsEnabledForSubscriber(int subId) {
try {
return getITelephony().getSimplifiedNetworkSettingsEnabledForSubscriber(subId);
} catch (RemoteException ex) {
diff --git a/telephony/java/com/android/internal/telephony/CallerInfo.java b/telephony/java/com/android/internal/telephony/CallerInfo.java
index 88e5bd6..5cd5d4e 100644
--- a/telephony/java/com/android/internal/telephony/CallerInfo.java
+++ b/telephony/java/com/android/internal/telephony/CallerInfo.java
@@ -301,7 +301,7 @@ public class CallerInfo {
public static CallerInfo getCallerInfo(Context context, String number) {
if (VDBG) Rlog.v(TAG, "getCallerInfo() based on number...");
- long subId = SubscriptionManager.getDefaultSubId();
+ int subId = SubscriptionManager.getDefaultSubId();
return getCallerInfo(context, number, subId);
}
@@ -316,7 +316,7 @@ public class CallerInfo {
* a matching number is not found, then a generic caller info is returned,
* with all relevant fields empty or null.
*/
- public static CallerInfo getCallerInfo(Context context, String number, long subId) {
+ public static CallerInfo getCallerInfo(Context context, String number, int subId) {
if (TextUtils.isEmpty(number)) {
return null;
@@ -418,12 +418,12 @@ public class CallerInfo {
// string in the phone number field.
/* package */ CallerInfo markAsVoiceMail() {
- long subId = SubscriptionManager.getDefaultSubId();
+ int subId = SubscriptionManager.getDefaultSubId();
return markAsVoiceMail(subId);
}
- /* package */ CallerInfo markAsVoiceMail(long subId) {
+ /* package */ CallerInfo markAsVoiceMail(int subId) {
mIsVoiceMail = true;
try {
diff --git a/telephony/java/com/android/internal/telephony/CallerInfoAsyncQuery.java b/telephony/java/com/android/internal/telephony/CallerInfoAsyncQuery.java
index 0d18389..aae7617 100644
--- a/telephony/java/com/android/internal/telephony/CallerInfoAsyncQuery.java
+++ b/telephony/java/com/android/internal/telephony/CallerInfoAsyncQuery.java
@@ -81,7 +81,7 @@ public class CallerInfoAsyncQuery {
public int event;
public String number;
- public long subId;
+ public int subId;
}
@@ -388,7 +388,7 @@ public class CallerInfoAsyncQuery {
public static CallerInfoAsyncQuery startQuery(int token, Context context, String number,
OnQueryCompleteListener listener, Object cookie) {
- long subId = SubscriptionManager.getDefaultSubId();
+ int subId = SubscriptionManager.getDefaultSubId();
return startQuery(token, context, number, listener, cookie, subId);
}
@@ -404,7 +404,7 @@ public class CallerInfoAsyncQuery {
* the phone type of the incoming connection.
*/
public static CallerInfoAsyncQuery startQuery(int token, Context context, String number,
- OnQueryCompleteListener listener, Object cookie, long subId) {
+ OnQueryCompleteListener listener, Object cookie, int subId) {
if (DBG) {
Rlog.d(LOG_TAG, "##### CallerInfoAsyncQuery startQuery()... #####");
diff --git a/telephony/java/com/android/internal/telephony/DcParamObject.java b/telephony/java/com/android/internal/telephony/DcParamObject.java
index c92988f..139939c 100644
--- a/telephony/java/com/android/internal/telephony/DcParamObject.java
+++ b/telephony/java/com/android/internal/telephony/DcParamObject.java
@@ -21,9 +21,9 @@ import android.os.Parcel;
public class DcParamObject implements Parcelable {
- private long mSubId;
+ private int mSubId;
- public DcParamObject(long subId) {
+ public DcParamObject(int subId) {
mSubId = subId;
}
@@ -40,7 +40,7 @@ public class DcParamObject implements Parcelable {
}
private void readFromParcel(Parcel in) {
- mSubId = in.readLong();
+ mSubId = in.readInt();
}
public static final Parcelable.Creator<DcParamObject> CREATOR = new Parcelable.Creator<DcParamObject>() {
@@ -52,7 +52,7 @@ public class DcParamObject implements Parcelable {
}
};
- public long getSubId() {
+ public int getSubId() {
return mSubId;
}
}
diff --git a/telephony/java/com/android/internal/telephony/IMms.aidl b/telephony/java/com/android/internal/telephony/IMms.aidl
index ebfefd1..0322499 100644
--- a/telephony/java/com/android/internal/telephony/IMms.aidl
+++ b/telephony/java/com/android/internal/telephony/IMms.aidl
@@ -39,7 +39,7 @@ interface IMms {
* @param sentIntent if not NULL this <code>PendingIntent</code> is
* broadcast when the message is successfully sent, or failed
*/
- void sendMessage(long subId, String callingPkg, in Uri contentUri,
+ void sendMessage(int subId, String callingPkg, in Uri contentUri,
String locationUrl, in Bundle configOverrides, in PendingIntent sentIntent);
/**
@@ -56,7 +56,7 @@ interface IMms {
* @param downloadedIntent if not NULL this <code>PendingIntent</code> is
* broadcast when the message is downloaded, or the download is failed
*/
- void downloadMessage(long subId, String callingPkg, String locationUrl,
+ void downloadMessage(int subId, String callingPkg, String locationUrl,
in Uri contentUri, in Bundle configOverrides,
in PendingIntent downloadedIntent);
@@ -99,7 +99,7 @@ interface IMms {
*
* @param subId the SIM id
*/
- Bundle getCarrierConfigValues(long subId);
+ Bundle getCarrierConfigValues(int subId);
/**
* Import a text message into system's SMS store
@@ -204,7 +204,7 @@ interface IMms {
* @param sentIntent if not NULL this <code>PendingIntent</code> is
* broadcast when the message is successfully sent, or failed
*/
- void sendStoredMessage(long subId, String callingPkg, in Uri messageUri,
+ void sendStoredMessage(int subId, String callingPkg, in Uri messageUri,
in Bundle configOverrides, in PendingIntent sentIntent);
/**
diff --git a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
index 98fd70c..eec5333 100644
--- a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
+++ b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
@@ -30,18 +30,18 @@ interface IPhoneSubInfo {
/**
* Retrieves the unique Network Access ID
*/
- String getNaiForSubscriber(long subId);
+ String getNaiForSubscriber(int subId);
/**
* Retrieves the unique device ID of a subId for the device, e.g., IMEI
* for GSM phones.
*/
- String getDeviceIdForSubscriber(long subId);
+ String getDeviceIdForSubscriber(int subId);
/**
* Retrieves the IMEI.
*/
- String getImeiForSubscriber(long subId);
+ String getImeiForSubscriber(int subId);
/**
* Retrieves the software version number for the device, e.g., IMEI/SV
@@ -53,7 +53,7 @@ interface IPhoneSubInfo {
* Retrieves the software version number of a subId for the device, e.g., IMEI/SV
* for GSM phones.
*/
- String getDeviceSvnUsingSubId(long subId);
+ String getDeviceSvnUsingSubId(int subId);
/**
* Retrieves the unique sbuscriber ID, e.g., IMSI for GSM phones.
@@ -63,7 +63,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the unique subscriber ID of a given subId, e.g., IMSI for GSM phones.
*/
- String getSubscriberIdForSubscriber(long subId);
+ String getSubscriberIdForSubscriber(int subId);
/**
* Retrieves the Group Identifier Level1 for GSM phones.
@@ -73,7 +73,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the Group Identifier Level1 for GSM phones of a subId.
*/
- String getGroupIdLevel1ForSubscriber(long subId);
+ String getGroupIdLevel1ForSubscriber(int subId);
/**
* Retrieves the serial number of the ICC, if applicable.
@@ -83,7 +83,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the serial number of a given subId.
*/
- String getIccSerialNumberForSubscriber(long subId);
+ String getIccSerialNumberForSubscriber(int subId);
/**
* Retrieves the phone number string for line 1.
@@ -93,7 +93,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the phone number string for line 1 of a subcription.
*/
- String getLine1NumberForSubscriber(long subId);
+ String getLine1NumberForSubscriber(int subId);
/**
@@ -104,7 +104,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the alpha identifier for line 1 of a subId.
*/
- String getLine1AlphaTagForSubscriber(long subId);
+ String getLine1AlphaTagForSubscriber(int subId);
/**
@@ -115,7 +115,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the Msisdn of a subId.
*/
- String getMsisdnForSubscriber(long subId);
+ String getMsisdnForSubscriber(int subId);
/**
* Retrieves the voice mail number.
@@ -125,7 +125,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the voice mail number of a given subId.
*/
- String getVoiceMailNumberForSubscriber(long subId);
+ String getVoiceMailNumberForSubscriber(int subId);
/**
* Retrieves the complete voice mail number.
@@ -135,7 +135,7 @@ interface IPhoneSubInfo {
/**
* Retrieves the complete voice mail number for particular subId
*/
- String getCompleteVoiceMailNumberForSubscriber(long subId);
+ String getCompleteVoiceMailNumberForSubscriber(int subId);
/**
* Retrieves the alpha identifier associated with the voice mail number.
@@ -146,7 +146,7 @@ interface IPhoneSubInfo {
* Retrieves the alpha identifier associated with the voice mail number
* of a subId.
*/
- String getVoiceMailAlphaTagForSubscriber(long subId);
+ String getVoiceMailAlphaTagForSubscriber(int subId);
/**
* Returns the IMS private user identity (IMPI) that was loaded from the ISIM.
@@ -199,5 +199,5 @@ interface IPhoneSubInfo {
* @param data authentication challenge data
* @return challenge response
*/
- String getIccSimChallengeResponse(long subId, int appType, String data);
+ String getIccSimChallengeResponse(int subId, int appType, String data);
}
diff --git a/telephony/java/com/android/internal/telephony/ISms.aidl b/telephony/java/com/android/internal/telephony/ISms.aidl
index 32bb8b4..560af45 100644
--- a/telephony/java/com/android/internal/telephony/ISms.aidl
+++ b/telephony/java/com/android/internal/telephony/ISms.aidl
@@ -47,7 +47,7 @@ interface ISms {
* @param subId the subId id.
* @return list of SmsRawData of all sms on ICC
*/
- List<SmsRawData> getAllMessagesFromIccEfForSubscriber(in long subId, String callingPkg);
+ List<SmsRawData> getAllMessagesFromIccEfForSubscriber(in int subId, String callingPkg);
/**
* Update the specified message on the ICC.
@@ -75,7 +75,7 @@ interface ISms {
* @return success or not
*
*/
- boolean updateMessageOnIccEfForSubscriber(in long subId, String callingPkg,
+ boolean updateMessageOnIccEfForSubscriber(in int subId, String callingPkg,
int messageIndex, int newStatus, in byte[] pdu);
/**
@@ -99,7 +99,7 @@ interface ISms {
* @return success or not
*
*/
- boolean copyMessageToIccEfForSubscriber(in long subId, String callingPkg, int status,
+ boolean copyMessageToIccEfForSubscriber(in int subId, String callingPkg, int status,
in byte[] pdu, in byte[] smsc);
/**
@@ -152,7 +152,7 @@ interface ISms {
* raw pdu of the status report is in the extended data ("pdu").
* @param subId the subId id.
*/
- void sendDataForSubscriber(long subId, String callingPkg, in String destAddr,
+ void sendDataForSubscriber(int subId, String callingPkg, in String destAddr,
in String scAddr, in int destPort, in byte[] data, in PendingIntent sentIntent,
in PendingIntent deliveryIntent);
@@ -206,7 +206,7 @@ interface ISms {
* raw pdu of the status report is in the extended data ("pdu").
* @param subId the subId on which the SMS has to be sent.
*/
- void sendTextForSubscriber(in long subId, String callingPkg, in String destAddr,
+ void sendTextForSubscriber(in int subId, String callingPkg, in String destAddr,
in String scAddr, in String text, in PendingIntent sentIntent,
in PendingIntent deliveryIntent);
@@ -283,7 +283,7 @@ interface ISms {
* extended data ("pdu").
* @param subId the subId on which the SMS has to be sent.
*/
- void sendMultipartTextForSubscriber(in long subId, String callingPkg,
+ void sendMultipartTextForSubscriber(in int subId, String callingPkg,
in String destinationAddress, in String scAddress,
in List<String> parts, in List<PendingIntent> sentIntents,
in List<PendingIntent> deliveryIntents);
@@ -315,7 +315,7 @@ interface ISms {
*
* @see #disableCellBroadcast(int)
*/
- boolean enableCellBroadcastForSubscriber(in long subId, int messageIdentifier);
+ boolean enableCellBroadcastForSubscriber(in int subId, int messageIdentifier);
/**
* Disable reception of cell broadcast (SMS-CB) messages with the given
@@ -344,7 +344,7 @@ interface ISms {
*
* @see #enableCellBroadcast(int)
*/
- boolean disableCellBroadcastForSubscriber(in long subId, int messageIdentifier);
+ boolean disableCellBroadcastForSubscriber(in int subId, int messageIdentifier);
/*
* Enable reception of cell broadcast (SMS-CB) messages with the given
@@ -377,7 +377,7 @@ interface ISms {
*
* @see #disableCellBroadcastRange(int, int)
*/
- boolean enableCellBroadcastRangeForSubscriber(long subId, int startMessageId, int endMessageId);
+ boolean enableCellBroadcastRangeForSubscriber(int subId, int startMessageId, int endMessageId);
/**
* Disable reception of cell broadcast (SMS-CB) messages with the given
@@ -410,7 +410,7 @@ interface ISms {
*
* @see #enableCellBroadcastRange(int, int, int)
*/
- boolean disableCellBroadcastRangeForSubscriber(long subId, int startMessageId,
+ boolean disableCellBroadcastRangeForSubscriber(int subId, int startMessageId,
int endMessageId);
/**
@@ -423,7 +423,7 @@ interface ISms {
* Returns the premium SMS send permission for the specified package.
* Requires system permission.
*/
- int getPremiumSmsPermissionForSubscriber(long subId, String packageName);
+ int getPremiumSmsPermissionForSubscriber(int subId, String packageName);
/**
* Set the SMS send permission for the specified package.
@@ -439,7 +439,7 @@ interface ISms {
* Set the SMS send permission for the specified package.
* Requires system permission.
*/
- void setPremiumSmsPermissionForSubscriber(long subId, String packageName, int permission);
+ void setPremiumSmsPermissionForSubscriber(int subId, String packageName, int permission);
/**
* SMS over IMS is supported if IMS is registered and SMS is supported
@@ -459,13 +459,13 @@ interface ISms {
*
* @see #getImsSmsFormat()
*/
- boolean isImsSmsSupportedForSubscriber(long subId);
+ boolean isImsSmsSupportedForSubscriber(int subId);
/*
* get user prefered SMS subId
* @return subId id
*/
- long getPreferredSmsSubscription();
+ int getPreferredSmsSubscription();
/**
* Gets SMS format supported on IMS. SMS over IMS format is
@@ -489,7 +489,7 @@ interface ISms {
*
* @see #isImsSmsSupported()
*/
- String getImsSmsFormatForSubscriber(long subId);
+ String getImsSmsFormatForSubscriber(int subId);
/*
* Get SMS prompt property, enabled or not
@@ -524,7 +524,7 @@ interface ISms {
* broadcast when the message is delivered to the recipient. The
* raw pdu of the status report is in the extended data ("pdu").
*/
- void sendStoredText(long subId, String callingPkg, in Uri messageUri, String scAddress,
+ void sendStoredText(int subId, String callingPkg, in Uri messageUri, String scAddress,
in PendingIntent sentIntent, in PendingIntent deliveryIntent);
/**
@@ -560,7 +560,7 @@ interface ISms {
* to the recipient. The raw pdu of the status report is in the
* extended data ("pdu").
*/
- void sendStoredMultipartText(long subId, String callingPkg, in Uri messageUri,
+ void sendStoredMultipartText(int subId, String callingPkg, in Uri messageUri,
String scAddress, in List<PendingIntent> sentIntents,
in List<PendingIntent> deliveryIntents);
}
diff --git a/telephony/java/com/android/internal/telephony/ISub.aidl b/telephony/java/com/android/internal/telephony/ISub.aidl
index b87365e..daf850e 100755
--- a/telephony/java/com/android/internal/telephony/ISub.aidl
+++ b/telephony/java/com/android/internal/telephony/ISub.aidl
@@ -25,7 +25,7 @@ interface ISub {
* @param subId The unique SubInfoRecord index in database
* @return SubInfoRecord, maybe null
*/
- SubInfoRecord getSubInfoForSubscriber(long subId);
+ SubInfoRecord getSubInfoForSubscriber(int subId);
/**
* Get the SubInfoRecord according to an IccId
@@ -79,7 +79,7 @@ interface ISub {
* @param subId the unique SubInfoRecord index in database
* @return the number of records updated
*/
- int setColor(int color, long subId);
+ int setColor(int color, int subId);
/**
* Set display name by simInfo index
@@ -87,7 +87,7 @@ interface ISub {
* @param subId the unique SubInfoRecord index in database
* @return the number of records updated
*/
- int setDisplayName(String displayName, long subId);
+ int setDisplayName(String displayName, int subId);
/**
* Set display name by simInfo index with name source
@@ -96,7 +96,7 @@ interface ISub {
* @param nameSource, 0: DEFAULT_SOURCE, 1: SIM_SOURCE, 2: USER_INPUT
* @return the number of records updated
*/
- int setDisplayNameUsingSrc(String displayName, long subId, long nameSource);
+ int setDisplayNameUsingSrc(String displayName, int subId, long nameSource);
/**
* Set phone number by subId
@@ -104,7 +104,7 @@ interface ISub {
* @param subId the unique SubInfoRecord index in database
* @return the number of records updated
*/
- int setDisplayNumber(String number, long subId);
+ int setDisplayNumber(String number, int subId);
/**
* Set number display format. 0: none, 1: the first four digits, 2: the last four digits
@@ -112,7 +112,7 @@ interface ISub {
* @param subId the unique SubInfoRecord index in database
* @return the number of records updated
*/
- int setDisplayNumberFormat(int format, long subId);
+ int setDisplayNumberFormat(int format, int subId);
/**
* Set data roaming by simInfo index
@@ -120,35 +120,35 @@ interface ISub {
* @param subId the unique SubInfoRecord index in database
* @return the number of records updated
*/
- int setDataRoaming(int roaming, long subId);
+ int setDataRoaming(int roaming, int subId);
- int getSlotId(long subId);
+ int getSlotId(int subId);
- long[] getSubId(int slotId);
+ int[] getSubId(int slotId);
- long getDefaultSubId();
+ int getDefaultSubId();
int clearSubInfo();
- int getPhoneId(long subId);
+ int getPhoneId(int subId);
/**
* Get the default data subscription
* @return Id of the data subscription
*/
- long getDefaultDataSubId();
+ int getDefaultDataSubId();
- void setDefaultDataSubId(long subId);
+ void setDefaultDataSubId(int subId);
- long getDefaultVoiceSubId();
+ int getDefaultVoiceSubId();
- void setDefaultVoiceSubId(long subId);
+ void setDefaultVoiceSubId(int subId);
- long getDefaultSmsSubId();
+ int getDefaultSmsSubId();
- void setDefaultSmsSubId(long subId);
+ void setDefaultSmsSubId(int subId);
void clearDefaultsForInactiveSubIds();
- long[] getActiveSubIdList();
+ int[] getActiveSubIdList();
}
diff --git a/telephony/java/com/android/internal/telephony/ITelephony.aidl b/telephony/java/com/android/internal/telephony/ITelephony.aidl
index b4d165c..13f0e3f 100644
--- a/telephony/java/com/android/internal/telephony/ITelephony.aidl
+++ b/telephony/java/com/android/internal/telephony/ITelephony.aidl
@@ -60,7 +60,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return whether it hung up
*/
- boolean endCallForSubscriber(long subId);
+ boolean endCallForSubscriber(int subId);
/**
* Answer the currently-ringing call.
@@ -94,7 +94,7 @@ interface ITelephony {
* TODO: this should be a oneway call (especially since it's called
* directly from the key queue thread).
*/
- void answerRingingCallForSubscriber(long subId);
+ void answerRingingCallForSubscriber(int subId);
/**
* Silence the ringer if an incoming call is currently ringing.
@@ -121,7 +121,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return true if the phone state is OFFHOOK.
*/
- boolean isOffhookForSubscriber(long subId);
+ boolean isOffhookForSubscriber(int subId);
/**
* Check if an incoming phone call is ringing or call waiting
@@ -130,7 +130,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return true if the phone state is RINGING.
*/
- boolean isRingingForSubscriber(long subId);
+ boolean isRingingForSubscriber(int subId);
/**
* Check if an incoming phone call is ringing or call waiting.
@@ -150,7 +150,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return true if the phone state is IDLE.
*/
- boolean isIdleForSubscriber(long subId);
+ boolean isIdleForSubscriber(int subId);
/**
* Check to see if the radio is on or not.
@@ -163,7 +163,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return returns true if the radio is on.
*/
- boolean isRadioOnForSubscriber(long subId);
+ boolean isRadioOnForSubscriber(int subId);
/**
* Check if the SIM pin lock is enabled.
@@ -185,7 +185,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return whether the operation was a success.
*/
- boolean supplyPinForSubscriber(long subId, String pin);
+ boolean supplyPinForSubscriber(int subId, String pin);
/**
* Supply puk to unlock the SIM and set SIM pin to new pin.
@@ -204,7 +204,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return whether the operation was a success.
*/
- boolean supplyPukForSubscriber(long subId, String puk, String pin);
+ boolean supplyPukForSubscriber(int subId, String puk, String pin);
/**
* Supply a pin to unlock the SIM. Blocks until a result is determined.
@@ -222,7 +222,7 @@ interface ITelephony {
* @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code
* retValue[1] = number of attempts remaining if known otherwise -1
*/
- int[] supplyPinReportResultForSubscriber(long subId, String pin);
+ int[] supplyPinReportResultForSubscriber(int subId, String pin);
/**
* Supply puk to unlock the SIM and set SIM pin to new pin.
@@ -244,7 +244,7 @@ interface ITelephony {
* @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code
* retValue[1] = number of attempts remaining if known otherwise -1
*/
- int[] supplyPukReportResultForSubscriber(long subId, String puk, String pin);
+ int[] supplyPukReportResultForSubscriber(int subId, String puk, String pin);
/**
* Handles PIN MMI commands (PIN/PIN2/PUK/PUK2), which are initiated
@@ -263,7 +263,7 @@ interface ITelephony {
* @param subId user preferred subId.
* @return true if MMI command is executed.
*/
- boolean handlePinMmiForSubscriber(long subId, String dialString);
+ boolean handlePinMmiForSubscriber(int subId, String dialString);
/**
* Toggles the radio on or off.
@@ -274,7 +274,7 @@ interface ITelephony {
* Toggles the radio on or off on particular subId.
* @param subId user preferred subId.
*/
- void toggleRadioOnOffForSubscriber(long subId);
+ void toggleRadioOnOffForSubscriber(int subId);
/**
* Set the radio to on or off
@@ -285,7 +285,7 @@ interface ITelephony {
* Set the radio to on or off on particular subId.
* @param subId user preferred subId.
*/
- boolean setRadioForSubscriber(long subId, boolean turnOn);
+ boolean setRadioForSubscriber(int subId, boolean turnOn);
/**
* Set the radio to on or off unconditionally
@@ -301,7 +301,7 @@ interface ITelephony {
* Request to update location information for a subscrition in service state
* @param subId user preferred subId.
*/
- void updateServiceLocationForSubscriber(long subId);
+ void updateServiceLocationForSubscriber(int subId);
/**
* Enable location update notifications.
@@ -312,7 +312,7 @@ interface ITelephony {
* Enable location update notifications.
* @param subId user preferred subId.
*/
- void enableLocationUpdatesForSubscriber(long subId);
+ void enableLocationUpdatesForSubscriber(int subId);
/**
* Disable location update notifications.
@@ -323,7 +323,7 @@ interface ITelephony {
* Disable location update notifications.
* @param subId user preferred subId.
*/
- void disableLocationUpdatesForSubscriber(long subId);
+ void disableLocationUpdatesForSubscriber(int subId);
/**
* Allow mobile data connections.
@@ -352,7 +352,7 @@ interface ITelephony {
/**
* Returns the call state for a subId.
*/
- int getCallStateForSubscriber(long subId);
+ int getCallStateForSubscriber(int subId);
int getDataActivity();
int getDataState();
@@ -370,7 +370,7 @@ interface ITelephony {
* and TelephonyManager.PHONE_TYPE_GSM if RILConstants.GSM_PHONE
* @param subId user preferred subId.
*/
- int getActivePhoneTypeForSubscriber(long subId);
+ int getActivePhoneTypeForSubscriber(int subId);
/**
* Returns the CDMA ERI icon index to display
@@ -381,7 +381,7 @@ interface ITelephony {
* Returns the CDMA ERI icon index to display on particular subId.
* @param subId user preferred subId.
*/
- int getCdmaEriIconIndexForSubscriber(long subId);
+ int getCdmaEriIconIndexForSubscriber(int subId);
/**
* Returns the CDMA ERI icon mode,
@@ -396,7 +396,7 @@ interface ITelephony {
* 1 - FLASHING
* @param subId user preferred subId.
*/
- int getCdmaEriIconModeForSubscriber(long subId);
+ int getCdmaEriIconModeForSubscriber(int subId);
/**
* Returns the CDMA ERI text,
@@ -407,7 +407,7 @@ interface ITelephony {
* Returns the CDMA ERI text for particular subId,
* @param subId user preferred subId.
*/
- String getCdmaEriTextForSubscriber(long subId);
+ String getCdmaEriTextForSubscriber(int subId);
/**
* Returns true if OTA service provisioning needs to run.
@@ -426,7 +426,7 @@ interface ITelephony {
* @param subId user preferred subId.
* Returns the unread count of voicemails
*/
- int getVoiceMessageCountForSubscriber(long subId);
+ int getVoiceMessageCountForSubscriber(int subId);
/**
* Returns the network type for data transmission
@@ -438,7 +438,7 @@ interface ITelephony {
* @param subId user preferred subId.
* Returns the network type
*/
- int getNetworkTypeForSubscriber(long subId);
+ int getNetworkTypeForSubscriber(int subId);
/**
* Returns the network type for data transmission
@@ -450,7 +450,7 @@ interface ITelephony {
* @param subId user preferred subId.
* Returns the network type
*/
- int getDataNetworkTypeForSubscriber(long subId);
+ int getDataNetworkTypeForSubscriber(int subId);
/**
* Returns the network type for voice
@@ -462,7 +462,7 @@ interface ITelephony {
* @param subId user preferred subId.
* Returns the network type
*/
- int getVoiceNetworkTypeForSubscriber(long subId);
+ int getVoiceNetworkTypeForSubscriber(int subId);
/**
* Return true if an ICC card is present
@@ -474,7 +474,7 @@ interface ITelephony {
* @param slotId user preferred slotId.
* Return true if an ICC card is present
*/
- boolean hasIccCardUsingSlotId(long slotId);
+ boolean hasIccCardUsingSlotId(int slotId);
/**
* Return if the current radio is LTE on CDMA. This
@@ -494,7 +494,7 @@ interface ITelephony {
* @return {@link Phone#LTE_ON_CDMA_UNKNOWN}, {@link Phone#LTE_ON_CDMA_FALSE}
* or {@link PHone#LTE_ON_CDMA_TRUE}
*/
- int getLteOnCdmaModeForSubscriber(long subId);
+ int getLteOnCdmaModeForSubscriber(int subId);
/**
* Returns the all observed cell information of the device.
@@ -689,13 +689,13 @@ interface ITelephony {
* Return MDN string for CDMA phone.
* @param subId user preferred subId.
*/
- String getCdmaMdn(long subId);
+ String getCdmaMdn(int subId);
/**
* Return MIN string for CDMA phone.
* @param subId user preferred subId.
*/
- String getCdmaMin(long subId);
+ String getCdmaMin(int subId);
/**
* Has the calling application been granted special privileges by the carrier.
@@ -733,7 +733,7 @@ interface ITelephony {
* @param subId for which the simplified UI should be enabled or disabled.
* @param enable true means enabling the simplified UI.
*/
- void enableSimplifiedNetworkSettingsForSubscriber(long subId, boolean enable);
+ void enableSimplifiedNetworkSettingsForSubscriber(int subId, boolean enable);
/**
* Get whether a simplified Mobile Network Settings UI is enabled for the
@@ -742,7 +742,7 @@ interface ITelephony {
* @param subId for which the simplified UI should be enabled or disabled.
* @return true if the simplified UI is enabled.
*/
- boolean getSimplifiedNetworkSettingsEnabledForSubscriber(long subId);
+ boolean getSimplifiedNetworkSettingsEnabledForSubscriber(int subId);
/**
* Set the line 1 phone number string and its alphatag for the current ICCID
@@ -754,7 +754,7 @@ interface ITelephony {
* @param alphaTag alpha-tagging of the dailing nubmer
* @param number The dialing number
*/
- void setLine1NumberForDisplayForSubscriber(long subId, String alphaTag, String number);
+ void setLine1NumberForDisplayForSubscriber(int subId, String alphaTag, String number);
/**
* Returns the displayed dialing number string if it was set previously via
@@ -763,7 +763,7 @@ interface ITelephony {
* @param subId whose dialing number for line 1 is returned.
* @return the displayed dialing number if set, or null if not set.
*/
- String getLine1NumberForDisplay(long subId);
+ String getLine1NumberForDisplay(int subId);
/**
* Returns the displayed alphatag of the dialing number if it was set
@@ -773,7 +773,7 @@ interface ITelephony {
* @return the displayed alphatag of the dialing number if set, or null if
* not set.
*/
- String getLine1AlphaTagForDisplay(long subId);
+ String getLine1AlphaTagForDisplay(int subId);
/**
* Override the operator branding for the current ICCID.
diff --git a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
index 39defcf..ee3f8b0 100644
--- a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
+++ b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
@@ -30,28 +30,28 @@ import com.android.internal.telephony.IPhoneStateListener;
interface ITelephonyRegistry {
void listen(String pkg, IPhoneStateListener callback, int events, boolean notifyNow);
- void listenForSubscriber(in long subId, String pkg, IPhoneStateListener callback, int events,
+ void listenForSubscriber(in int subId, String pkg, IPhoneStateListener callback, int events,
boolean notifyNow);
void notifyCallState(int state, String incomingNumber);
- void notifyCallStateForSubscriber(in long subId, int state, String incomingNumber);
- void notifyServiceStateForPhoneId(in int phoneId, in long subId, in ServiceState state);
+ void notifyCallStateForSubscriber(in int subId, int state, String incomingNumber);
+ void notifyServiceStateForPhoneId(in int phoneId, in int subId, in ServiceState state);
void notifySignalStrength(in SignalStrength signalStrength);
- void notifySignalStrengthForSubscriber(in long subId, in SignalStrength signalStrength);
- void notifyMessageWaitingChangedForPhoneId(in int phoneId, in long subId, in boolean mwi);
+ void notifySignalStrengthForSubscriber(in int subId, in SignalStrength signalStrength);
+ void notifyMessageWaitingChangedForPhoneId(in int phoneId, in int subId, in boolean mwi);
void notifyCallForwardingChanged(boolean cfi);
- void notifyCallForwardingChangedForSubscriber(in long subId, boolean cfi);
+ void notifyCallForwardingChangedForSubscriber(in int subId, boolean cfi);
void notifyDataActivity(int state);
- void notifyDataActivityForSubscriber(in long subId, int state);
+ void notifyDataActivityForSubscriber(in int subId, int state);
void notifyDataConnection(int state, boolean isDataConnectivityPossible,
String reason, String apn, String apnType, in LinkProperties linkProperties,
in NetworkCapabilities networkCapabilities, int networkType, boolean roaming);
- void notifyDataConnectionForSubscriber(long subId, int state, boolean isDataConnectivityPossible,
+ void notifyDataConnectionForSubscriber(int subId, int state, boolean isDataConnectivityPossible,
String reason, String apn, String apnType, in LinkProperties linkProperties,
in NetworkCapabilities networkCapabilities, int networkType, boolean roaming);
void notifyDataConnectionFailed(String reason, String apnType);
- void notifyDataConnectionFailedForSubscriber(long subId, String reason, String apnType);
+ void notifyDataConnectionFailedForSubscriber(int subId, String reason, String apnType);
void notifyCellLocation(in Bundle cellLocation);
- void notifyCellLocationForSubscriber(in long subId, in Bundle cellLocation);
+ void notifyCellLocationForSubscriber(in int subId, in Bundle cellLocation);
void notifyOtaspChanged(in int otaspMode);
void notifyCellInfo(in List<CellInfo> cellInfo);
void notifyPreciseCallState(int ringingCallState, int foregroundCallState,
@@ -59,8 +59,8 @@ interface ITelephonyRegistry {
void notifyDisconnectCause(int disconnectCause, int preciseDisconnectCause);
void notifyPreciseDataConnectionFailed(String reason, String apnType, String apn,
String failCause);
- void notifyCellInfoForSubscriber(in long subId, in List<CellInfo> cellInfo);
+ void notifyCellInfoForSubscriber(in int subId, in List<CellInfo> cellInfo);
void notifyDataConnectionRealTimeInfo(in DataConnectionRealTimeInfo dcRtInfo);
void notifyVoLteServiceStateChanged(in VoLteServiceState lteState);
- void notifyOemHookRawEventForSubscriber(in long subId, in byte[] rawData);
+ void notifyOemHookRawEventForSubscriber(in int subId, in byte[] rawData);
}