Loading telephony/java/android/telephony/SubscriptionInfo.java +3 −3 Original line number Diff line number Diff line Loading @@ -89,8 +89,8 @@ public class SubscriptionInfo implements Parcelable { private int mCarrierId; /** * The source of the name, NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SOURCE or * NAME_SOURCE_USER_INPUT. * The source of the name, NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SPN, * NAME_SOURCE_SIM_PNN, or NAME_SOURCE_USER_INPUT. */ private int mNameSource; Loading Loading @@ -334,7 +334,7 @@ public class SubscriptionInfo implements Parcelable { } /** * @return the source of the name, eg NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SOURCE or * @return the source of the name, eg NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SPN or * NAME_SOURCE_USER_INPUT. * @hide */ Loading telephony/java/android/telephony/SubscriptionManager.java +24 −7 Original line number Diff line number Diff line Loading @@ -400,19 +400,19 @@ public class SubscriptionManager { public static final String NAME_SOURCE = "name_source"; /** * The name_source is the default * The name_source is the default, which is from the carrier id. * @hide */ public static final int NAME_SOURCE_DEFAULT_SOURCE = 0; /** * The name_source is from the SIM * The name_source is from SIM EF_SPN. * @hide */ public static final int NAME_SOURCE_SIM_SOURCE = 1; public static final int NAME_SOURCE_SIM_SPN = 1; /** * The name_source is from the user * The name_source is from user input * @hide */ @UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.P, trackingBug = 115609023) Loading @@ -424,6 +424,24 @@ public class SubscriptionManager { */ public static final int NAME_SOURCE_CARRIER = 3; /** * The name_source is from SIM EF_PNN. * @hide */ public static final int NAME_SOURCE_SIM_PNN = 4; /** @hide */ @Retention(RetentionPolicy.SOURCE) @IntDef(prefix = {"NAME_SOURCE_"}, value = { NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SPN, NAME_SOURCE_USER_INPUT, NAME_SOURCE_CARRIER, NAME_SOURCE_SIM_PNN }) public @interface SimDisplayNameSource {} /** * TelephonyProvider column name for the color of a SIM. * <P>Type: INTEGER (int)</P> Loading Loading @@ -1660,13 +1678,12 @@ public class SubscriptionManager { * Set display name by simInfo index with name source * @param displayName the display name of SIM card * @param subId the unique SubscriptionInfo index in database * @param nameSource 0: NAME_SOURCE_DEFAULT_SOURCE, 1: NAME_SOURCE_SIM_SOURCE, * 2: NAME_SOURCE_USER_INPUT * @param nameSource SIM display name source * @return the number of records updated or < 0 if invalid subId * @hide */ @UnsupportedAppUsage public int setDisplayName(String displayName, int subId, int nameSource) { public int setDisplayName(String displayName, int subId, @SimDisplayNameSource int nameSource) { if (VDBG) { logd("[setDisplayName]+ displayName:" + displayName + " subId:" + subId + " nameSource:" + nameSource); Loading Loading
telephony/java/android/telephony/SubscriptionInfo.java +3 −3 Original line number Diff line number Diff line Loading @@ -89,8 +89,8 @@ public class SubscriptionInfo implements Parcelable { private int mCarrierId; /** * The source of the name, NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SOURCE or * NAME_SOURCE_USER_INPUT. * The source of the name, NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SPN, * NAME_SOURCE_SIM_PNN, or NAME_SOURCE_USER_INPUT. */ private int mNameSource; Loading Loading @@ -334,7 +334,7 @@ public class SubscriptionInfo implements Parcelable { } /** * @return the source of the name, eg NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SOURCE or * @return the source of the name, eg NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SPN or * NAME_SOURCE_USER_INPUT. * @hide */ Loading
telephony/java/android/telephony/SubscriptionManager.java +24 −7 Original line number Diff line number Diff line Loading @@ -400,19 +400,19 @@ public class SubscriptionManager { public static final String NAME_SOURCE = "name_source"; /** * The name_source is the default * The name_source is the default, which is from the carrier id. * @hide */ public static final int NAME_SOURCE_DEFAULT_SOURCE = 0; /** * The name_source is from the SIM * The name_source is from SIM EF_SPN. * @hide */ public static final int NAME_SOURCE_SIM_SOURCE = 1; public static final int NAME_SOURCE_SIM_SPN = 1; /** * The name_source is from the user * The name_source is from user input * @hide */ @UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.P, trackingBug = 115609023) Loading @@ -424,6 +424,24 @@ public class SubscriptionManager { */ public static final int NAME_SOURCE_CARRIER = 3; /** * The name_source is from SIM EF_PNN. * @hide */ public static final int NAME_SOURCE_SIM_PNN = 4; /** @hide */ @Retention(RetentionPolicy.SOURCE) @IntDef(prefix = {"NAME_SOURCE_"}, value = { NAME_SOURCE_DEFAULT_SOURCE, NAME_SOURCE_SIM_SPN, NAME_SOURCE_USER_INPUT, NAME_SOURCE_CARRIER, NAME_SOURCE_SIM_PNN }) public @interface SimDisplayNameSource {} /** * TelephonyProvider column name for the color of a SIM. * <P>Type: INTEGER (int)</P> Loading Loading @@ -1660,13 +1678,12 @@ public class SubscriptionManager { * Set display name by simInfo index with name source * @param displayName the display name of SIM card * @param subId the unique SubscriptionInfo index in database * @param nameSource 0: NAME_SOURCE_DEFAULT_SOURCE, 1: NAME_SOURCE_SIM_SOURCE, * 2: NAME_SOURCE_USER_INPUT * @param nameSource SIM display name source * @return the number of records updated or < 0 if invalid subId * @hide */ @UnsupportedAppUsage public int setDisplayName(String displayName, int subId, int nameSource) { public int setDisplayName(String displayName, int subId, @SimDisplayNameSource int nameSource) { if (VDBG) { logd("[setDisplayName]+ displayName:" + displayName + " subId:" + subId + " nameSource:" + nameSource); Loading