Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e03edaba authored by Shuo Qian's avatar Shuo Qian Committed by Gerrit Code Review
Browse files

Merge "API Council Feedbacks"

parents 3a290c6b 9ae1afee
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -5983,13 +5983,15 @@ package android.os {
    field public static final String ACTION_UPDATE_CARRIER_PROVISIONING_URLS = "android.intent.action.UPDATE_CARRIER_PROVISIONING_URLS";
    field public static final String ACTION_UPDATE_CONVERSATION_ACTIONS = "android.intent.action.UPDATE_CONVERSATION_ACTIONS";
    field public static final String ACTION_UPDATE_CT_LOGS = "android.intent.action.UPDATE_CT_LOGS";
    field public static final String ACTION_UPDATE_EMERGENCY_NUMBER_DB = "android.os.action.UPDATE_EMERGENCY_NUMBER_DB";
    field @RequiresPermission("android.permission.UPDATE_CONFIG") public static final String ACTION_UPDATE_EMERGENCY_NUMBER_DB = "android.os.action.UPDATE_EMERGENCY_NUMBER_DB";
    field public static final String ACTION_UPDATE_INTENT_FIREWALL = "android.intent.action.UPDATE_INTENT_FIREWALL";
    field public static final String ACTION_UPDATE_LANG_ID = "android.intent.action.UPDATE_LANG_ID";
    field public static final String ACTION_UPDATE_NETWORK_WATCHLIST = "android.intent.action.UPDATE_NETWORK_WATCHLIST";
    field public static final String ACTION_UPDATE_PINS = "android.intent.action.UPDATE_PINS";
    field public static final String ACTION_UPDATE_SMART_SELECTION = "android.intent.action.UPDATE_SMART_SELECTION";
    field public static final String ACTION_UPDATE_SMS_SHORT_CODES = "android.intent.action.UPDATE_SMS_SHORT_CODES";
    field public static final String EXTRA_REQUIRED_HASH = "android.os.extra.REQUIRED_HASH";
    field public static final String EXTRA_VERSION = "android.os.extra.VERSION";
  }
  public class Environment {
@@ -9362,7 +9364,7 @@ package android.telephony {
    method @NonNull public java.util.List<android.telephony.data.ApnSetting> getDevicePolicyOverrideApns(@NonNull android.content.Context);
    method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getDeviceSoftwareVersion(int);
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean getEmergencyCallbackMode();
    method public int getEmergencyNumberDbVersion();
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getEmergencyNumberDbVersion();
    method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getIsimDomain();
    method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String[] getIsimImpu();
    method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getIsimIst();
@@ -9392,7 +9394,7 @@ package android.telephony {
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isApplicationOnUicc(int);
    method public boolean isCurrentSimOperator(@NonNull String, int, @Nullable String);
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isDataAllowedInVoiceCall();
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isDataConnectionEnabled();
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isDataConnectionAllowed();
    method public boolean isDataConnectivityPossible();
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isDataEnabledForApn(int);
    method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isEmergencyAssistanceEnabled();
+1 −1
Original line number Diff line number Diff line
@@ -3244,7 +3244,7 @@ package android.telephony {
    method public java.util.List<java.lang.String> getCarrierPackageNamesForIntent(android.content.Intent);
    method @Nullable public static android.content.ComponentName getDefaultRespondViaMessageApplication(@NonNull android.content.Context, boolean);
    method @NonNull public java.util.List<android.telephony.data.ApnSetting> getDevicePolicyOverrideApns(@NonNull android.content.Context);
    method public int getEmergencyNumberDbVersion();
    method @RequiresPermission("android.permission.READ_PRIVILEGED_PHONE_STATE") public int getEmergencyNumberDbVersion();
    method @RequiresPermission(android.Manifest.permission.READ_PHONE_STATE) public String getLine1AlphaTag();
    method @NonNull @RequiresPermission("android.permission.READ_PRIVILEGED_PHONE_STATE") public String getNetworkCountryIso(int);
    method public android.util.Pair<java.lang.Integer,java.lang.Integer> getRadioHalVersion();
+24 −7
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@

package android.os;

import android.annotation.RequiresPermission;
import android.annotation.SystemApi;

/**
@@ -114,20 +115,36 @@ public final class ConfigUpdate {
            = "android.os.action.UPDATE_CARRIER_ID_DB";

    /**
    * Broadcast intent action indicating that the updated emergency number database is available.
    * <p>Extra: "VERSION" the numeric version of the new data. Devices should only install if the
    * update version is newer than the current one.
    * <p>Extra: "REQUIRED_HASH" the hash of the current update data.
    * <p>Input: {@link android.content.Intent#getData} is URI of downloaded emergency number file.
    * Devices should pick up the downloaded file and persist to the database
    * {@code com.android.internal.telephony.emergency.EmergencyNumberTracker}.
    * Update the emergency number database into the devices.
    * <p>Extra: {@link #EXTRA_VERSION} the numeric version of the database.
    * <p>Extra: {@link #EXTRA_REQUIRED_HASH} the hash of the database.
    * <p>Input: {@link android.content.Intent#getData} the URI to download emergency number
    * database.
    *
    * @hide
    */
    @SystemApi
    @RequiresPermission(android.Manifest.permission.UPDATE_CONFIG)
    public static final String ACTION_UPDATE_EMERGENCY_NUMBER_DB =
            "android.os.action.UPDATE_EMERGENCY_NUMBER_DB";

    /**
     * An integer to indicate the numeric version of the new data. Devices should only install
     * if the update version is newer than the current one.
     *
     * @hide
     */
    @SystemApi
    public static final String EXTRA_VERSION = "android.os.extra.VERSION";

    /**
     * A string to indicate the hash of the data.
     *
     * @hide
     */
    @SystemApi
    public static final String EXTRA_REQUIRED_HASH = "android.os.extra.REQUIRED_HASH";

    private ConfigUpdate() {
    }
}
+1 −1
Original line number Diff line number Diff line
@@ -577,7 +577,7 @@ public class MobileSignalController extends SignalController<
    }

    boolean isDataDisabled() {
        return !mPhone.isDataConnectionEnabled();
        return !mPhone.isDataConnectionAllowed();
    }

    @VisibleForTesting
+1 −1
Original line number Diff line number Diff line
@@ -176,7 +176,7 @@ public class NetworkControllerBaseTest extends SysuiTestCase {
    protected void setupNetworkController() {
        // For now just pretend to be the data sim, so we can test that too.
        mSubId = SubscriptionManager.DEFAULT_SUBSCRIPTION_ID;
        when(mMockTm.isDataConnectionEnabled()).thenReturn(true);
        when(mMockTm.isDataConnectionAllowed()).thenReturn(true);
        setDefaultSubId(mSubId);
        setSubscriptions(mSubId);
        mMobileSignalController = mNetworkController.mMobileSignalControllers.get(mSubId);
Loading