summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChen Xu <fionaxu@google.com>2018-10-19 11:13:04 -0700
committerandroid-build-merger <android-build-merger@google.com>2018-10-19 11:13:04 -0700
commitbb0689b6d5a0382fcd04a659c3827d56c581aada (patch)
tree6c69924b72fdac9aa6a12c0f9f88f95220f90b19
parent76439a1665d45ea177eb9f2a33bc8553b24998bc (diff)
parentf2e0f579761aba0b24187df1fc5dc6a73fff6945 (diff)
downloadbase-pie-temp.tar.gz
Merge "expose some Telephony.Carriers cols system APIs"pie-temp
am: f2e0f57976 Change-Id: Ifbceb368352aa1f57912b6690f61fe8412e2dc41
-rw-r--r--api/system-current.txt17
-rw-r--r--telephony/java/android/provider/Telephony.java84
2 files changed, 77 insertions, 24 deletions
diff --git a/api/system-current.txt b/api/system-current.txt
index f6d1fe2cf498..acda35685528 100644
--- a/api/system-current.txt
+++ b/api/system-current.txt
@@ -4283,6 +4283,23 @@ package android.provider {
field public static final java.lang.String INSTANT_APPS_ENABLED = "instant_apps_enabled";
}
+ public static final class Telephony.Carriers implements android.provider.BaseColumns {
+ field public static final java.lang.String APN_SET_ID = "apn_set_id";
+ field public static final int CARRIER_EDITED = 4; // 0x4
+ field public static final java.lang.String EDITED = "edited";
+ field public static final java.lang.String MAX_CONNS = "max_conns";
+ field public static final java.lang.String MAX_CONNS_TIME = "max_conns_time";
+ field public static final java.lang.String MODEM_COGNITIVE = "modem_cognitive";
+ field public static final java.lang.String MTU = "mtu";
+ field public static final int NO_SET_SET = 0; // 0x0
+ field public static final int UNEDITED = 0; // 0x0
+ field public static final int USER_DELETED = 2; // 0x2
+ field public static final java.lang.String USER_EDITABLE = "user_editable";
+ field public static final int USER_EDITED = 1; // 0x1
+ field public static final java.lang.String USER_VISIBLE = "user_visible";
+ field public static final java.lang.String WAIT_TIME = "wait_time";
+ }
+
public final class TimeZoneRulesDataContract {
field public static final java.lang.String AUTHORITY = "com.android.timezone";
}
diff --git a/telephony/java/android/provider/Telephony.java b/telephony/java/android/provider/Telephony.java
index d48f21b6dfcd..954bb44e8532 100644
--- a/telephony/java/android/provider/Telephony.java
+++ b/telephony/java/android/provider/Telephony.java
@@ -18,6 +18,7 @@ package android.provider;
import android.annotation.SdkConstant;
import android.annotation.SdkConstant.SdkConstantType;
+import android.annotation.SystemApi;
import android.annotation.TestApi;
import android.annotation.UnsupportedAppUsage;
import android.app.job.JobService;
@@ -2813,100 +2814,131 @@ public final class Telephony {
public static final String SUBSCRIPTION_ID = "sub_id";
/**
- * The profile_id to which the APN saved in modem
+ * The profile_id to which the APN saved in modem.
* <p>Type: INTEGER</p>
*@hide
*/
public static final String PROFILE_ID = "profile_id";
/**
- * Is the apn setting to be set in modem
- * <P>Type: INTEGER (boolean)</P>
+ * If set to {@code true}, then the APN setting will persist to the modem.
+ * <p>Type: INTEGER (boolean)</p>
*@hide
*/
+ @SystemApi
public static final String MODEM_COGNITIVE = "modem_cognitive";
/**
- * The max connections of this apn
+ * The max connections of this APN.
* <p>Type: INTEGER</p>
*@hide
*/
+ @SystemApi
public static final String MAX_CONNS = "max_conns";
/**
- * The wait time for retry of the apn
+ * The wait time for retry of the APN.
* <p>Type: INTEGER</p>
*@hide
*/
+ @SystemApi
public static final String WAIT_TIME = "wait_time";
/**
- * The time to limit max connection for the apn
+ * The time to limit max connection for the APN.
* <p>Type: INTEGER</p>
*@hide
*/
+ @SystemApi
public static final String MAX_CONNS_TIME = "max_conns_time";
/**
- * The MTU size of the mobile interface to which the APN connected
+ * The MTU(Maxinum transmit unit) size of the mobile interface to which the APN connected.
* <p>Type: INTEGER </p>
* @hide
*/
+ @SystemApi
public static final String MTU = "mtu";
/**
- * Is this APN added/edited/deleted by a user or carrier?
+ * APN edit status. APN could be added/edited/deleted by a user or carrier.
* <p>Type: INTEGER </p>
* @hide
*/
+ @SystemApi
public static final String EDITED = "edited";
/**
- * Is this APN visible to the user?
- * <p>Type: INTEGER (boolean) </p>
+ * {@code true} if this APN visible to the user, {@code false} otherwise.
+ * <p>Type: INTEGER (boolean)</p>
* @hide
*/
+ @SystemApi
public static final String USER_VISIBLE = "user_visible";
/**
- * Is the user allowed to edit this APN?
- * <p>Type: INTEGER (boolean) </p>
+ * {@code true} if the user allowed to edit this APN, {@code false} otherwise.
+ * <p>Type: INTEGER (boolean)</p>
* @hide
*/
+ @SystemApi
public static final String USER_EDITABLE = "user_editable";
/**
- * Following are possible values for the EDITED field
+ * {@link #EDITED APN edit status} indicates that this APN has not been edited or fails to
+ * edit.
+ * <p>Type: INTEGER </p>
* @hide
*/
+ @SystemApi
public static final int UNEDITED = 0;
+
/**
- * @hide
+ * {@link #EDITED APN edit status} indicates that this APN has been edited by users.
+ * <p>Type: INTEGER </p>
+ * @hide
*/
+ @SystemApi
public static final int USER_EDITED = 1;
+
/**
- * @hide
+ * {@link #EDITED APN edit status} indicates that this APN has been deleted by users.
+ * <p>Type: INTEGER </p>
+ * @hide
*/
+ @SystemApi
public static final int USER_DELETED = 2;
+
/**
- * DELETED_BUT_PRESENT is an intermediate value used to indicate that an entry deleted
- * by the user is still present in the new APN database and therefore must remain tagged
- * as user deleted rather than completely removed from the database
+ * {@link #EDITED APN edit status} is an intermediate value used to indicate that an entry
+ * deleted by the user is still present in the new APN database and therefore must remain
+ * tagged as user deleted rather than completely removed from the database.
* @hide
*/
public static final int USER_DELETED_BUT_PRESENT_IN_XML = 3;
+
/**
- * @hide
+ * {@link #EDITED APN edit status} indicates that this APN has been edited by carriers.
+ * <p>Type: INTEGER </p>
+ * @hide
*/
+ @SystemApi
public static final int CARRIER_EDITED = 4;
+
/**
- * CARRIER_DELETED values are currently not used as there is no usecase. If they are used,
+ * {@link #EDITED APN edit status} indicates that this APN has been deleted by carriers.
+ * CARRIER_DELETED values are currently not used as there is no use case. If they are used,
* delete() will have to change accordingly. Currently it is hardcoded to USER_DELETED.
+ * <p>Type: INTEGER </p>
* @hide
*/
public static final int CARRIER_DELETED = 5;
+
/**
- * @hide
+ * {@link #EDITED APN edit status} is an intermediate value used to indicate that an entry
+ * deleted by the carrier is still present in the new APN database and therefore must remain
+ * tagged as user deleted rather than completely removed from the database.
+ * @hide
*/
public static final int CARRIER_DELETED_BUT_PRESENT_IN_XML = 6;
@@ -2935,16 +2967,20 @@ public final class Telephony {
* The APN set id. When the user manually selects an APN or the framework sets an APN as
* preferred, all APNs with the same set id as the selected APN should be prioritized over
* APNs in other sets.
+ * <p>Type: INTEGER</p>
* @hide
*/
+ @SystemApi
public static final String APN_SET_ID = "apn_set_id";
/**
- * Possible value for the APN_SET_ID field. By default APNs will not belong to a set. If the
- * user manually selects an APN with no set set, there is no need to prioritize any specific
- * APN set ids.
+ * Possible value for the{@link #APN_SET_ID} field. By default APNs will not belong to a
+ * set. If the user manually selects an APN with no set set, there is no need to prioritize
+ * any specific APN set ids.
+ * <p>Type: INTEGER</p>
* @hide
*/
+ @SystemApi
public static final int NO_SET_SET = 0;
}