Merge "Multi-SIM - Fixing inconsistent naming in CarrierConfigManager." into nyc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
70d5c8d246
@@ -36510,9 +36510,11 @@ package android.telecom {
|
|||||||
package android.telephony {
|
package android.telephony {
|
||||||
|
|
||||||
public class CarrierConfigManager {
|
public class CarrierConfigManager {
|
||||||
|
method public android.os.PersistableBundle getConfig(int);
|
||||||
method public android.os.PersistableBundle getConfig();
|
method public android.os.PersistableBundle getConfig();
|
||||||
method public android.os.PersistableBundle getConfigForSubId(int);
|
method public deprecated android.os.PersistableBundle getConfigForSubId(int);
|
||||||
method public void notifyConfigChangedForSubId(int);
|
method public void notifyConfigChanged(int);
|
||||||
|
method public deprecated void notifyConfigChangedForSubId(int);
|
||||||
field public static final java.lang.String ACTION_CARRIER_CONFIG_CHANGED = "android.telephony.action.CARRIER_CONFIG_CHANGED";
|
field public static final java.lang.String ACTION_CARRIER_CONFIG_CHANGED = "android.telephony.action.CARRIER_CONFIG_CHANGED";
|
||||||
field public static final java.lang.String BOOL_ALLOW_EMERGENCY_VIDEO_CALLS = "bool_allow_emergency_video_calls";
|
field public static final java.lang.String BOOL_ALLOW_EMERGENCY_VIDEO_CALLS = "bool_allow_emergency_video_calls";
|
||||||
field public static final java.lang.String BOOL_ALLOW_VIDEO_PAUSE = "bool_allow_video_pause";
|
field public static final java.lang.String BOOL_ALLOW_VIDEO_PAUSE = "bool_allow_video_pause";
|
||||||
|
|||||||
@@ -39225,10 +39225,12 @@ package android.telecom {
|
|||||||
package android.telephony {
|
package android.telephony {
|
||||||
|
|
||||||
public class CarrierConfigManager {
|
public class CarrierConfigManager {
|
||||||
|
method public android.os.PersistableBundle getConfig(int);
|
||||||
method public android.os.PersistableBundle getConfig();
|
method public android.os.PersistableBundle getConfig();
|
||||||
method public android.os.PersistableBundle getConfigForSubId(int);
|
method public deprecated android.os.PersistableBundle getConfigForSubId(int);
|
||||||
method public static android.os.PersistableBundle getDefaultConfig();
|
method public static android.os.PersistableBundle getDefaultConfig();
|
||||||
method public void notifyConfigChangedForSubId(int);
|
method public void notifyConfigChanged(int);
|
||||||
|
method public deprecated void notifyConfigChangedForSubId(int);
|
||||||
method public void updateConfigForPhoneId(int, java.lang.String);
|
method public void updateConfigForPhoneId(int, java.lang.String);
|
||||||
field public static final java.lang.String ACTION_CARRIER_CONFIG_CHANGED = "android.telephony.action.CARRIER_CONFIG_CHANGED";
|
field public static final java.lang.String ACTION_CARRIER_CONFIG_CHANGED = "android.telephony.action.CARRIER_CONFIG_CHANGED";
|
||||||
field public static final java.lang.String BOOL_ALLOW_EMERGENCY_VIDEO_CALLS = "bool_allow_emergency_video_calls";
|
field public static final java.lang.String BOOL_ALLOW_EMERGENCY_VIDEO_CALLS = "bool_allow_emergency_video_calls";
|
||||||
|
|||||||
@@ -36525,9 +36525,11 @@ package android.telecom {
|
|||||||
package android.telephony {
|
package android.telephony {
|
||||||
|
|
||||||
public class CarrierConfigManager {
|
public class CarrierConfigManager {
|
||||||
|
method public android.os.PersistableBundle getConfig(int);
|
||||||
method public android.os.PersistableBundle getConfig();
|
method public android.os.PersistableBundle getConfig();
|
||||||
method public android.os.PersistableBundle getConfigForSubId(int);
|
method public deprecated android.os.PersistableBundle getConfigForSubId(int);
|
||||||
method public void notifyConfigChangedForSubId(int);
|
method public void notifyConfigChanged(int);
|
||||||
|
method public deprecated void notifyConfigChangedForSubId(int);
|
||||||
field public static final java.lang.String ACTION_CARRIER_CONFIG_CHANGED = "android.telephony.action.CARRIER_CONFIG_CHANGED";
|
field public static final java.lang.String ACTION_CARRIER_CONFIG_CHANGED = "android.telephony.action.CARRIER_CONFIG_CHANGED";
|
||||||
field public static final java.lang.String BOOL_ALLOW_EMERGENCY_VIDEO_CALLS = "bool_allow_emergency_video_calls";
|
field public static final java.lang.String BOOL_ALLOW_EMERGENCY_VIDEO_CALLS = "bool_allow_emergency_video_calls";
|
||||||
field public static final java.lang.String BOOL_ALLOW_VIDEO_PAUSE = "bool_allow_video_pause";
|
field public static final java.lang.String BOOL_ALLOW_VIDEO_PAUSE = "bool_allow_video_pause";
|
||||||
|
|||||||
@@ -733,9 +733,28 @@ public class CarrierConfigManager {
|
|||||||
* @param subId the subscription ID, normally obtained from {@link SubscriptionManager}.
|
* @param subId the subscription ID, normally obtained from {@link SubscriptionManager}.
|
||||||
* @return A {@link PersistableBundle} containing the config for the given subId, or default
|
* @return A {@link PersistableBundle} containing the config for the given subId, or default
|
||||||
* values for an invalid subId.
|
* values for an invalid subId.
|
||||||
|
*
|
||||||
|
* @deprecated use getConfig.
|
||||||
*/
|
*/
|
||||||
@Nullable
|
@Nullable
|
||||||
public PersistableBundle getConfigForSubId(int subId) {
|
public PersistableBundle getConfigForSubId(int subId) {
|
||||||
|
return getConfig(subId);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets the configuration values for a particular subscription, which is associated with a
|
||||||
|
* specific SIM card. If an invalid subId is used, the returned config will contain default
|
||||||
|
* values.
|
||||||
|
*
|
||||||
|
* <p>Requires Permission:
|
||||||
|
* {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
|
||||||
|
*
|
||||||
|
* @param subId the subscription ID, normally obtained from {@link SubscriptionManager}.
|
||||||
|
* @return A {@link PersistableBundle} containing the config for the given subId, or default
|
||||||
|
* values for an invalid subId.
|
||||||
|
*/
|
||||||
|
@Nullable
|
||||||
|
public PersistableBundle getConfig(int subId) {
|
||||||
try {
|
try {
|
||||||
ICarrierConfigLoader loader = getICarrierConfigLoader();
|
ICarrierConfigLoader loader = getICarrierConfigLoader();
|
||||||
if (loader == null) {
|
if (loader == null) {
|
||||||
@@ -757,11 +776,32 @@ public class CarrierConfigManager {
|
|||||||
* <p>Requires Permission:
|
* <p>Requires Permission:
|
||||||
* {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
|
* {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
|
||||||
*
|
*
|
||||||
* @see #getConfigForSubId
|
* @return A {@link PersistableBundle} containing the config for the default subscription.
|
||||||
*/
|
*/
|
||||||
@Nullable
|
@Nullable
|
||||||
public PersistableBundle getConfig() {
|
public PersistableBundle getConfig() {
|
||||||
return getConfigForSubId(SubscriptionManager.getDefaultSubscriptionId());
|
return getConfig(SubscriptionManager.getDefaultSubscriptionId());
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Calling this method triggers telephony services to fetch the current carrier configuration.
|
||||||
|
* <p>
|
||||||
|
* Normally this does not need to be called because the platform reloads config on its own.
|
||||||
|
* This should be called by a carrier service app if it wants to update config at an arbitrary
|
||||||
|
* moment.
|
||||||
|
* </p>
|
||||||
|
* <p>Requires that the calling app has carrier privileges.
|
||||||
|
* @see #hasCarrierPrivileges
|
||||||
|
* <p>
|
||||||
|
* This method returns before the reload has completed, and
|
||||||
|
* {@link android.service.carrier.CarrierService#onLoadConfig} will be called from an
|
||||||
|
* arbitrary thread.
|
||||||
|
* </p>
|
||||||
|
*
|
||||||
|
* @deprecated use notifyConfigChanged.
|
||||||
|
*/
|
||||||
|
public void notifyConfigChangedForSubId(int subId) {
|
||||||
|
notifyConfigChanged(subId);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -779,7 +819,7 @@ public class CarrierConfigManager {
|
|||||||
* arbitrary thread.
|
* arbitrary thread.
|
||||||
* </p>
|
* </p>
|
||||||
*/
|
*/
|
||||||
public void notifyConfigChangedForSubId(int subId) {
|
public void notifyConfigChanged(int subId) {
|
||||||
try {
|
try {
|
||||||
ICarrierConfigLoader loader = getICarrierConfigLoader();
|
ICarrierConfigLoader loader = getICarrierConfigLoader();
|
||||||
if (loader == null) {
|
if (loader == null) {
|
||||||
|
|||||||
Reference in New Issue
Block a user