• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2015 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package android.telephony;
18 
19 import android.Manifest;
20 import android.annotation.CallbackExecutor;
21 import android.annotation.FlaggedApi;
22 import android.annotation.IntDef;
23 import android.annotation.NonNull;
24 import android.annotation.Nullable;
25 import android.annotation.RequiresFeature;
26 import android.annotation.RequiresPermission;
27 import android.annotation.SuppressAutoDoc;
28 import android.annotation.SuppressLint;
29 import android.annotation.SystemApi;
30 import android.annotation.SystemService;
31 import android.compat.annotation.UnsupportedAppUsage;
32 import android.content.ComponentName;
33 import android.content.Context;
34 import android.content.pm.PackageManager;
35 import android.net.NetworkCapabilities;
36 import android.net.ipsec.ike.SaProposal;
37 import android.os.Build;
38 import android.os.Handler;
39 import android.os.PersistableBundle;
40 import android.os.RemoteException;
41 import android.service.carrier.CarrierService;
42 import android.telecom.TelecomManager;
43 import android.telephony.AccessNetworkConstants.AccessNetworkType;
44 import android.telephony.data.ApnSetting;
45 import android.telephony.gba.TlsParams;
46 import android.telephony.gba.UaSecurityProtocolIdentifier;
47 import android.telephony.ims.ImsReasonInfo;
48 import android.telephony.ims.ImsRegistrationAttributes;
49 import android.telephony.ims.ImsSsData;
50 import android.telephony.ims.MediaQualityStatus;
51 import android.telephony.ims.RcsUceAdapter;
52 import android.telephony.ims.feature.MmTelFeature;
53 import android.telephony.ims.feature.RcsFeature;
54 import android.telephony.satellite.SatelliteManager;
55 
56 import com.android.internal.telephony.ICarrierConfigLoader;
57 import com.android.internal.telephony.flags.Flags;
58 import com.android.telephony.Rlog;
59 
60 import java.util.List;
61 import java.util.Objects;
62 import java.util.concurrent.Executor;
63 import java.util.concurrent.TimeUnit;
64 import java.util.function.Consumer;
65 
66 /**
67  * Provides access to telephony configuration values that are carrier-specific.
68  */
69 @SystemService(Context.CARRIER_CONFIG_SERVICE)
70 @RequiresFeature(PackageManager.FEATURE_TELEPHONY_SUBSCRIPTION)
71 public class CarrierConfigManager {
72     private static final String TAG = "CarrierConfigManager";
73 
74     /**
75      * Extra included in {@link #ACTION_CARRIER_CONFIG_CHANGED} to indicate the slot index that the
76      * broadcast is for.
77      */
78     public static final String EXTRA_SLOT_INDEX = "android.telephony.extra.SLOT_INDEX";
79 
80     /**
81      * {@link #ACTION_CARRIER_CONFIG_CHANGED} is broadcast once on device bootup and then again when
82      * the device is unlocked. Direct-Boot-aware applications may use the first broadcast as an
83      * early signal that the carrier config has been loaded, but other applications will only
84      * receive the second broadcast, when the device is unlocked.
85      *
86      * This extra is included in {@link #ACTION_CARRIER_CONFIG_CHANGED} to indicate whether this is
87      * a rebroadcast on unlock.
88      */
89     public static final String EXTRA_REBROADCAST_ON_UNLOCK =
90             "android.telephony.extra.REBROADCAST_ON_UNLOCK";
91 
92     /**
93      * Optional extra included in {@link #ACTION_CARRIER_CONFIG_CHANGED} to indicate the
94      * subscription index that the broadcast is for, if a valid one is available.
95      */
96     public static final String EXTRA_SUBSCRIPTION_INDEX =
97             SubscriptionManager.EXTRA_SUBSCRIPTION_INDEX;
98 
99     /**
100      * Service class flag if no specific service class is specified.
101      * Reference: 3GPP TS 27.007 Section 7.4 Facility lock +CLCK
102      */
103     public static final int SERVICE_CLASS_NONE = ImsSsData.SERVICE_CLASS_NONE;
104 
105     /**
106      * Service class flag for voice telephony.
107      * Reference: 3GPP TS 27.007 Section 7.4 Facility lock +CLCK
108      */
109     public static final int SERVICE_CLASS_VOICE = ImsSsData.SERVICE_CLASS_VOICE;
110 
111     /**
112      * Only send USSD over IMS while CS is out of service, otherwise send USSD over CS.
113      * {@link #KEY_CARRIER_USSD_METHOD_INT}
114      */
115     public static final int USSD_OVER_CS_PREFERRED = 0;
116 
117     /**
118      * Send USSD over IMS or CS while IMS is out of service or silent redial over CS if needed.
119      * {@link #KEY_CARRIER_USSD_METHOD_INT}
120      */
121     public static final int USSD_OVER_IMS_PREFERRED = 1;
122 
123     /**
124      * Only send USSD over CS.
125      * {@link #KEY_CARRIER_USSD_METHOD_INT}
126      */
127     public static final int USSD_OVER_CS_ONLY = 2;
128 
129     /**
130      * Only send USSD over IMS and disallow silent redial over CS.
131      * {@link #KEY_CARRIER_USSD_METHOD_INT}
132      */
133     public static final int USSD_OVER_IMS_ONLY = 3;
134 
135     /**
136      * Indicates CARRIER_NR_AVAILABILITY_NSA determine that the carrier enable the non-standalone
137      * (NSA) mode of 5G NR.
138      */
139     public static final int CARRIER_NR_AVAILABILITY_NSA = 1;
140 
141     /**
142      * Indicates CARRIER_NR_AVAILABILITY_SA determine that the carrier enable the standalone (SA)
143      * mode of 5G NR.
144      */
145     public static final int CARRIER_NR_AVAILABILITY_SA = 2;
146 
147     private final Context mContext;
148 
149     /**
150      * @hide
151      */
CarrierConfigManager(Context context)152     public CarrierConfigManager(Context context) {
153         mContext = context;
154     }
155 
156     /**
157      * This intent is broadcast by the system when carrier config changes. An int is specified in
158      * {@link #EXTRA_SLOT_INDEX} to indicate the slot index that this is for. An optional int extra
159      * {@link #EXTRA_SUBSCRIPTION_INDEX} is included to indicate the subscription index if a valid
160      * one is available for the slot index. An optional int extra
161      * {@link TelephonyManager#EXTRA_CARRIER_ID} is included to indicate the carrier id for the
162      * changed carrier configuration. An optional int extra
163      * {@link TelephonyManager#EXTRA_SPECIFIC_CARRIER_ID} is included to indicate the precise
164      * carrier id for the changed carrier configuration.
165      * @see TelephonyManager#getSimCarrierId()
166      * @see TelephonyManager#getSimSpecificCarrierId()
167      */
168     public static final String ACTION_CARRIER_CONFIG_CHANGED =
169             "android.telephony.action.CARRIER_CONFIG_CHANGED";
170 
171     // Below are the keys used in carrier config bundles. To add a new variable, define the key and
172     // give it a default value in sDefaults. If you need to ship a per-network override in the
173     // system image, that can be added in packages/apps/CarrierConfig.
174 
175     /**
176      * Specifies a value that identifies the version of the carrier configuration that is
177      * currently in use. This string is displayed on the UI.
178      * The format of the string is not specified.
179      */
180     public static final String KEY_CARRIER_CONFIG_VERSION_STRING =
181             "carrier_config_version_string";
182 
183     /**
184      * This flag specifies whether VoLTE availability is based on provisioning. By default this is
185      * false.
186      * Used for UCE to determine if EAB provisioning checks should be based on provisioning.
187      * @deprecated Use {@link Ims#KEY_CARRIER_RCS_PROVISIONING_REQUIRED_BOOL} instead.
188      */
189     @Deprecated
190     public static final String KEY_CARRIER_VOLTE_PROVISIONED_BOOL =
191             "carrier_volte_provisioned_bool";
192 
193     /**
194      * Boolean indicating the Supplementary Services(SS) is disable when airplane mode on in the
195      * Call Settings menu.
196      * {@code true}: SS is disable when airplane mode on.
197      * {@code false}: SS is enable when airplane mode on.
198      * The default value for this key is {@code false}
199      */
200     public static final String KEY_DISABLE_SUPPLEMENTARY_SERVICES_IN_AIRPLANE_MODE_BOOL =
201             "disable_supplementary_services_in_airplane_mode_bool";
202 
203     /**
204      * Boolean indicating if the "Call forwarding" item is visible in the Call Settings menu.
205      * true means visible. false means gone.
206      * @hide
207      */
208     public static final String KEY_CALL_FORWARDING_VISIBILITY_BOOL =
209             "call_forwarding_visibility_bool";
210 
211     /**
212      * Boolean indicating if carrier supports call forwarding option "When unreachable".
213      *
214      * {@code true}: Call forwarding option "When unreachable" is supported.
215      * {@code false}: Call forwarding option "When unreachable" is not supported. Option will be
216      * removed in the UI.
217      *
218      * By default this value is true.
219      * @hide
220      */
221     public static final String KEY_CALL_FORWARDING_WHEN_UNREACHABLE_SUPPORTED_BOOL =
222             "call_forwarding_when_unreachable_supported_bool";
223 
224     /**
225      * Boolean indicating if carrier supports call forwarding option "When unanswered".
226      *
227      * {@code true}: Call forwarding option "When unanswered" is supported.
228      * {@code false}: Call forwarding option "When unanswered" is not supported. Option will be
229      * removed in the UI.
230      *
231      * By default this value is true.
232      * @hide
233      */
234     public static final String KEY_CALL_FORWARDING_WHEN_UNANSWERED_SUPPORTED_BOOL =
235             "call_forwarding_when_unanswered_supported_bool";
236 
237     /**
238      * Boolean indicating if carrier supports call forwarding option "When busy".
239      *
240      * {@code true}: Call forwarding option "When busy" is supported.
241      * {@code false}: Call forwarding option "When busy" is not supported. Option will be
242      * removed in the UI.
243      *
244      * By default this value is true.
245      * @hide
246      */
247     public static final String KEY_CALL_FORWARDING_WHEN_BUSY_SUPPORTED_BOOL =
248             "call_forwarding_when_busy_supported_bool";
249 
250     /**
251      * Boolean indicating if the "Caller ID" item is visible in the Additional Settings menu.
252      * true means visible. false means gone.
253      *
254      * The default value is true.
255      */
256     public static final String KEY_ADDITIONAL_SETTINGS_CALLER_ID_VISIBILITY_BOOL =
257             "additional_settings_caller_id_visibility_bool";
258 
259     /**
260      * Boolean indicating if the "Call Waiting" item is visible in the Additional Settings menu.
261      * true means visible. false means gone.
262      *
263      * The default value is true.
264      */
265     public static final String KEY_ADDITIONAL_SETTINGS_CALL_WAITING_VISIBILITY_BOOL =
266             "additional_settings_call_waiting_visibility_bool";
267 
268     /**
269      * Boolean indicating if the "Call barring" item is visible in the Call Settings menu.
270      * If true, the "Call Barring" menu will be visible. If false, the menu will be gone.
271      *
272      * Disabled by default.
273      */
274     public static final String KEY_CALL_BARRING_VISIBILITY_BOOL =
275             "call_barring_visibility_bool";
276 
277     /**
278      * Flag indicating whether or not changing the call barring password via the "Call Barring"
279      * settings menu is supported. If true, the option will be visible in the "Call
280      * Barring" settings menu. If false, the option will not be visible.
281      *
282      * Enabled by default.
283      */
284     public static final String KEY_CALL_BARRING_SUPPORTS_PASSWORD_CHANGE_BOOL =
285             "call_barring_supports_password_change_bool";
286 
287     /**
288      * Flag indicating whether or not deactivating all call barring features via the "Call Barring"
289      * settings menu is supported. If true, the option will be visible in the "Call
290      * Barring" settings menu. If false, the option will not be visible.
291      *
292      * Enabled by default.
293      */
294     public static final String KEY_CALL_BARRING_SUPPORTS_DEACTIVATE_ALL_BOOL =
295             "call_barring_supports_deactivate_all_bool";
296 
297     /**
298      * Specifies the service class for call barring service. Default value is
299      * {@link #SERVICE_CLASS_VOICE}.
300      * The value set as below:
301      * <ul>
302      * <li>0: {@link #SERVICE_CLASS_NONE}</li>
303      * <li>1: {@link #SERVICE_CLASS_VOICE}</li>
304      * </ul>
305      */
306     public static final String KEY_CALL_BARRING_DEFAULT_SERVICE_CLASS_INT =
307             "call_barring_default_service_class_int";
308 
309     /**
310      * This carrier supports dialing USSD codes to enable/disable supplementary services such as
311      * call forwarding and call waiting over CDMA.
312      * <p>
313      * The supplementary service menu will still need to be set as visible, see
314      * {@link #KEY_CALL_FORWARDING_VISIBILITY_BOOL} and
315      * {@link #KEY_ADDITIONAL_SETTINGS_CALL_WAITING_VISIBILITY_BOOL}.
316      * <p>
317      * If this is set as false and the supplementary service menu is visible, the associated setting
318      * will be enabled and disabled based on the availability of supplementary services over UT. See
319      * {@link #KEY_CARRIER_SUPPORTS_SS_OVER_UT_BOOL}.
320      * @deprecated Legacy CDMA is unsupported.
321      * @hide
322      */
323     @Deprecated
324     public static final String KEY_SUPPORT_SS_OVER_CDMA_BOOL = "support_ss_over_cdma_bool";
325 
326     /**
327      * Flag indicating whether the Phone app should ignore EVENT_SIM_NETWORK_LOCKED
328      * events from the Sim.
329      * If true, this will prevent the IccNetworkDepersonalizationPanel from being shown, and
330      * effectively disable the "Sim network lock" feature.
331      */
332     public static final String KEY_IGNORE_SIM_NETWORK_LOCKED_EVENTS_BOOL =
333             "ignore_sim_network_locked_events_bool";
334 
335     /**
336      * When checking if a given number is the voicemail number, if this flag is true
337      * then in addition to comparing the given number to the voicemail number, we also compare it
338      * to the mdn. If this flag is false, the given number is only compared to the voicemail number.
339      * By default this value is false.
340      */
341     public static final String KEY_MDN_IS_ADDITIONAL_VOICEMAIL_NUMBER_BOOL =
342             "mdn_is_additional_voicemail_number_bool";
343 
344     /**
345      * Flag indicating whether the Phone app should provide a "Dismiss" button on the SIM network
346      * unlock screen. The default value is true. If set to false, there will be *no way* to dismiss
347      * the SIM network unlock screen if you don't enter the correct unlock code. (One important
348      * consequence: there will be no way to make an Emergency Call if your SIM is network-locked and
349      * you don't know the PIN.)
350      */
351     public static final String KEY_SIM_NETWORK_UNLOCK_ALLOW_DISMISS_BOOL =
352             "sim_network_unlock_allow_dismiss_bool";
353 
354     /**
355      * Flag indicating whether or not sending emergency SMS messages over IMS
356      * is supported when in LTE/limited LTE (Emergency only) service mode..
357      */
358     public static final String KEY_SUPPORT_EMERGENCY_SMS_OVER_IMS_BOOL =
359             "support_emergency_sms_over_ims_bool";
360 
361     /** Flag indicating if the phone is a world phone */
362     public static final String KEY_WORLD_PHONE_BOOL = "world_phone_bool";
363 
364     /**
365      * Flag to require or skip entitlement checks.
366      * If true, entitlement checks will be executed if device has been configured for it,
367      * If false, entitlement checks will be skipped.
368      */
369     public static final String KEY_REQUIRE_ENTITLEMENT_CHECKS_BOOL =
370             "require_entitlement_checks_bool";
371 
372     /**
373      * Flag indicating if the carrier supports tethering of mobile data.
374      */
375     public static final String KEY_CARRIER_SUPPORTS_TETHERING_BOOL =
376             "carrier_supports_tethering_bool";
377 
378     /**
379      * Flag indicating whether radio is to be restarted on error PDP_FAIL_REGULAR_DEACTIVATION
380      * This is false by default.
381      *
382      * @deprecated Use {@link #KEY_RADIO_RESTART_FAILURE_CAUSES_INT_ARRAY} instead
383      */
384     @Deprecated
385     public static final String KEY_RESTART_RADIO_ON_PDP_FAIL_REGULAR_DEACTIVATION_BOOL =
386             "restart_radio_on_pdp_fail_regular_deactivation_bool";
387 
388     /**
389      * A list of failure cause codes that will trigger a modem restart when telephony receiving
390      * one of those during data setup. The cause codes are defined in 3GPP TS 24.008 Annex I and
391      * TS 24.301 Annex B.
392      */
393     public static final String KEY_RADIO_RESTART_FAILURE_CAUSES_INT_ARRAY =
394             "radio_restart_failure_causes_int_array";
395 
396     /**
397      * If true, enable vibration (haptic feedback) for key presses in the EmergencyDialer activity.
398      * The pattern is set on a per-platform basis using config_virtualKeyVibePattern. To be
399      * consistent with the regular Dialer, this value should agree with the corresponding values
400      * from config.xml under apps/Contacts.
401      */
402     public static final String KEY_ENABLE_DIALER_KEY_VIBRATION_BOOL =
403             "enable_dialer_key_vibration_bool";
404 
405     /** Flag indicating if dtmf tone type is enabled */
406     public static final String KEY_DTMF_TYPE_ENABLED_BOOL = "dtmf_type_enabled_bool";
407 
408     /** Flag indicating if auto retry is enabled */
409     public static final String KEY_AUTO_RETRY_ENABLED_BOOL = "auto_retry_enabled_bool";
410 
411     /**
412      * Determine whether we want to play local DTMF tones in a call, or just let the radio/BP handle
413      * playing of the tones.
414      */
415     public static final String KEY_ALLOW_LOCAL_DTMF_TONES_BOOL = "allow_local_dtmf_tones_bool";
416 
417     /**
418      * Determines if the carrier requires that a tone be played to the remote party when an app is
419      * recording audio during a call (e.g. using a call recording app).
420      * <p>
421      * Note: This requires the Telephony config_supports_telephony_audio_device overlay to be true
422      * in order to work.
423      * @deprecated this functionality was never used and is no longer supported.
424      * @hide
425      */
426     public static final String KEY_PLAY_CALL_RECORDING_TONE_BOOL = "play_call_recording_tone_bool";
427 
428     /**
429      * Determines if the carrier requires converting the destination number before sending out an
430      * SMS. Certain networks and numbering plans require different formats.
431      */
432     public static final String KEY_SMS_REQUIRES_DESTINATION_NUMBER_CONVERSION_BOOL =
433             "sms_requires_destination_number_conversion_bool";
434 
435     /**
436      * If true, show an onscreen "Dial" button in the dialer. In practice this is used on all
437      * platforms, even the ones with hard SEND/END keys, but for maximum flexibility it's controlled
438      * by a flag here (which can be overridden on a per-product basis.)
439      */
440     public static final String KEY_SHOW_ONSCREEN_DIAL_BUTTON_BOOL =
441             "show_onscreen_dial_button_bool";
442 
443     /** Determines if device implements a noise suppression device for in call audio. */
444     public static final String
445             KEY_HAS_IN_CALL_NOISE_SUPPRESSION_BOOL = "has_in_call_noise_suppression_bool";
446 
447     /**
448      * Determines if the current device should allow emergency numbers to be logged in the Call Log.
449      * (Some carriers require that emergency calls *not* be logged, presumably to avoid the risk of
450      * accidental redialing from the call log UI. This is a good idea, so the default here is
451      * false.)
452      */
453     public static final String KEY_ALLOW_EMERGENCY_NUMBERS_IN_CALL_LOG_BOOL =
454             "allow_emergency_numbers_in_call_log_bool";
455 
456     /**
457      * A string array containing numbers that shouldn't be included in the call log.
458      */
459     public static final String KEY_UNLOGGABLE_NUMBERS_STRING_ARRAY =
460             "unloggable_numbers_string_array";
461 
462     /** If true, removes the Voice Privacy option from Call Settings */
463     public static final String KEY_VOICE_PRIVACY_DISABLE_UI_BOOL = "voice_privacy_disable_ui_bool";
464 
465     /** Control whether users can reach the carrier portions of Cellular Network Settings. */
466     public static final String
467             KEY_HIDE_CARRIER_NETWORK_SETTINGS_BOOL = "hide_carrier_network_settings_bool";
468 
469     /**
470      * Only allow auto selection in Advanced Network Settings when in home network.
471      * Manual selection is allowed when in roaming network.
472      */
473     public static final String KEY_ONLY_AUTO_SELECT_IN_HOME_NETWORK_BOOL =
474             "only_auto_select_in_home_network";
475 
476     /**
477      * Flag indicating whether to show single operator row in the choose network setting.
478      *
479      * The device configuration value {@code config_enableNewAutoSelectNetworkUI} ultimately
480      * controls whether this carrier configuration option is used.
481      * Where {@code config_enableNewAutoSelectNetworkUI} is false, the value of this
482      * carrier configuration is ignored.
483      *
484      * If {@code true}, default value, merge the duplicate networks which with the same plmn, keep
485      * the one that with the higher signal strength level.
486      * If {@code false}, show all operators without merging.
487      * @hide
488      */
489     public static final String KEY_SHOW_SINGLE_OPERATOR_ROW_IN_CHOOSE_NETWORK_SETTING_BOOL =
490             "show_single_operator_row_in_choose_network_setting_bool";
491 
492     /**
493      * Flag indicating whether to display SPN as network name for home network in choose
494      * network setting.
495      *
496      * If {@code true}, display SPN as network name in choose network setting.
497      * If {@code false}, display PLMN in choose network setting.
498      * @hide
499      */
500     public static final String KEY_SHOW_SPN_FOR_HOME_IN_CHOOSE_NETWORK_SETTING_BOOL =
501             "show_spn_for_home_in_choose_network_setting_bool";
502 
503     /**
504      * Control whether users receive a simplified network settings UI and improved network
505      * selection.
506      *
507      * @deprecated Never implemented. Has no behavior impact when override. DO NOT USE.
508      */
509     @Deprecated
510     public static final String KEY_SIMPLIFIED_NETWORK_SETTINGS_BOOL =
511             "simplified_network_settings_bool";
512 
513     /** Control whether users can reach the SIM lock settings. */
514     public static final String KEY_HIDE_SIM_LOCK_SETTINGS_BOOL = "hide_sim_lock_settings_bool";
515 
516     /** Control whether users can edit APNs in Settings. */
517     public static final String KEY_APN_EXPAND_BOOL = "apn_expand_bool";
518 
519     /** Control whether users can choose a network operator. */
520     public static final String KEY_OPERATOR_SELECTION_EXPAND_BOOL =
521             "operator_selection_expand_bool";
522 
523     /**
524      * Used in the Preferred Network Types menu to determine if the 2G option is displayed.
525      * Value defaults to false as of Android T to discourage the use of insecure 2G protocols.
526      */
527     public static final String KEY_PREFER_2G_BOOL = "prefer_2g_bool";
528 
529     /**
530      * Used in the Preferred Network Types menu to determine if the 3G option is displayed.
531      */
532     @FlaggedApi(Flags.FLAG_HIDE_PREFER_3G_ITEM)
533     public static final String KEY_PREFER_3G_VISIBILITY_BOOL = "prefer_3g_visibility_bool";
534 
535     /**
536      * Used in Cellular Network Settings for preferred network type to show 4G only mode.
537      * @hide
538      */
539     public static final String KEY_4G_ONLY_BOOL = "4g_only_bool";
540 
541     /** Show cdma network mode choices 1x, 3G, global etc.
542      * @deprecated Legacy CDMA is unsupported.
543      */
544     @Deprecated
545     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
546     public static final String KEY_SHOW_CDMA_CHOICES_BOOL = "show_cdma_choices_bool";
547 
548     /** CDMA activation goes through HFA */
549     public static final String KEY_USE_HFA_FOR_PROVISIONING_BOOL = "use_hfa_for_provisioning_bool";
550 
551     /**
552      * CDMA activation goes through OTASP.
553      * @deprecated Legacy CDMA is unsupported.
554      */
555     // TODO: This should be combined with config_use_hfa_for_provisioning and implemented as an enum
556     // (NONE, HFA, OTASP).
557     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
558     @Deprecated
559     public static final String KEY_USE_OTASP_FOR_PROVISIONING_BOOL =
560             "use_otasp_for_provisioning_bool";
561 
562     /** Display carrier settings menu if true */
563     public static final String KEY_CARRIER_SETTINGS_ENABLE_BOOL = "carrier_settings_enable_bool";
564 
565     /** Does not display additional call setting for IMS phone based on GSM Phone */
566     public static final String KEY_ADDITIONAL_CALL_SETTING_BOOL = "additional_call_setting_bool";
567 
568     /**
569      * Show APN Settings for some CDMA carriers
570      * @deprecated Legacy CDMA is unsupported.
571      */
572     @Deprecated
573     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
574     public static final String KEY_SHOW_APN_SETTING_CDMA_BOOL = "show_apn_setting_cdma_bool";
575 
576     /**
577      * After a CDMA conference call is merged, the swap button should be displayed.
578      * @deprecated Legacy CDMA is unsupported.
579      */
580     @Deprecated
581     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
582     public static final String KEY_SUPPORT_SWAP_AFTER_MERGE_BOOL = "support_swap_after_merge_bool";
583 
584     /**
585      * Determine whether user can edit voicemail number in Settings.
586      */
587     public static final String KEY_EDITABLE_VOICEMAIL_NUMBER_SETTING_BOOL =
588             "editable_voicemail_number_setting_bool";
589 
590     /**
591      * Since the default voicemail number is empty, if a SIM card does not have a voicemail number
592      * available the user cannot use voicemail. This flag allows the user to edit the voicemail
593      * number in such cases, and is false by default.
594      */
595     public static final String KEY_EDITABLE_VOICEMAIL_NUMBER_BOOL =
596             "editable_voicemail_number_bool";
597 
598     /**
599      * Determine whether the voicemail number in Settings is hidden.
600      * @hide
601      */
602     public static final String KEY_HIDE_VOICEMAIL_NUMBER_SETTING_BOOL =
603             "hide_voicemail_number_setting_bool";
604 
605     /**
606      * Determine whether the voicemail notification is persistent in the notification bar. If true,
607      * the voicemail notifications cannot be dismissed from the notification bar.
608      */
609     public static final String KEY_VOICEMAIL_NOTIFICATION_PERSISTENT_BOOL =
610             "voicemail_notification_persistent_bool";
611 
612     /** For IMS video over LTE calls, determines whether video pause signalling is supported. */
613     public static final String KEY_SUPPORT_PAUSE_IMS_VIDEO_CALLS_BOOL =
614             "support_pause_ims_video_calls_bool";
615 
616     /**
617      * Disables dialing "*228" (OTASP provisioning) on CDMA carriers where it is not supported or is
618      * potentially harmful by locking the SIM to 3G.
619      * @deprecated Legacy CDMA is unsupported.
620      */
621     @Deprecated
622     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
623     public static final String KEY_DISABLE_CDMA_ACTIVATION_CODE_BOOL =
624             "disable_cdma_activation_code_bool";
625 
626     /**
627      * List of network type constants which support only a single data connection at a time.
628      * Some carriers do not support multiple PDP on UMTS.
629      * @see TelephonyManager NETWORK_TYPE_*
630      * @see #KEY_ONLY_SINGLE_DC_ALLOWED_INT_ARRAY
631      */
632     public static final String KEY_ONLY_SINGLE_DC_ALLOWED_INT_ARRAY =
633             "only_single_dc_allowed_int_array";
634 
635     /**
636      * Only apply if {@link #KEY_ONLY_SINGLE_DC_ALLOWED_INT_ARRAY} specifies the network types that
637      * support a single data connection at a time. This key defines a list of network capabilities
638      * which, if requested, will exempt the request from single data connection checks.
639      * @see NetworkCapabilities NET_CAPABILITY_*
640      */
641     public static final String KEY_CAPABILITIES_EXEMPT_FROM_SINGLE_DC_CHECK_INT_ARRAY =
642             "capabilities_exempt_from_single_dc_check_int_array";
643 
644     /**
645      * Override the platform's notion of a network operator being considered roaming.
646      * Value is string array of MCCMNCs to be considered roaming for 3GPP RATs.
647      */
648     public static final String KEY_GSM_ROAMING_NETWORKS_STRING_ARRAY =
649             "gsm_roaming_networks_string_array";
650 
651     /**
652      * Override the platform's notion of a network operator being considered not roaming.
653      * Value is string array of MCCMNCs to be considered not roaming for 3GPP RATs.
654      */
655     public static final String KEY_GSM_NONROAMING_NETWORKS_STRING_ARRAY =
656             "gsm_nonroaming_networks_string_array";
657 
658     /**
659      * The package name containing the ImsService that will be bound to the telephony framework to
660      * support both IMS MMTEL and RCS feature functionality instead of the device default
661      * ImsService for this subscription.
662      * @deprecated Use {@link #KEY_CONFIG_IMS_MMTEL_PACKAGE_OVERRIDE_STRING} and
663      * {@link #KEY_CONFIG_IMS_RCS_PACKAGE_OVERRIDE_STRING} instead to configure these values
664      * separately. If any of those values are not empty, they will override this value.
665      */
666     @Deprecated
667     public static final String KEY_CONFIG_IMS_PACKAGE_OVERRIDE_STRING =
668             "config_ims_package_override_string";
669 
670     /**
671      * The package name containing the ImsService that will be bound to the telephony framework to
672      * support IMS MMTEL feature functionality instead of the device default ImsService for this
673      * subscription.
674      */
675     public static final String KEY_CONFIG_IMS_MMTEL_PACKAGE_OVERRIDE_STRING =
676             "config_ims_mmtel_package_override_string";
677 
678     /**
679      * The package name containing the ImsService that will be bound to the telephony framework to
680      * support IMS RCS feature functionality instead of the device default ImsService for this
681      * subscription.
682      */
683     public static final String KEY_CONFIG_IMS_RCS_PACKAGE_OVERRIDE_STRING =
684             "config_ims_rcs_package_override_string";
685 
686     /**
687      * Override the package that will manage {@link SubscriptionPlan}
688      * information instead of the {@link CarrierService} that defines this
689      * value.
690      *
691      * @see SubscriptionManager#getSubscriptionPlans(int)
692      * @see SubscriptionManager#setSubscriptionPlans(int, java.util.List)
693      */
694     public static final String KEY_CONFIG_PLANS_PACKAGE_OVERRIDE_STRING =
695             "config_plans_package_override_string";
696 
697     /**
698      * Override the platform's notion of a network operator being considered roaming.
699      * Value is string array of SIDs to be considered roaming for 3GPP2 RATs.
700      * @deprecated Legacy CDMA is unsupported.
701      */
702     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
703     @Deprecated
704     public static final String
705             KEY_CDMA_ROAMING_NETWORKS_STRING_ARRAY = "cdma_roaming_networks_string_array";
706 
707     /**
708      * Override the platform's notion of a network operator being considered non roaming.
709      * Value is string array of SIDs to be considered not roaming for 3GPP2 RATs.
710      * @deprecated Legacy CDMA is unsupported.
711      */
712     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
713     @Deprecated
714     public static final String
715             KEY_CDMA_NONROAMING_NETWORKS_STRING_ARRAY = "cdma_nonroaming_networks_string_array";
716 
717     /**
718      * Override the platform's notion of a network operator being considered non roaming.
719      * If true all networks are considered as home network a.k.a. non-roaming. When false,
720      * the 2 pairs of CMDA and GSM roaming/non-roaming arrays are consulted.
721      *
722      * @see #KEY_GSM_ROAMING_NETWORKS_STRING_ARRAY
723      * @see #KEY_GSM_NONROAMING_NETWORKS_STRING_ARRAY
724      * @see #KEY_CDMA_ROAMING_NETWORKS_STRING_ARRAY
725      * @see #KEY_CDMA_NONROAMING_NETWORKS_STRING_ARRAY
726      */
727     public static final String
728             KEY_FORCE_HOME_NETWORK_BOOL = "force_home_network_bool";
729 
730     /**
731      * Flag specifying whether VoLTE should be available for carrier, independent of carrier
732      * provisioning. If false: hard disabled. If true: then depends on carrier provisioning,
733      * availability, etc.
734      */
735     public static final String KEY_CARRIER_VOLTE_AVAILABLE_BOOL = "carrier_volte_available_bool";
736 
737     /**
738      * Flag specifying whether video telephony is available for carrier. If false: hard disabled.
739      * If true: then depends on carrier provisioning, availability, etc.
740      */
741     public static final String KEY_CARRIER_VT_AVAILABLE_BOOL = "carrier_vt_available_bool";
742 
743     /**
744      * Specify the method of selection for UE sending USSD requests. The default value is
745      * {@link #USSD_OVER_CS_PREFERRED}.
746      * <p> Available options:
747      * <ul>
748      *   <li>0: {@link #USSD_OVER_CS_PREFERRED} </li>
749      *   <li>1: {@link #USSD_OVER_IMS_PREFERRED} </li>
750      *   <li>2: {@link #USSD_OVER_CS_ONLY} </li>
751      *   <li>3: {@link #USSD_OVER_IMS_ONLY} </li>
752      * </ul>
753      */
754     public static final String KEY_CARRIER_USSD_METHOD_INT = "carrier_ussd_method_int";
755 
756     /**
757      * Flag specifying whether to show an alert dialog for 5G disable when the user disables VoLTE.
758      * By default this value is {@code false}.
759      *
760      * @hide
761      */
762     public static final String KEY_VOLTE_5G_LIMITED_ALERT_DIALOG_BOOL =
763             "volte_5g_limited_alert_dialog_bool";
764 
765     /**
766      * Flag specifying whether the carrier wants to notify the user when a VT call has been handed
767      * over from WIFI to LTE.
768      * <p>
769      * The handover notification is sent as a
770      * {@link TelephonyManager#EVENT_HANDOVER_VIDEO_FROM_WIFI_TO_LTE}
771      * {@link android.telecom.Connection} event, which an {@link android.telecom.InCallService}
772      * should use to trigger the display of a user-facing message.
773      * <p>
774      * The Connection event is sent to the InCallService only once, the first time it occurs.
775      * @hide
776      */
777     public static final String KEY_NOTIFY_HANDOVER_VIDEO_FROM_WIFI_TO_LTE_BOOL =
778             "notify_handover_video_from_wifi_to_lte_bool";
779 
780     /**
781      * Flag specifying whether the carrier supports merging a RTT call with a voice call,
782      * downgrading the call in the process.
783      * @hide
784      */
785     public static final String KEY_ALLOW_MERGING_RTT_CALLS_BOOL = "allow_merging_rtt_calls_bool";
786 
787     /**
788      * Flag specifying whether the carrier wants to notify the user when a VT call has been handed
789      * over from LTE to WIFI.
790      * <p>
791      * The handover notification is sent as a
792      * {@link TelephonyManager#EVENT_HANDOVER_VIDEO_FROM_LTE_TO_WIFI}
793      * {@link android.telecom.Connection} event, which an {@link android.telecom.InCallService}
794      * should use to trigger the display of a user-facing message.
795      * @hide
796      */
797     public static final String KEY_NOTIFY_HANDOVER_VIDEO_FROM_LTE_TO_WIFI_BOOL =
798             "notify_handover_video_from_lte_to_wifi_bool";
799 
800     /**
801      * Flag specifying whether the carrier supports downgrading a video call (tx, rx or tx/rx)
802      * directly to an audio call.
803      * @hide
804      */
805     public static final String KEY_SUPPORT_DOWNGRADE_VT_TO_AUDIO_BOOL =
806             "support_downgrade_vt_to_audio_bool";
807 
808     /**
809      * Where there is no preloaded voicemail number on a SIM card, specifies the carrier's default
810      * voicemail number.
811      * When empty string, no default voicemail number is specified.
812      */
813     public static final String KEY_DEFAULT_VM_NUMBER_STRING = "default_vm_number_string";
814 
815     /**
816      * Where there is no preloaded voicemail number on a SIM card, specifies the carrier's default
817      * voicemail number for roaming network.
818      * When empty string, no default voicemail number is specified for roaming network.
819      * @hide
820      */
821     public static final String KEY_DEFAULT_VM_NUMBER_ROAMING_STRING =
822             "default_vm_number_roaming_string";
823 
824     /**
825      * Where there is no preloaded voicemail number on a SIM card, specifies the carrier's default
826      * voicemail number while the device is both roaming and not registered for IMS.
827      * When empty string, no default voicemail number is specified for roaming network and
828      * unregistered state in IMS.
829      */
830     public static final String KEY_DEFAULT_VM_NUMBER_ROAMING_AND_IMS_UNREGISTERED_STRING =
831             "default_vm_number_roaming_and_ims_unregistered_string";
832 
833     /**
834      * Flag that specifies to use the user's own phone number as the voicemail number when there is
835      * no pre-loaded voicemail number on the SIM card.
836      * <p>
837      * {@link #KEY_DEFAULT_VM_NUMBER_STRING} takes precedence over this flag.
838      * <p>
839      * If false, the system default (*86) will be used instead.
840      */
841     public static final String KEY_CONFIG_TELEPHONY_USE_OWN_NUMBER_FOR_VOICEMAIL_BOOL =
842             "config_telephony_use_own_number_for_voicemail_bool";
843 
844     /**
845      * When {@code true}, changes to the mobile data enabled switch will not cause the VT
846      * registration state to change. That is, turning on or off mobile data will not cause VT to be
847      * enabled or disabled.
848      * When {@code false}, disabling mobile data will cause VT to be de-registered.
849      */
850     public static final String KEY_IGNORE_DATA_ENABLED_CHANGED_FOR_VIDEO_CALLS =
851             "ignore_data_enabled_changed_for_video_calls";
852 
853     /**
854      * Flag indicating whether data used for a video call over LTE is metered or not.
855      * <p>
856      * When {@code true}, if the device hits the data limit or data is disabled during a ViLTE call,
857      * the call will be downgraded to audio-only (or paused if
858      * {@link #KEY_SUPPORT_PAUSE_IMS_VIDEO_CALLS_BOOL} is {@code true}).
859      *
860      * @hide
861      */
862     public static final String KEY_VILTE_DATA_IS_METERED_BOOL = "vilte_data_is_metered_bool";
863 
864     /**
865      * Flag specifying whether WFC over IMS should be available for carrier: independent of
866      * carrier provisioning. If false: hard disabled. If true: then depends on carrier
867      * provisioning, availability etc.
868      */
869     public static final String KEY_CARRIER_WFC_IMS_AVAILABLE_BOOL =
870             "carrier_wfc_ims_available_bool";
871 
872     /**
873      * Flag specifying whether Cross SIM over IMS should be available for carrier.
874      * When {@code false} the carrier does not support cross SIM calling.
875      * When {@code true} the carrier does support cross sim calling, where available
876      */
877     public static final String KEY_CARRIER_CROSS_SIM_IMS_AVAILABLE_BOOL =
878             "carrier_cross_sim_ims_available_bool";
879 
880     /**
881      * Flag specifying whether cross sim calling on opportunistic data is supported for carrier.
882      * When {@code false} the carrier does not support cross sim calling on opportunistic data.
883      * When {@code true} the carrier does support cross sim calling on opportunistic data.
884      */
885     public static final String KEY_ENABLE_CROSS_SIM_CALLING_ON_OPPORTUNISTIC_DATA_BOOL =
886             "enable_cross_sim_calling_on_opportunistic_data_bool";
887 
888     /**
889      * Specifies a map from dialstrings to replacements for roaming network service numbers which
890      * cannot be replaced on the carrier side.
891      * <p>
892      * Individual entries have the format:
893      * [dialstring to replace]:[replacement]
894      */
895     public static final String KEY_DIAL_STRING_REPLACE_STRING_ARRAY =
896             "dial_string_replace_string_array";
897 
898     /**
899      * Specifies a map from dialstrings to replacements for international roaming network service
900      * numbers which cannot be replaced on the carrier side.
901      * <p>
902      * Individual entries have the format:
903      * [dialstring to replace]:[replacement]
904      * @hide
905      */
906     public static final String KEY_INTERNATIONAL_ROAMING_DIAL_STRING_REPLACE_STRING_ARRAY =
907             "international_roaming_dial_string_replace_string_array";
908 
909     /**
910      * Flag specifying whether WFC over IMS supports the "wifi only" option. If false, the wifi
911      * calling settings will not include an option for "wifi only". If true, the wifi calling
912      * settings will include an option for "wifi only"
913      * <p>
914      * By default, it is assumed that WFC supports "wifi only".
915      */
916     public static final String KEY_CARRIER_WFC_SUPPORTS_WIFI_ONLY_BOOL =
917             "carrier_wfc_supports_wifi_only_bool";
918 
919     /**
920      * Default mode for WFC over IMS on home network:
921      * <ul>
922      *   <li>0: Wi-Fi only
923      *   <li>1: prefer mobile network
924      *   <li>2: prefer Wi-Fi
925      * </ul>
926      */
927     public static final String KEY_CARRIER_DEFAULT_WFC_IMS_MODE_INT =
928             "carrier_default_wfc_ims_mode_int";
929 
930     /**
931      * Default mode for WFC over IMS on roaming network.
932      * See {@link #KEY_CARRIER_DEFAULT_WFC_IMS_MODE_INT} for meaning of values.
933      */
934     public static final String KEY_CARRIER_DEFAULT_WFC_IMS_ROAMING_MODE_INT =
935             "carrier_default_wfc_ims_roaming_mode_int";
936 
937     /**
938      * Default WFC_IMS_enabled: true VoWiFi by default is on
939      *                          false VoWiFi by default is off
940      */
941     public static final String KEY_CARRIER_DEFAULT_WFC_IMS_ENABLED_BOOL =
942             "carrier_default_wfc_ims_enabled_bool";
943 
944     /**
945      * Default WFC_IMS_roaming_enabled: true VoWiFi roaming by default is on
946      *                                  false VoWiFi roaming by default is off
947      * @hide
948      */
949     public static final String KEY_CARRIER_DEFAULT_WFC_IMS_ROAMING_ENABLED_BOOL =
950             "carrier_default_wfc_ims_roaming_enabled_bool";
951 
952     /**
953      * Flag indicating whether failed calls due to no service should prompt the user to enable
954      * WIFI calling. When {@code true}, if the user attempts to establish a call when there is no
955      * service available, they are connected to WIFI, and WIFI calling is disabled, a different
956      * call failure message will be used to encourage the user to enable WIFI calling.
957      * @hide
958      */
959     public static final String KEY_CARRIER_PROMOTE_WFC_ON_CALL_FAIL_BOOL =
960             "carrier_promote_wfc_on_call_fail_bool";
961 
962     /**
963      * Flag specifying whether provisioning is required for RCS.
964      */
965     public static final String KEY_CARRIER_RCS_PROVISIONING_REQUIRED_BOOL =
966             "carrier_rcs_provisioning_required_bool";
967 
968     /**
969      * Flag specifying whether provisioning is required for VoLTE, Video Telephony, and WiFi
970      * Calling.
971 
972      * Combines VoLTE, VT, VoWiFI calling provisioning into one parameter.
973      * @deprecated Use {@link Ims#KEY_MMTEL_REQUIRES_PROVISIONING_BUNDLE} instead for
974      * finer-grained control.
975      * changing carrier_volte_provisioning_required_bool requires changes to
976      * mmtel_requires_provisioning_bundle and vice versa
977      * {@link Ims#KEY_MMTEL_REQUIRES_PROVISIONING_BUNDLE}
978      */
979     @Deprecated
980     public static final String KEY_CARRIER_VOLTE_PROVISIONING_REQUIRED_BOOL =
981             "carrier_volte_provisioning_required_bool";
982 
983     /**
984      * Flag indicating whether or not the IMS MmTel UT capability requires carrier provisioning
985      * before it can be set as enabled.
986      *
987      * If true, the UT capability will be set to false for the newly loaded subscription
988      * and will require the carrier provisioning app to set the persistent provisioning result.
989      * If false, the platform will not wait for provisioning status updates for the UT capability
990      * and enable the UT over IMS capability for the subscription when the subscription is loaded.
991      *
992      * The default value for this key is {@code false}.
993      *
994      * @deprecated Use {@link Ims#KEY_MMTEL_REQUIRES_PROVISIONING_BUNDLE} instead for
995      * determining if UT requires provisioning.
996      */
997     @Deprecated
998     public static final String KEY_CARRIER_UT_PROVISIONING_REQUIRED_BOOL =
999             "carrier_ut_provisioning_required_bool";
1000 
1001     /**
1002      * Flag indicating whether or not the carrier supports Supplementary Services over the UT
1003      * interface for this subscription.
1004      *
1005      * If true, the device will use Supplementary Services over UT when provisioned (see
1006      * {@link #KEY_CARRIER_UT_PROVISIONING_REQUIRED_BOOL}). If false, this device will fallback to
1007      * circuit switch for supplementary services and will disable this capability for IMS entirely.
1008      *
1009      * The default value for this key is {@code false}.
1010      */
1011     public static final String KEY_CARRIER_SUPPORTS_SS_OVER_UT_BOOL =
1012             "carrier_supports_ss_over_ut_bool";
1013 
1014     /**
1015      * Flag specifying if WFC provisioning depends on VoLTE provisioning.
1016      *
1017      * {@code false}: default value; honor actual WFC provisioning state.
1018      * {@code true}: when VoLTE is not provisioned, treat WFC as not provisioned; when VoLTE is
1019      *               provisioned, honor actual WFC provisioning state.
1020      *
1021      * As of now, Verizon is the only carrier enforcing this dependency in their
1022      * WFC awareness and activation requirements.
1023      */
1024     public static final String KEY_CARRIER_VOLTE_OVERRIDE_WFC_PROVISIONING_BOOL =
1025             "carrier_volte_override_wfc_provisioning_bool";
1026 
1027     /**
1028      * Override the device's configuration for the cellular data service to use for this SIM card.
1029      * @hide
1030      */
1031     public static final String KEY_CARRIER_DATA_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING =
1032             "carrier_data_service_wwan_package_override_string";
1033 
1034     /**
1035      * Override the device's configuration for the IWLAN data service to use for this SIM card.
1036      * @hide
1037      */
1038     public static final String KEY_CARRIER_DATA_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING =
1039             "carrier_data_service_wlan_package_override_string";
1040 
1041     /**
1042      * Override the device's configuration for the cellular data service class to use
1043      * for this SIM card.
1044      * @hide
1045      */
1046     public static final String KEY_CARRIER_DATA_SERVICE_WWAN_CLASS_OVERRIDE_STRING =
1047             "carrier_data_service_wwan_class_override_string";
1048 
1049     /**
1050      * Override the device's configuration for the IWLAN data service class to use
1051      * for this SIM card.
1052      * @hide
1053      */
1054     public static final String KEY_CARRIER_DATA_SERVICE_WLAN_CLASS_OVERRIDE_STRING =
1055             "carrier_data_service_wlan_class_override_string";
1056 
1057     /** Flag specifying whether VoLTE TTY is supported. */
1058     public static final String KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL =
1059             "carrier_volte_tty_supported_bool";
1060 
1061     /** Flag specifying whether VoWIFI TTY is supported.
1062      * @hide
1063      */
1064     public static final String KEY_CARRIER_VOWIFI_TTY_SUPPORTED_BOOL =
1065             "carrier_vowifi_tty_supported_bool";
1066 
1067     /**
1068      * Flag specifying whether IMS service can be turned off. If false then the service will not be
1069      * turned-off completely, but individual features can be disabled.
1070      */
1071     public static final String KEY_CARRIER_ALLOW_TURNOFF_IMS_BOOL =
1072             "carrier_allow_turnoff_ims_bool";
1073 
1074     /**
1075      * Flag specifying whether Generic Bootstrapping Architecture capable SIM is required for IMS.
1076      */
1077     public static final String KEY_CARRIER_IMS_GBA_REQUIRED_BOOL =
1078             "carrier_ims_gba_required_bool";
1079 
1080     /**
1081      * Flag specifying whether IMS instant lettering is available for the carrier. {@code True} if
1082      * instant lettering is available for the carrier, {@code false} otherwise.
1083      */
1084     public static final String KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL =
1085             "carrier_instant_lettering_available_bool";
1086 
1087     /**
1088      * Flag specifying whether IMS should be the first phone attempted for E911 even if the
1089      * phone is not in service.
1090      */
1091     public static final String KEY_CARRIER_USE_IMS_FIRST_FOR_EMERGENCY_BOOL =
1092             "carrier_use_ims_first_for_emergency_bool";
1093 
1094     /**
1095      * When {@code true}, this carrier will preferentially dial normal routed emergency calls over
1096      * an in-service SIM if one is available.
1097      * @hide
1098      */
1099     public static final String KEY_PREFER_IN_SERVICE_SIM_FOR_NORMAL_ROUTED_EMERGENCY_CALLS_BOOL =
1100             "prefer_in_service_sim_for_normal_routed_emergency_calls_bool";
1101 
1102     /**
1103      * When {@code true}, the determination of whether to place a call as an emergency call will be
1104      * based on the known {@link android.telephony.emergency.EmergencyNumber}s for the SIM on which
1105      * the call is being placed. In a dual SIM scenario, if Sim A has the emergency numbers
1106      * 123, 456 and Sim B has the emergency numbers 789, and the user places a call on SIM A to 789,
1107      * it will not be treated as an emergency call in this case.
1108      * When {@code false}, the determination is based on the emergency numbers from all device SIMs,
1109      * regardless of which SIM the call is being placed on. If Sim A has the emergency numbers
1110      * 123, 456 and Sim B has the emergency numbers 789, and the user places a call on SIM A to 789,
1111      * the call will be dialed as an emergency number, but with an unspecified routing.
1112      * @hide
1113      */
1114     public static final String KEY_USE_ONLY_DIALED_SIM_ECC_LIST_BOOL =
1115             "use_only_dialed_sim_ecc_list_bool";
1116 
1117     /**
1118      * When IMS instant lettering is available for a carrier (see
1119      * {@link #KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL}), determines the list of characters
1120      * which may not be contained in messages. Should be specified as a regular expression suitable
1121      * for use with {@link String#matches(String)}.
1122      */
1123     public static final String KEY_CARRIER_INSTANT_LETTERING_INVALID_CHARS_STRING =
1124             "carrier_instant_lettering_invalid_chars_string";
1125 
1126     /**
1127      * When IMS instant lettering is available for a carrier (see
1128      * {@link #KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL}), determines a list of characters which
1129      * must be escaped with a backslash '\' character. Should be specified as a string containing
1130      * the characters to be escaped. For example to escape quote and backslash the string would be
1131      * a quote and a backslash.
1132      */
1133     public static final String KEY_CARRIER_INSTANT_LETTERING_ESCAPED_CHARS_STRING =
1134             "carrier_instant_lettering_escaped_chars_string";
1135 
1136     /**
1137      * When IMS instant lettering is available for a carrier (see
1138      * {@link #KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL}), determines the character encoding
1139      * which will be used when determining the length of messages. Used in the InCall UI to limit
1140      * the number of characters the user may type. If empty-string, the instant lettering
1141      * message size limit will be enforced on a 1:1 basis. That is, each character will count
1142      * towards the messages size limit as a single byte. If a character encoding is specified, the
1143      * message size limit will be based on the number of bytes in the message per the specified
1144      * encoding.
1145      */
1146     public static final String KEY_CARRIER_INSTANT_LETTERING_ENCODING_STRING =
1147             "carrier_instant_lettering_encoding_string";
1148 
1149     /**
1150      * When IMS instant lettering is available for a carrier (see
1151      * {@link #KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL}), the length limit for messages. Used
1152      * in the InCall UI to ensure the user cannot enter more characters than allowed by the carrier.
1153      * See also {@link #KEY_CARRIER_INSTANT_LETTERING_ENCODING_STRING} for more information on how
1154      * the length of the message is calculated.
1155      */
1156     public static final String KEY_CARRIER_INSTANT_LETTERING_LENGTH_LIMIT_INT =
1157             "carrier_instant_lettering_length_limit_int";
1158 
1159     /**
1160      * If Voice Radio Technology is RIL_RADIO_TECHNOLOGY_LTE:14 or RIL_RADIO_TECHNOLOGY_UNKNOWN:0
1161      * this is the value that should be used instead. A configuration value of
1162      * RIL_RADIO_TECHNOLOGY_UNKNOWN:0 means there is no replacement value and that the default
1163      * assumption for phone type (GSM) should be used.
1164      */
1165     public static final String KEY_VOLTE_REPLACEMENT_RAT_INT = "volte_replacement_rat_int";
1166 
1167     /**
1168      * The default sim call manager to use when the default dialer doesn't implement one. A sim call
1169      * manager can control and route outgoing and incoming phone calls, even if they're placed
1170      * using another connection service (PSTN, for example).
1171      */
1172     public static final String KEY_DEFAULT_SIM_CALL_MANAGER_STRING =
1173             "default_sim_call_manager_string";
1174 
1175     /**
1176      * The default flag specifying whether ETWS/CMAS test setting is forcibly disabled in
1177      * Settings->More->Emergency broadcasts menu even though developer options is turned on.
1178      * @deprecated Use {@code com.android.cellbroadcastreceiver.CellBroadcastReceiver} resource
1179      * {@code show_test_settings} to control whether to show test alert settings or not.
1180      */
1181     @Deprecated
1182     public static final String KEY_CARRIER_FORCE_DISABLE_ETWS_CMAS_TEST_BOOL =
1183             "carrier_force_disable_etws_cmas_test_bool";
1184 
1185     /**
1186      * The default flag specifying whether "Allow alerts" option will be always shown in
1187      * emergency alerts settings regardless developer options is turned on or not.
1188      *
1189      * @deprecated The allow alerts option is always shown now. No longer need a config for that.
1190      */
1191     @Deprecated
1192     public static final String KEY_ALWAYS_SHOW_EMERGENCY_ALERT_ONOFF_BOOL =
1193             "always_show_emergency_alert_onoff_bool";
1194 
1195     /**
1196      * Default mobile network MTU value, in bytes.
1197      * @hide
1198      */
1199     public static final String KEY_DEFAULT_MTU_INT = "default_mtu_int";
1200 
1201     /**
1202      * Delay in milliseconds for retrying APN after disconnect
1203      * @hide
1204      */
1205     public static final String KEY_CARRIER_DATA_CALL_APN_RETRY_AFTER_DISCONNECT_LONG =
1206             "carrier_data_call_apn_retry_after_disconnect_long";
1207 
1208     /**
1209      * Data call setup permanent failure causes by the carrier.
1210      *
1211      * @deprecated This API key was added in mistake and is not used anymore by the telephony data
1212      * frameworks.
1213      */
1214     @Deprecated
1215     public static final String KEY_CARRIER_DATA_CALL_PERMANENT_FAILURE_STRINGS =
1216             "carrier_data_call_permanent_failure_strings";
1217 
1218     /**
1219      * A string array indicating the default APN types that are metered by the carrier.
1220      *
1221      * The string in the array is the name of the APN type. For example, "default" for
1222      * {@link ApnSetting#TYPE_DEFAULT}, "mms" for {@link ApnSetting#TYPE_MMS}, etc.
1223      *
1224      * The default value is {@code {"default", "mms", "dun", "supl"}}.
1225      *
1226      * @see ApnSetting#TYPE_DEFAULT
1227      * @see ApnSetting#TYPE_MMS
1228      * @see ApnSetting#TYPE_SUPL
1229      * @see ApnSetting#TYPE_DUN
1230      * @see ApnSetting#TYPE_HIPRI
1231      * @see ApnSetting#TYPE_FOTA
1232      * @see ApnSetting#TYPE_IMS
1233      * @see ApnSetting#TYPE_CBS
1234      * @see ApnSetting#TYPE_IA
1235      * @see ApnSetting#TYPE_EMERGENCY
1236      * @see ApnSetting#TYPE_MCX
1237      * @see ApnSetting#TYPE_XCAP
1238      * @see ApnSetting#TYPE_BIP
1239      * @see ApnSetting#TYPE_VSIM
1240      * @see ApnSetting#TYPE_ENTERPRISE
1241      */
1242     public static final String KEY_CARRIER_METERED_APN_TYPES_STRINGS =
1243             "carrier_metered_apn_types_strings";
1244 
1245     /**
1246      * A string array indicating the default APN types that are roaming-metered by the carrier.
1247      *
1248      * The string in the array is the name of the APN type. For example, "default" for
1249      * {@link ApnSetting#TYPE_DEFAULT}, "mms" for {@link ApnSetting#TYPE_MMS}, etc.
1250      *
1251      * The default value is {@code {"default", "mms", "dun", "supl"}}.
1252      *
1253      * @see ApnSetting#TYPE_DEFAULT
1254      * @see ApnSetting#TYPE_MMS
1255      * @see ApnSetting#TYPE_SUPL
1256      * @see ApnSetting#TYPE_DUN
1257      * @see ApnSetting#TYPE_HIPRI
1258      * @see ApnSetting#TYPE_FOTA
1259      * @see ApnSetting#TYPE_IMS
1260      * @see ApnSetting#TYPE_CBS
1261      * @see ApnSetting#TYPE_IA
1262      * @see ApnSetting#TYPE_EMERGENCY
1263      * @see ApnSetting#TYPE_MCX
1264      * @see ApnSetting#TYPE_XCAP
1265      * @see ApnSetting#TYPE_BIP
1266      * @see ApnSetting#TYPE_VSIM
1267      * @see ApnSetting#TYPE_ENTERPRISE
1268      */
1269     public static final String KEY_CARRIER_METERED_ROAMING_APN_TYPES_STRINGS =
1270             "carrier_metered_roaming_apn_types_strings";
1271 
1272     /**
1273      * CDMA carrier ERI (Enhanced Roaming Indicator) file name
1274      * @deprecated Legacy CDMA is unsupported.
1275      * @hide
1276      */
1277     @Deprecated
1278     public static final String KEY_CARRIER_ERI_FILE_NAME_STRING = "carrier_eri_file_name_string";
1279 
1280     /* The following 3 fields are related to carrier visual voicemail. */
1281 
1282     /**
1283      * The carrier number mobile outgoing (MO) sms messages are sent to.
1284      */
1285     public static final String KEY_VVM_DESTINATION_NUMBER_STRING = "vvm_destination_number_string";
1286 
1287     /**
1288      * The port through which the mobile outgoing (MO) sms messages are sent through.
1289      */
1290     public static final String KEY_VVM_PORT_NUMBER_INT = "vvm_port_number_int";
1291 
1292     /**
1293      * The type of visual voicemail protocol the carrier adheres to. See {@link TelephonyManager}
1294      * for possible values. For example {@link TelephonyManager#VVM_TYPE_OMTP}.
1295      */
1296     public static final String KEY_VVM_TYPE_STRING = "vvm_type_string";
1297 
1298     /**
1299      * Whether cellular data is required to access visual voicemail.
1300      */
1301     public static final String KEY_VVM_CELLULAR_DATA_REQUIRED_BOOL =
1302             "vvm_cellular_data_required_bool";
1303 
1304     /**
1305      * The default OMTP visual voicemail client prefix to use. Defaulted to "//VVM"
1306      */
1307     public static final String KEY_VVM_CLIENT_PREFIX_STRING = "vvm_client_prefix_string";
1308 
1309     /**
1310      * Whether to use SSL to connect to the visual voicemail IMAP server. Defaulted to false.
1311      */
1312     public static final String KEY_VVM_SSL_ENABLED_BOOL = "vvm_ssl_enabled_bool";
1313 
1314     /**
1315      * A set of capabilities that should not be used even if it is reported by the visual voicemail
1316      * IMAP CAPABILITY command.
1317      */
1318     public static final String KEY_VVM_DISABLED_CAPABILITIES_STRING_ARRAY =
1319             "vvm_disabled_capabilities_string_array";
1320 
1321     /**
1322      * Whether legacy mode should be used when the visual voicemail client is disabled.
1323      *
1324      * <p>Legacy mode is a mode that on the carrier side visual voicemail is still activated, but on
1325      * the client side all network operations are disabled. SMSs are still monitored so a new
1326      * message SYNC SMS will be translated to show a message waiting indicator, like traditional
1327      * voicemails.
1328      *
1329      * <p>This is for carriers that does not support VVM deactivation so voicemail can continue to
1330      * function without the data cost.
1331      */
1332     public static final String KEY_VVM_LEGACY_MODE_ENABLED_BOOL = "vvm_legacy_mode_enabled_bool";
1333 
1334     /**
1335      * Whether to prefetch audio data on new voicemail arrival, defaulted to true.
1336      */
1337     public static final String KEY_VVM_PREFETCH_BOOL = "vvm_prefetch_bool";
1338 
1339     /**
1340      * The package name of the carrier's visual voicemail app to ensure that dialer visual voicemail
1341      * and carrier visual voicemail are not active at the same time.
1342      *
1343      * @deprecated use {@link #KEY_CARRIER_VVM_PACKAGE_NAME_STRING_ARRAY}.
1344      */
1345     @Deprecated
1346     public static final String KEY_CARRIER_VVM_PACKAGE_NAME_STRING =
1347             "carrier_vvm_package_name_string";
1348 
1349     /**
1350      * A list of the carrier's visual voicemail app package names to ensure that dialer visual
1351      * voicemail and carrier visual voicemail are not active at the same time.
1352      */
1353     public static final String KEY_CARRIER_VVM_PACKAGE_NAME_STRING_ARRAY =
1354             "carrier_vvm_package_name_string_array";
1355 
1356     /**
1357      * Flag specifying whether ICCID is showed in SIM Status screen, default to false.
1358      */
1359     public static final String KEY_SHOW_ICCID_IN_SIM_STATUS_BOOL = "show_iccid_in_sim_status_bool";
1360 
1361     /**
1362      * Flag specifying whether the {@link android.telephony.SignalStrength} is shown in the SIM
1363      * Status screen. The default value is true.
1364      */
1365     public static final String KEY_SHOW_SIGNAL_STRENGTH_IN_SIM_STATUS_BOOL =
1366             "show_signal_strength_in_sim_status_bool";
1367 
1368     /**
1369      * Flag specifying if we should interpret all signal strength as one bar higher
1370      * This is a replacement for the former resource config_inflateSignalStrength
1371      * The default value is false.
1372      * @hide
1373      */
1374     public static final String KEY_INFLATE_SIGNAL_STRENGTH_BOOL =
1375             "inflate_signal_strength_bool";
1376 
1377     /**
1378      * Flag specifying whether an additional (client initiated) intent needs to be sent on System
1379      * update
1380      */
1381     public static final String KEY_CI_ACTION_ON_SYS_UPDATE_BOOL = "ci_action_on_sys_update_bool";
1382 
1383     /**
1384      * Intent to be sent for the additional action on System update
1385      */
1386     public static final String KEY_CI_ACTION_ON_SYS_UPDATE_INTENT_STRING =
1387             "ci_action_on_sys_update_intent_string";
1388 
1389     /**
1390      * Extra to be included in the intent sent for additional action on System update
1391      */
1392     public static final String KEY_CI_ACTION_ON_SYS_UPDATE_EXTRA_STRING =
1393             "ci_action_on_sys_update_extra_string";
1394 
1395     /**
1396      * Value of extra included in intent sent for additional action on System update
1397      */
1398     public static final String KEY_CI_ACTION_ON_SYS_UPDATE_EXTRA_VAL_STRING =
1399             "ci_action_on_sys_update_extra_val_string";
1400 
1401     /**
1402      * Specifies the amount of gap to be added in millis between postdial DTMF tones. When a
1403      * non-zero value is specified, the UE shall wait for the specified amount of time before it
1404      * sends out successive DTMF tones on the network.
1405      */
1406     public static final String KEY_GSM_DTMF_TONE_DELAY_INT = "gsm_dtmf_tone_delay_int";
1407 
1408     /**
1409      * Specifies the amount of gap to be added in millis between DTMF tones. When a non-zero value
1410      * is specified, the UE shall wait for the specified amount of time before it sends out
1411      * successive DTMF tones on the network.
1412      */
1413     public static final String KEY_IMS_DTMF_TONE_DELAY_INT = "ims_dtmf_tone_delay_int";
1414 
1415     /**
1416      * Specifies the amount of gap to be added in millis between postdial DTMF tones. When a
1417      * non-zero value is specified, the UE shall wait for the specified amount of time before it
1418      * sends out successive DTMF tones on the network.
1419      * @deprecated Legacy CDMA is unsupported.
1420      */
1421     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
1422     @Deprecated
1423     public static final String KEY_CDMA_DTMF_TONE_DELAY_INT = "cdma_dtmf_tone_delay_int";
1424 
1425     /**
1426      * Some carriers will send call forwarding responses for voicemail in a format that is not 3gpp
1427      * compliant, which causes issues during parsing. This causes the
1428      * {@link com.android.internal.telephony.CallForwardInfo#number} to contain non-numerical
1429      * characters instead of a number.
1430      *
1431      * If true, we will detect the non-numerical characters and replace them with "Voicemail".
1432      * @hide
1433      */
1434     public static final String KEY_CALL_FORWARDING_MAP_NON_NUMBER_TO_VOICEMAIL_BOOL =
1435             "call_forwarding_map_non_number_to_voicemail_bool";
1436 
1437     /**
1438      * When {@code true}, the phone will always tell the IMS stack to keep RTT enabled and
1439      * determine on a per-call basis (based on extras from the dialer app) whether a call should be
1440      * an RTT call or not.
1441      *
1442      * When {@code false}, the old behavior is used, where the toggle in accessibility settings is
1443      * used to set the IMS stack's RTT enabled state.
1444      */
1445     public static final String KEY_IGNORE_RTT_MODE_SETTING_BOOL =
1446             "ignore_rtt_mode_setting_bool";
1447 
1448     /**
1449      * Determines whether adhoc conference calls are supported by a carrier. When {@code true},
1450      * adhoc conference calling is supported, {@code false otherwise}.
1451      */
1452     public static final String KEY_SUPPORT_ADHOC_CONFERENCE_CALLS_BOOL =
1453             "support_adhoc_conference_calls_bool";
1454 
1455     /**
1456      * Determines whether conference participants can be added to existing call to form an adhoc
1457      * conference call (in contrast to merging calls to form a conference). When {@code true},
1458      * adding conference participants to existing call is supported, {@code false otherwise}.
1459      */
1460     public static final String KEY_SUPPORT_ADD_CONFERENCE_PARTICIPANTS_BOOL =
1461             "support_add_conference_participants_bool";
1462 
1463     /**
1464      * Determines whether conference calls are supported by a carrier. When {@code true},
1465      * conference calling is supported, {@code false otherwise}.
1466      */
1467     public static final String KEY_SUPPORT_CONFERENCE_CALL_BOOL = "support_conference_call_bool";
1468 
1469     /**
1470      * Determines whether a maximum size limit for IMS conference calls is enforced on the device.
1471      * When {@code true}, IMS conference calls will be limited to at most
1472      * {@link #KEY_IMS_CONFERENCE_SIZE_LIMIT_INT} participants. When {@code false}, no attempt is
1473      * made to limit the number of participants in a conference (the carrier will raise an error
1474      * when an attempt is made to merge too many participants into a conference).
1475      * <p>
1476      * Note: The maximum size of a conference can ONLY be supported where
1477      * {@link #KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_BOOL} is {@code true} since the platform
1478      * needs conference event package data to accurately know the number of participants in the
1479      * conference.
1480      */
1481     public static final String KEY_IS_IMS_CONFERENCE_SIZE_ENFORCED_BOOL =
1482             "is_ims_conference_size_enforced_bool";
1483 
1484     /**
1485      * Determines the maximum number of participants the carrier supports for a conference call.
1486      * This number is exclusive of the current device. A conference between 3 devices, for example,
1487      * would have a size limit of 2 participants.
1488      * Enforced when {@link #KEY_IS_IMS_CONFERENCE_SIZE_ENFORCED_BOOL} is {@code true}.
1489      */
1490     public static final String KEY_IMS_CONFERENCE_SIZE_LIMIT_INT = "ims_conference_size_limit_int";
1491 
1492     /**
1493      * Determines whether manage IMS conference calls is supported by a carrier. When {@code true},
1494      * manage IMS conference call is supported, {@code false otherwise}.
1495      * @hide
1496      */
1497     public static final String KEY_SUPPORT_MANAGE_IMS_CONFERENCE_CALL_BOOL =
1498             "support_manage_ims_conference_call_bool";
1499 
1500     /**
1501      * Determines whether the IMS conference merge process supports and returns its participants
1502      * data. When {@code true}, on merge complete, conference call would have a list of its
1503      * participants returned in XML format, {@code false otherwise}.
1504      */
1505     public static final String KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_BOOL =
1506             "support_ims_conference_event_package_bool";
1507 
1508     /**
1509      * Determines whether processing of conference event package data received on a device other
1510      * than the conference host is supported.
1511      * <p>
1512      * When a device A merges calls B and C into a conference it is considered the conference host
1513      * and B and C are considered the conference peers.
1514      * <p>
1515      * When {@code true}, the conference peer will display the conference state if it receives
1516      * conference event package data from the network. When {@code false}, the conference peer will
1517      * ignore conference event package data received from the network.
1518      * @hide
1519      */
1520     public static final String KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_ON_PEER_BOOL =
1521             "support_ims_conference_event_package_on_peer_bool";
1522 
1523     /**
1524      * Indicates whether the carrier supports the use of RFC8285 compliant RTP header extensions for
1525      * the purpose of device to device communication while in a call.
1526      * <p>
1527      * See also {@link #KEY_SUPPORTS_SDP_NEGOTIATION_OF_D2D_RTP_HEADER_EXTENSIONS_BOOL}.
1528      */
1529     public static final String KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_RTP_BOOL =
1530             "supports_device_to_device_communication_using_rtp_bool";
1531 
1532     /**
1533      * Indicates whether the carrier supports the negotiations of RFC8285 compliant RTP header
1534      * extensions supported on a call during the Session Description Protocol (SDP). This option
1535      * is only used when {@link #KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_RTP_BOOL} is
1536      * {@code true}.
1537      * <p>
1538      * When {@code true}, the RTP header extensions the platform uses for device to device
1539      * communication will be offered to the remote end during the SDP negotiation process.
1540      * When {@code false}, the RTP header extensions will not be negotiated during the SDP
1541      * negotiation process and the platform will send RTP header extensions without prior
1542      * negotiation if {@link #KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_RTP_BOOL} is
1543      * {@code true}.
1544      */
1545     public static final String KEY_SUPPORTS_SDP_NEGOTIATION_OF_D2D_RTP_HEADER_EXTENSIONS_BOOL =
1546             "supports_sdp_negotiation_of_d2d_rtp_header_extensions_bool";
1547 
1548     /**
1549      * Indicates whether the carrier supports the use of DTMF digits A-D for the purpose of device
1550      * to device communication while in a call.
1551      */
1552     public static final String KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_DTMF_BOOL =
1553             "supports_device_to_device_communication_using_dtmf_bool";
1554 
1555     /**
1556      * Determines whether High Definition audio property is displayed in the dialer UI.
1557      * If {@code false}, remove the HD audio property from the connection so that HD audio related
1558      * UI is not displayed. If {@code true}, keep HD audio property as it is configured.
1559      */
1560     public static final String KEY_DISPLAY_HD_AUDIO_PROPERTY_BOOL =
1561             "display_hd_audio_property_bool";
1562 
1563     /**
1564      * Determines whether IMS conference calls are supported by a carrier. When {@code true},
1565      * IMS conference calling is supported, {@code false} otherwise.
1566      * @hide
1567      */
1568     public static final String KEY_SUPPORT_IMS_CONFERENCE_CALL_BOOL =
1569             "support_ims_conference_call_bool";
1570 
1571     /**
1572      * Determines whether the device will locally disconnect an IMS conference when the participant
1573      * count drops to zero. When {@code true}, it is assumed the carrier does NOT disconnect a
1574      * conference when the participant count drops to zero and that the device must do this by
1575      * disconnecting the conference locally. When {@code false}, it is assumed that the carrier
1576      * is responsible for disconnecting the conference when there are no longer any participants
1577      * present.
1578      * <p>
1579      * Note: both {@link #KEY_SUPPORT_IMS_CONFERENCE_CALL_BOOL} and
1580      * {@link #KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_BOOL} must be true for this configuration to
1581      * have any effect.
1582      * <p>
1583      * Defaults to {@code false}, meaning the carrier network is responsible for disconnecting an
1584      * empty IMS conference.
1585      * @hide
1586      */
1587     public static final String KEY_LOCAL_DISCONNECT_EMPTY_IMS_CONFERENCE_BOOL =
1588             "local_disconnect_empty_ims_conference_bool";
1589 
1590     /**
1591      * Determines whether video conference calls are supported by a carrier. When {@code true},
1592      * video calls can be merged into conference calls, {@code false} otherwise.
1593      * <p>
1594      * Note: even if video conference calls are not supported, audio calls may be merged into a
1595      * conference if {@link #KEY_SUPPORT_CONFERENCE_CALL_BOOL} is {@code true}.
1596      * @hide
1597      */
1598     public static final String KEY_SUPPORT_VIDEO_CONFERENCE_CALL_BOOL =
1599             "support_video_conference_call_bool";
1600 
1601     /**
1602      * Determine whether user can toggle Enhanced 4G LTE Mode in Settings.
1603      */
1604     public static final String KEY_EDITABLE_ENHANCED_4G_LTE_BOOL = "editable_enhanced_4g_lte_bool";
1605 
1606     /**
1607      * Determines whether the Enhanced 4G LTE toggle will be shown in the settings. When this
1608      * option is {@code true}, the toggle will be hidden regardless of whether the device and
1609      * carrier supports 4G LTE or not.
1610      */
1611     public static final String KEY_HIDE_ENHANCED_4G_LTE_BOOL = "hide_enhanced_4g_lte_bool";
1612 
1613     /**
1614      * Sets the default state for the "Enhanced 4G LTE" or "Advanced Calling" mode toggle set by the
1615      * user. When this is {@code true}, this mode by default is on, otherwise if {@code false},
1616      * this mode by default is off.
1617      */
1618     public static final String KEY_ENHANCED_4G_LTE_ON_BY_DEFAULT_BOOL =
1619             "enhanced_4g_lte_on_by_default_bool";
1620 
1621     /**
1622      * Determine whether IMS apn can be shown.
1623      */
1624     public static final String KEY_HIDE_IMS_APN_BOOL = "hide_ims_apn_bool";
1625 
1626     /**
1627      * Determine whether preferred network type can be shown.
1628      */
1629     public static final String KEY_HIDE_PREFERRED_NETWORK_TYPE_BOOL =
1630             "hide_preferred_network_type_bool";
1631 
1632     /**
1633      * String array for package names that need to be enabled for this carrier.
1634      * If user has explicitly disabled some packages in the list, won't re-enable.
1635      * Other carrier specific apps which are not in this list may be disabled for current carrier,
1636      * and only be re-enabled when this config for another carrier includes it.
1637      *
1638      * @hide
1639      */
1640     public static final String KEY_ENABLE_APPS_STRING_ARRAY = "enable_apps_string_array";
1641 
1642     /**
1643      * Determine whether user can switch Wi-Fi preferred or Cellular preferred
1644      * in calling preference.
1645      * Some operators support Wi-Fi Calling only, not VoLTE.
1646      * They don't need "Cellular preferred" option.
1647      * In this case, set uneditable attribute for preferred preference.
1648      */
1649     public static final String KEY_EDITABLE_WFC_MODE_BOOL = "editable_wfc_mode_bool";
1650 
1651     /**
1652      * Flag to indicate if Wi-Fi needs to be disabled in ECBM.
1653      */
1654     public static final String KEY_CONFIG_WIFI_DISABLE_IN_ECBM = "config_wifi_disable_in_ecbm";
1655 
1656     /**
1657      * List operator-specific error codes and indices of corresponding error strings in
1658      * wfcOperatorErrorAlertMessages and wfcOperatorErrorNotificationMessages.
1659      *
1660      * Example: "REG09|0" specifies error code "REG09" and index "0". This index will be
1661      * used to find alert and notification messages in wfcOperatorErrorAlertMessages and
1662      * wfcOperatorErrorNotificationMessages.
1663      *
1664      * @hide
1665      */
1666     public static final String KEY_WFC_OPERATOR_ERROR_CODES_STRING_ARRAY =
1667             "wfc_operator_error_codes_string_array";
1668 
1669     /**
1670      * Indexes of SPN format strings in wfcSpnFormats.
1671      *
1672      * <p>Available options are:
1673      * <ul>
1674      * <li>  0: %s</li>
1675      * <li>  1: %s Wi-Fi Calling</li>
1676      * <li>  2: WLAN Call</li>
1677      * <li>  3: %s WLAN Call</li>
1678      * <li>  4: %s Wi-Fi</li>
1679      * <li>  5: WiFi Calling | %s</li>
1680      * <li>  6: %s VoWifi</li>
1681      * <li>  7: Wi-Fi Calling</li>
1682      * <li>  8: Wi-Fi</li>
1683      * <li>  9: WiFi Calling</li>
1684      * <li> 10: VoWifi</li>
1685      * <li> 11: %s WiFi Calling</li>
1686      * <li> 12: WiFi Call</li>
1687      * @hide
1688      */
1689     public static final String KEY_WFC_SPN_FORMAT_IDX_INT = "wfc_spn_format_idx_int";
1690 
1691     /**
1692      * Indexes of data SPN format strings in wfcSpnFormats.
1693      *
1694      * @see KEY_WFC_SPN_FORMAT_IDX_INT for available options.
1695      * @hide
1696      */
1697     public static final String KEY_WFC_DATA_SPN_FORMAT_IDX_INT = "wfc_data_spn_format_idx_int";
1698 
1699     /**
1700      * Indexes of SPN format strings in wfcSpnFormats used during flight mode.
1701      *
1702      * Set to -1 to use the value from KEY_WFC_SPN_FORMAT_IDX_INT also in this case.
1703      * @see KEY_WFC_SPN_FORMAT_IDX_INT for other available options.
1704      * @hide
1705      */
1706     public static final String KEY_WFC_FLIGHT_MODE_SPN_FORMAT_IDX_INT =
1707             "wfc_flight_mode_spn_format_idx_int";
1708 
1709     /**
1710      * Use root locale when reading wfcSpnFormats.
1711      *
1712      * If true, then the root locale will always be used when reading wfcSpnFormats. This means the
1713      * non localized version of wfcSpnFormats will be used.
1714      * @hide
1715      */
1716     public static final String KEY_WFC_SPN_USE_ROOT_LOCALE = "wfc_spn_use_root_locale";
1717 
1718     /**
1719      * The Component Name of the activity that can setup the emergency address for WiFi Calling
1720      * as per carrier requirement.
1721      */
1722      public static final String KEY_WFC_EMERGENCY_ADDRESS_CARRIER_APP_STRING =
1723             "wfc_emergency_address_carrier_app_string";
1724 
1725     /**
1726      * Unconditionally override the carrier name string using #KEY_CARRIER_NAME_STRING.
1727      *
1728      * If true, then the carrier name string will be #KEY_CARRIER_NAME_STRING, unconditionally.
1729      *
1730      * <p>If false, then the override will be performed conditionally and the
1731      * #KEY_CARRIER_NAME_STRING will have the lowest-precedence; it will only be used in the event
1732      * that the name string would otherwise be empty, allowing it to serve as a last-resort. If
1733      * used, this value functions in place of the SPN on any/all ICC records for the corresponding
1734      * subscription.
1735      */
1736     public static final String KEY_CARRIER_NAME_OVERRIDE_BOOL = "carrier_name_override_bool";
1737 
1738     /**
1739      * String to identify carrier name in CarrierConfig app. This string overrides SPN if
1740      * #KEY_CARRIER_NAME_OVERRIDE_BOOL is true; otherwise, it will be used if its value is provided
1741      * and SPN is unavailable
1742      */
1743     public static final String KEY_CARRIER_NAME_STRING = "carrier_name_string";
1744 
1745     /**
1746      * To override wifi calling's carrier name string using ef_pnn from sim card when SPN in empty.
1747      *
1748      * @hide
1749      */
1750     public static final String KEY_WFC_CARRIER_NAME_OVERRIDE_BY_PNN_BOOL =
1751             "wfc_carrier_name_override_by_pnn_bool";
1752 
1753     /**
1754      * Specifies SPN format of displaying carrier name only.
1755      *
1756      */
1757     public static final int CROSS_SIM_SPN_FORMAT_CARRIER_NAME_ONLY = 0;
1758 
1759     /**
1760      * Specifies SPN format of displaying carrier name along with "Cross-SIM calling".
1761      */
1762     public static final int CROSS_SIM_SPN_FORMAT_CARRIER_NAME_WITH_BRANDING = 1;
1763 
1764     /**
1765      * Indexes of SPN format strings in crossSimSpnFormats.
1766      *
1767      * <p>Available options are:
1768      * <ul>
1769      * <li>  {@link #CROSS_SIM_SPN_FORMAT_CARRIER_NAME_ONLY}: %s</li>
1770      * <li>  {@link #CROSS_SIM_SPN_FORMAT_CARRIER_NAME_WITH_BRANDING}: %s Cross-SIM Calling</li>
1771      * </ul>
1772      * %s will be filled with carrier name
1773      */
1774     public static final String KEY_CROSS_SIM_SPN_FORMAT_INT = "cross_sim_spn_format_int";
1775 
1776     /**
1777      * Override the SPN Display Condition 2 integer bits (lsb). B2, B1 is the last two bits of the
1778      * spn display condition coding.
1779      *
1780      * The default value -1 mean this field is not set.
1781      *
1782      * B1 = 0: display of registered PLMN name not required when registered PLMN is either HPLMN
1783      * or a PLMN in the service provider PLMN list (see EF_SPDI).
1784      * B1 = 1: display of registered PLMN name required when registered PLMN is either HPLMN or a
1785      * PLMN in the service provider PLMN list(see EF_SPDI).
1786      * B2 = 0: display of the service provider name is required when registered PLMN is neither
1787      * HPLMN nor a PLMN in the service provider PLMN list(see EF_SPDI).
1788      * B2 = 1: display of the service provider name is not required when registered PLMN is neither
1789      * HPLMN nor a PLMN in the service provider PLMN list(see EF_SPDI).
1790      *
1791      * Reference: 3GPP TS 31.102 v15.2.0 Section 4.2.12 EF_SPN.
1792      * @hide
1793      */
1794     public static final String KEY_SPN_DISPLAY_CONDITION_OVERRIDE_INT =
1795             "spn_display_condition_override_int";
1796 
1797     /**
1798      * Override the SPDI - an array of PLMN(MCC + MNC) strings.
1799      *
1800      * Reference: 3GPP TS 31.102 v15.2.0 Section 4.2.66 EF_SPDI.
1801      * @hide
1802      */
1803     public static final String KEY_SPDI_OVERRIDE_STRING_ARRAY = "spdi_override_string_array";
1804 
1805     /**
1806      * Override the EHPLMNs - an array of PLMN(MCC + MNC) strings.
1807      *
1808      * To allow provision for multiple HPLMN codes, PLMN codes that are present within this list
1809      * shall replace the HPLMN code derived from the IMSI for PLMN selection purposes.
1810      *
1811      * Reference: 3GPP TS 31.102 v15.2.0 Section 4.2.84 EF_EHPLMN
1812      * Reference: 3GPP TS 23.122 v15.6.0 Section 1.2 Equivalent HPLMN list
1813      * @hide
1814      */
1815     public static final String KEY_EHPLMN_OVERRIDE_STRING_ARRAY = "ehplmn_override_string_array";
1816 
1817     /**
1818      * Override the PNN - a string array of comma-separated alpha long and short names:
1819      * "alpha_long1,alpha_short1".
1820      *
1821      * Reference: 3GPP TS 31.102 v15.2.0 Section 4.2.58 EF_PNN.
1822      * @hide
1823      */
1824     public static final String KEY_PNN_OVERRIDE_STRING_ARRAY = "pnn_override_string_array";
1825 
1826     /**
1827      * A string array of OPL records, each with comma-delimited data fields as follows:
1828      * "plmn1,lactac_start,lactac_end,index".
1829      *
1830      * Reference: 3GPP TS 31.102 v15.2.0 Section 4.2.59 EF_OPL.
1831      * @hide
1832      */
1833     public static final String KEY_OPL_OVERRIDE_STRING_ARRAY = "opl_override_opl_string_array";
1834 
1835     /**
1836      * Allow ERI rules to select a carrier name display string when using 3gpp2 access technologies.
1837      * If this bit is not set, the carrier name display string will be selected from the carrier
1838      * display name resolver which doesn't apply the ERI rules.
1839      *
1840      * @deprecated Legacy CDMA is unsupported.
1841      * @hide
1842      */
1843     @Deprecated
1844     public static final String KEY_ALLOW_ERI_BOOL = "allow_cdma_eri_bool";
1845 
1846     /**
1847      * If true, use the carrier display name(SPN and PLMN) from the carrier display name resolver.
1848      *
1849      * @hide
1850      */
1851     public static final String KEY_ENABLE_CARRIER_DISPLAY_NAME_RESOLVER_BOOL =
1852             "enable_carrier_display_name_resolver_bool";
1853 
1854     /**
1855      * String to override sim country iso.
1856      * Sim country iso is based on sim MCC which is coarse and doesn't work with dual IMSI SIM where
1857      * a SIM can have multiple MCC from different countries.
1858      * Instead, each sim carrier should have a single country code, apply per carrier based iso
1859      * code as an override. The overridden value can be read from
1860      * {@link TelephonyManager#getSimCountryIso()} and {@link SubscriptionInfo#getCountryIso()}
1861      */
1862     public static final String KEY_SIM_COUNTRY_ISO_OVERRIDE_STRING =
1863             "sim_country_iso_override_string";
1864 
1865     /**
1866      * The Component Name of a carrier-provided CallScreeningService implementation. Telecom will
1867      * bind to {@link android.telecom.CallScreeningService} for ALL incoming calls and provide
1868      * the carrier
1869      * CallScreeningService with the opportunity to allow or block calls.
1870      * <p>
1871      * The String includes the package name/the class name.
1872      * Example:
1873      * <item>com.android.carrier/com.android.carrier.callscreeningserviceimpl</item>
1874      * <p>
1875      * Using {@link ComponentName#flattenToString()} to convert a ComponentName object to String.
1876      * Using {@link ComponentName#unflattenFromString(String)} to convert a String object to a
1877      * ComponentName.
1878      */
1879     public static final String KEY_CARRIER_CALL_SCREENING_APP_STRING = "call_screening_app";
1880 
1881     /**
1882      * Override the registered PLMN name using #KEY_CDMA_HOME_REGISTERED_PLMN_NAME_STRING.
1883      *
1884      * If true, then the registered PLMN name (only for CDMA/CDMA-LTE and only when not roaming)
1885      * will be #KEY_CDMA_HOME_REGISTERED_PLMN_NAME_STRING. If false, or if phone type is not
1886      * CDMA/CDMA-LTE or if roaming, then #KEY_CDMA_HOME_REGISTERED_PLMN_NAME_STRING will be ignored.
1887      * @deprecated Legacy CDMA is unsupported.
1888      * @hide
1889      */
1890     @Deprecated
1891     public static final String KEY_CDMA_HOME_REGISTERED_PLMN_NAME_OVERRIDE_BOOL =
1892             "cdma_home_registered_plmn_name_override_bool";
1893 
1894     /**
1895      * String to identify registered PLMN name in CarrierConfig app. This string overrides
1896      * registered PLMN name if #KEY_CDMA_HOME_REGISTERED_PLMN_NAME_OVERRIDE_BOOL is true, phone type
1897      * is CDMA/CDMA-LTE and device is not in roaming state; otherwise, it will be ignored.
1898      * @deprecated Legacy CDMA is unsupported.
1899      * @hide
1900      */
1901     @Deprecated
1902     public static final String KEY_CDMA_HOME_REGISTERED_PLMN_NAME_STRING =
1903             "cdma_home_registered_plmn_name_string";
1904 
1905     /**
1906      * If this is true, the SIM card (through Customer Service Profile EF file) will be able to
1907      * prevent manual operator selection. If false, this SIM setting will be ignored and manual
1908      * operator selection will always be available. See CPHS4_2.WW6, CPHS B.4.7.1 for more
1909      * information
1910      */
1911     public static final String KEY_CSP_ENABLED_BOOL = "csp_enabled_bool";
1912 
1913     /**
1914      * Allow user to add APNs
1915      */
1916     public static final String KEY_ALLOW_ADDING_APNS_BOOL = "allow_adding_apns_bool";
1917 
1918     /**
1919      * APN types that user is not allowed to modify.
1920      */
1921     public static final String KEY_READ_ONLY_APN_TYPES_STRING_ARRAY =
1922             "read_only_apn_types_string_array";
1923 
1924     /**
1925      * APN fields that user is not allowed to modify.
1926      */
1927     public static final String KEY_READ_ONLY_APN_FIELDS_STRING_ARRAY =
1928             "read_only_apn_fields_string_array";
1929 
1930     /**
1931      * Default value of APN types field if not specified by user when adding/modifying an APN.
1932      */
1933     public static final String KEY_APN_SETTINGS_DEFAULT_APN_TYPES_STRING_ARRAY =
1934             "apn_settings_default_apn_types_string_array";
1935 
1936     /**
1937      * Configs used for APN setup.
1938      */
1939     public static final class Apn {
1940         /**
1941          * Prefix of all Apn.KEY_* constants.
1942          *
1943          * @deprecated Since KEY_PREFIX is unnecessary to public, it will modify to private
1944          * next android generation.
1945          */
1946         @Deprecated
1947         public static final String KEY_PREFIX = "apn.";
1948 
1949         /** IPv4 internet protocol */
1950         public static final String PROTOCOL_IPV4 = "IP";
1951         /** IPv6 internet protocol */
1952         public static final String PROTOCOL_IPV6 = "IPV6";
1953         /** IPv4 or IPv6 internet protocol */
1954         public static final String PROTOCOL_IPV4V6 = "IPV4V6";
1955 
1956         /**
1957          * Default value of APN protocol field if not specified by user when adding/modifying
1958          * an APN.
1959          *
1960          * Available options are: {@link #PROTOCOL_IPV4}, {@link #PROTOCOL_IPV6},
1961          * {@link #PROTOCOL_IPV4V6}
1962          */
1963         public static final String KEY_SETTINGS_DEFAULT_PROTOCOL_STRING =
1964                 KEY_PREFIX + "settings_default_protocol_string";
1965 
1966         /**
1967          * Default value of APN roaming protocol field if not specified by user when
1968          * adding/modifying an APN.
1969          *
1970          * Available options are: {@link #PROTOCOL_IPV4}, {@link #PROTOCOL_IPV6},
1971          * {@link #PROTOCOL_IPV4V6}
1972          */
1973         public static final String KEY_SETTINGS_DEFAULT_ROAMING_PROTOCOL_STRING =
1974                 KEY_PREFIX + "settings_default_roaming_protocol_string";
1975 
Apn()1976         private Apn() {}
1977 
getDefaults()1978         private static PersistableBundle getDefaults() {
1979             PersistableBundle defaults = new PersistableBundle();
1980             defaults.putString(KEY_SETTINGS_DEFAULT_PROTOCOL_STRING, "");
1981             defaults.putString(KEY_SETTINGS_DEFAULT_ROAMING_PROTOCOL_STRING, "");
1982             return defaults;
1983         }
1984     }
1985 
1986     /**
1987      * Boolean indicating if intent for emergency call state changes should be broadcast
1988      * @hide
1989      */
1990     public static final String KEY_BROADCAST_EMERGENCY_CALL_STATE_CHANGES_BOOL =
1991             "broadcast_emergency_call_state_changes_bool";
1992 
1993     /**
1994      * Indicates whether STK LAUNCH_BROWSER command is disabled.
1995      * If {@code true}, then the browser will not be launched
1996      * on UI for the LAUNCH_BROWSER STK command.
1997      * @hide
1998      */
1999     public static final String KEY_STK_DISABLE_LAUNCH_BROWSER_BOOL =
2000             "stk_disable_launch_browser_bool";
2001 
2002     /**
2003      * Boolean indicating if the helper text for STK GET INKEY/INPUT commands with the digit only
2004      * mode is displayed on the input screen.
2005      * The helper text is displayed regardless of the input mode, if {@code false}.
2006      * @hide
2007      */
2008     public static final String KEY_HIDE_DIGITS_HELPER_TEXT_ON_STK_INPUT_SCREEN_BOOL =
2009             "hide_digits_helper_text_on_stk_input_screen_bool";
2010 
2011     /**
2012      * Boolean indicating if show data RAT icon on status bar even when data is disabled.
2013      */
2014     public static final String KEY_ALWAYS_SHOW_DATA_RAT_ICON_BOOL =
2015             "always_show_data_rat_icon_bool";
2016 
2017     /**
2018      * Boolean indicating if default data account should show LTE or 4G icon.
2019      */
2020     public static final String KEY_SHOW_4G_FOR_LTE_DATA_ICON_BOOL =
2021             "show_4g_for_lte_data_icon_bool";
2022 
2023     /**
2024      * Boolean indicating if default data account should show 4G LTE or 4G icon.
2025      * @hide
2026      */
2027     public static final String KEY_SHOW_4GLTE_FOR_LTE_DATA_ICON_BOOL =
2028             "show_4glte_for_lte_data_icon_bool";
2029 
2030     /**
2031      * Boolean indicating if default data account should show 4G icon when in 3G.
2032      */
2033     public static final String KEY_SHOW_4G_FOR_3G_DATA_ICON_BOOL =
2034             "show_4g_for_3g_data_icon_bool";
2035 
2036     /**
2037      * Boolean indicating if LTE+ icon should be shown if available.
2038      */
2039     public static final String KEY_HIDE_LTE_PLUS_DATA_ICON_BOOL = "hide_lte_plus_data_icon_bool";
2040 
2041     /**
2042      * Boolean indicting if the 5G slice icon should be shown if available.
2043      * @hide
2044      */
2045     public static final String KEY_SHOW_5G_SLICE_ICON_BOOL = "show_5g_slice_icon_bool";
2046 
2047     /**
2048      * The combined channel bandwidth threshold (non-inclusive) in KHz required to display the
2049      * LTE+ data icon. It is 20000 by default, meaning the LTE+ icon will be shown if the device is
2050      * using carrier aggregation and the combined channel bandwidth is strictly greater than 20 MHz.
2051      * @hide
2052      */
2053     public static final String KEY_LTE_PLUS_THRESHOLD_BANDWIDTH_KHZ_INT =
2054             "lte_plus_threshold_bandwidth_khz_int";
2055 
2056     /**
2057      * The combined channel bandwidth threshold (inclusive) in KHz required to display the
2058      * NR advanced (i.e. 5G+) data icon. It is 0 by default, meaning minimum bandwidth check is
2059      * not enabled. Other factors like bands or frequency can also determine whether the NR
2060      * advanced data icon is shown or not.
2061      *
2062      * @see #KEY_ADDITIONAL_NR_ADVANCED_BANDS_INT_ARRAY
2063      * @see #KEY_NR_ADVANCED_CAPABLE_PCO_ID_INT
2064      *
2065      * @hide
2066      */
2067     public static final String KEY_NR_ADVANCED_THRESHOLD_BANDWIDTH_KHZ_INT =
2068             "nr_advanced_threshold_bandwidth_khz_int";
2069 
2070     /**
2071      * Indicating whether to include LTE cell bandwidths when determining whether the aggregated
2072      * cell bandwidth meets the required threshold for NR advanced.
2073      *
2074      * @see TelephonyDisplayInfo#OVERRIDE_NETWORK_TYPE_NR_ADVANCED
2075      */
2076     public static final String KEY_INCLUDE_LTE_FOR_NR_ADVANCED_THRESHOLD_BANDWIDTH_BOOL =
2077             "include_lte_for_nr_advanced_threshold_bandwidth_bool";
2078 
2079     /**
2080      * Indicating whether to ratchet the aggregated cell bandwidths on receiving new values when
2081      * the device is in RRC IDLE mode.
2082      * The aggregated cell bandwidths are used for determining NR advanced state.
2083      *
2084      * If this is {@code true}, we will only update the aggregate cell bandwidths if the new
2085      * aggregate is higher than the current aggregate and the anchor NR cell is the same.
2086      * If this is {@code false}, we will always update the aggregate cell bandwidths when receiving
2087      * new values.
2088      */
2089     public static final String KEY_RATCHET_NR_ADVANCED_BANDWIDTH_IF_RRC_IDLE_BOOL =
2090             "ratchet_nr_advanced_bandwidth_if_rrc_idle_bool";
2091 
2092     /**
2093      * Boolean indicating if operator name should be shown in the status bar
2094      * @hide
2095      */
2096     public static final String KEY_SHOW_OPERATOR_NAME_IN_STATUSBAR_BOOL =
2097             "show_operator_name_in_statusbar_bool";
2098 
2099     /**
2100      * The string is used to filter redundant string from PLMN Network Name that's supplied by
2101      * specific carrier.
2102      *
2103      * @hide
2104      */
2105     public static final String KEY_OPERATOR_NAME_FILTER_PATTERN_STRING =
2106             "operator_name_filter_pattern_string";
2107 
2108     /**
2109      * The string is used to compare with operator name.
2110      * If it matches the pattern then show specific data icon.
2111      * @hide
2112      */
2113     public static final String KEY_SHOW_CARRIER_DATA_ICON_PATTERN_STRING =
2114             "show_carrier_data_icon_pattern_string";
2115 
2116     /**
2117      * Boolean to decide whether to show precise call failed cause to user
2118      * @hide
2119      */
2120     public static final String KEY_SHOW_PRECISE_FAILED_CAUSE_BOOL =
2121             "show_precise_failed_cause_bool";
2122 
2123     /**
2124      * A list of carrier nr availability is used to determine whether the carrier enable the
2125      * non-standalone (NSA) mode of 5G NR, standalone (SA) mode of 5G NR
2126      *
2127      * <p> The value of list is
2128      * {@link #CARRIER_NR_AVAILABILITY_NSA}, or {@link #CARRIER_NR_AVAILABILITY_SA}.
2129      *
2130      * <p> For example, if both NSA and SA are used, the list value is {
2131      * {@link #CARRIER_NR_AVAILABILITY_NSA},{@link #CARRIER_NR_AVAILABILITY_SA}}.
2132      * If the carrier doesn't support 5G NR, the value is the empty array.
2133      * If the key is invalid or not configured, the default value {
2134      * {@link #CARRIER_NR_AVAILABILITY_NSA},{@link #CARRIER_NR_AVAILABILITY_SA}} will apply.
2135      */
2136     public static final String KEY_CARRIER_NR_AVAILABILITIES_INT_ARRAY =
2137             "carrier_nr_availabilities_int_array";
2138 
2139     /**
2140      * Boolean to decide whether LTE is enabled.
2141      */
2142     public static final String KEY_LTE_ENABLED_BOOL = "lte_enabled_bool";
2143 
2144     /**
2145      * Boolean to decide whether TD-SCDMA is supported.
2146      */
2147     public static final String KEY_SUPPORT_TDSCDMA_BOOL = "support_tdscdma_bool";
2148 
2149     /**
2150      * A list of mcc/mnc that support TD-SCDMA for device when connect to the roaming network.
2151      */
2152     public static final String KEY_SUPPORT_TDSCDMA_ROAMING_NETWORKS_STRING_ARRAY =
2153             "support_tdscdma_roaming_networks_string_array";
2154 
2155     /**
2156      * Boolean to decide whether world mode is enabled.
2157      */
2158     public static final String KEY_WORLD_MODE_ENABLED_BOOL = "world_mode_enabled_bool";
2159 
2160     /**
2161      * Flatten {@link android.content.ComponentName} of the carrier's settings activity.
2162      */
2163     public static final String KEY_CARRIER_SETTINGS_ACTIVITY_COMPONENT_NAME_STRING =
2164             "carrier_settings_activity_component_name_string";
2165 
2166     // These variables are used by the MMS service and exposed through another API,
2167     // SmsManager. The variable names and string values are copied from there.
2168     public static final String KEY_MMS_ALIAS_ENABLED_BOOL = "aliasEnabled";
2169     public static final String KEY_MMS_ALLOW_ATTACH_AUDIO_BOOL = "allowAttachAudio";
2170     public static final String KEY_MMS_APPEND_TRANSACTION_ID_BOOL = "enabledTransID";
2171     public static final String KEY_MMS_GROUP_MMS_ENABLED_BOOL = "enableGroupMms";
2172     public static final String KEY_MMS_MMS_DELIVERY_REPORT_ENABLED_BOOL =
2173             "enableMMSDeliveryReports";
2174     public static final String KEY_MMS_MMS_ENABLED_BOOL = "enabledMMS";
2175     public static final String KEY_MMS_MMS_READ_REPORT_ENABLED_BOOL = "enableMMSReadReports";
2176     public static final String KEY_MMS_MULTIPART_SMS_ENABLED_BOOL = "enableMultipartSMS";
2177     public static final String KEY_MMS_NOTIFY_WAP_MMSC_ENABLED_BOOL = "enabledNotifyWapMMSC";
2178     public static final String KEY_MMS_SEND_MULTIPART_SMS_AS_SEPARATE_MESSAGES_BOOL =
2179             "sendMultipartSmsAsSeparateMessages";
2180     public static final String KEY_MMS_SHOW_CELL_BROADCAST_APP_LINKS_BOOL =
2181             "config_cellBroadcastAppLinks";
2182     public static final String KEY_MMS_SMS_DELIVERY_REPORT_ENABLED_BOOL =
2183             "enableSMSDeliveryReports";
2184     public static final String KEY_MMS_SUPPORT_HTTP_CHARSET_HEADER_BOOL =
2185             "supportHttpCharsetHeader";
2186     public static final String KEY_MMS_SUPPORT_MMS_CONTENT_DISPOSITION_BOOL =
2187             "supportMmsContentDisposition";
2188     public static final String KEY_MMS_ALIAS_MAX_CHARS_INT = "aliasMaxChars";
2189     public static final String KEY_MMS_ALIAS_MIN_CHARS_INT = "aliasMinChars";
2190     public static final String KEY_MMS_HTTP_SOCKET_TIMEOUT_INT = "httpSocketTimeout";
2191     public static final String KEY_MMS_MAX_IMAGE_HEIGHT_INT = "maxImageHeight";
2192     public static final String KEY_MMS_MAX_IMAGE_WIDTH_INT = "maxImageWidth";
2193     public static final String KEY_MMS_MAX_MESSAGE_SIZE_INT = "maxMessageSize";
2194     public static final String KEY_MMS_MESSAGE_TEXT_MAX_SIZE_INT = "maxMessageTextSize";
2195     public static final String KEY_MMS_RECIPIENT_LIMIT_INT = "recipientLimit";
2196     public static final String KEY_MMS_SMS_TO_MMS_TEXT_LENGTH_THRESHOLD_INT =
2197             "smsToMmsTextLengthThreshold";
2198     public static final String KEY_MMS_SMS_TO_MMS_TEXT_THRESHOLD_INT = "smsToMmsTextThreshold";
2199     public static final String KEY_MMS_SUBJECT_MAX_LENGTH_INT = "maxSubjectLength";
2200     public static final String KEY_MMS_EMAIL_GATEWAY_NUMBER_STRING = "emailGatewayNumber";
2201     public static final String KEY_MMS_HTTP_PARAMS_STRING = "httpParams";
2202     public static final String KEY_MMS_NAI_SUFFIX_STRING = "naiSuffix";
2203     public static final String KEY_MMS_UA_PROF_TAG_NAME_STRING = "uaProfTagName";
2204     public static final String KEY_MMS_UA_PROF_URL_STRING = "uaProfUrl";
2205     public static final String KEY_MMS_USER_AGENT_STRING = "userAgent";
2206     /**
2207      * If true, add "Connection: close" header to MMS HTTP requests so the connection
2208      * is immediately closed (disabling keep-alive).
2209      */
2210     public static final String KEY_MMS_CLOSE_CONNECTION_BOOL = "mmsCloseConnection";
2211     /**
2212      * Waiting time in milliseconds used before releasing an MMS data call. Not tearing down an MMS
2213      * data connection immediately helps to reduce the message delivering latency if messaging
2214      * continues between all parties in the conversation since the same data connection can be
2215      * reused for further messages.
2216      *
2217      * This timer will control how long the data call will be kept alive before being torn down.
2218      */
2219     public static final String KEY_MMS_NETWORK_RELEASE_TIMEOUT_MILLIS_INT =
2220             "mms_network_release_timeout_millis_int";
2221     /**
2222      * Maximum size in bytes of the PDU to send or download when connected to a non-terrestrial
2223      * network. MmsService will return a result code of MMS_ERROR_TOO_LARGE_FOR_TRANSPORT if
2224      * the PDU exceeds this limit when connected to a non-terrestrial network.
2225      */
2226     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
2227     public static final String KEY_MMS_MAX_NTN_PAYLOAD_SIZE_BYTES_INT =
2228             "mms_max_ntn_payload_size_bytes_int";
2229 
2230     /**
2231      * The flatten {@link android.content.ComponentName componentName} of the activity that can
2232      * setup the device and activate with the network per carrier requirements.
2233      *
2234      * e.g., com.google.android.carrierPackageName/.CarrierActivityName
2235      * @hide
2236      */
2237     @SystemApi
2238     public static final String KEY_CARRIER_SETUP_APP_STRING = "carrier_setup_app_string";
2239 
2240     /**
2241      * Defines carrier-specific actions which act upon
2242      * com.android.internal.telephony.CARRIER_SIGNAL_REDIRECTED, used for customization of the
2243      * default carrier app.
2244      * Format: "CARRIER_ACTION_IDX, ..."
2245      * Where {@code CARRIER_ACTION_IDX} is an integer defined in
2246      * com.android.carrierdefaultapp.CarrierActionUtils
2247      * Example:
2248      * com.android.carrierdefaultapp.CarrierActionUtils#CARRIER_ACTION_DISABLE_METERED_APNS
2249      * disables metered APNs
2250      */
2251     @SuppressLint("IntentName")
2252     public static final String KEY_CARRIER_DEFAULT_ACTIONS_ON_REDIRECTION_STRING_ARRAY =
2253             "carrier_default_actions_on_redirection_string_array";
2254 
2255     /**
2256      * Defines carrier-specific actions which act upon CARRIER_SIGNAL_REQUEST_NETWORK_FAILED
2257      * and configured signal args:
2258      * android.telephony.TelephonyManager#EXTRA_APN_TYPE,
2259      * android.telephony.TelephonyManager#EXTRA_ERROR_CODE
2260      * used for customization of the default carrier app
2261      * Format:
2262      * {
2263      *     "APN_1, ERROR_CODE_1 : CARRIER_ACTION_IDX_1, CARRIER_ACTION_IDX_2...",
2264      *     "APN_1, ERROR_CODE_2 : CARRIER_ACTION_IDX_1 "
2265      * }
2266      * Where {@code APN_1} is an integer defined in {@link android.telephony.data.ApnSetting}
2267      * (e.g. {@link android.telephony.data.ApnSetting#TYPE_DEFAULT}
2268      *
2269      * {@code ERROR_CODE_1} is an integer defined in android.telephony.DataFailCause
2270      * Example:
2271      * android.telephony.DataFailCause#MISSING_UNKNOWN_APN
2272      *
2273      * {@code CARRIER_ACTION_IDX_1} is an integer defined in
2274      * com.android.carrierdefaultapp.CarrierActionUtils
2275      * Example:
2276      * com.android.carrierdefaultapp.CarrierActionUtils#CARRIER_ACTION_DISABLE_METERED_APNS
2277      * disables metered APNs
2278      */
2279     @SuppressLint("IntentName")
2280     public static final String KEY_CARRIER_DEFAULT_ACTIONS_ON_DCFAILURE_STRING_ARRAY =
2281             "carrier_default_actions_on_dcfailure_string_array";
2282 
2283     /**
2284      * Defines carrier-specific actions which act upon CARRIER_SIGNAL_RESET,
2285      * used for customization of the default carrier app.
2286      * Format: "CARRIER_ACTION_IDX, ..."
2287      * Where {@code CARRIER_ACTION_IDX} is an integer defined in
2288      * com.android.carrierdefaultapp.CarrierActionUtils
2289      * Example:
2290      * com.android.carrierdefaultapp.CarrierActionUtils#CARRIER_ACTION_CANCEL_ALL_NOTIFICATIONS
2291      * clears all notifications on reset
2292      */
2293     @SuppressLint("IntentName")
2294     public static final String KEY_CARRIER_DEFAULT_ACTIONS_ON_RESET =
2295             "carrier_default_actions_on_reset_string_array";
2296 
2297     /**
2298      * Defines carrier-specific actions which act upon
2299      * com.android.internal.telephony.CARRIER_SIGNAL_DEFAULT_NETWORK_AVAILABLE,
2300      * used for customization of the default carrier app.
2301      * Format:
2302      * {
2303      *     "true : CARRIER_ACTION_IDX_1",
2304      *     "false: CARRIER_ACTION_IDX_2"
2305      * }
2306      * Where {@code true} is a boolean indicates default network available/unavailable
2307      * Where {@code CARRIER_ACTION_IDX} is an integer defined in
2308      * com.android.carrierdefaultapp.CarrierActionUtils CarrierActionUtils
2309      * Example:
2310      * com.android.carrierdefaultapp.CarrierActionUtils#CARRIER_ACTION_ENABLE_DEFAULT_URL_HANDLER
2311      * enables the app as the default URL handler
2312      */
2313     @SuppressLint("IntentName")
2314     public static final String KEY_CARRIER_DEFAULT_ACTIONS_ON_DEFAULT_NETWORK_AVAILABLE =
2315             "carrier_default_actions_on_default_network_available_string_array";
2316 
2317     /**
2318      * Defines a list of acceptable redirection url for default carrier app.
2319      */
2320     public static final String KEY_CARRIER_DEFAULT_REDIRECTION_URL_STRING_ARRAY =
2321             "carrier_default_redirection_url_string_array";
2322 
2323     /**
2324      * Each config includes the componentName of the carrier app, followed by a list of interesting
2325      * signals(declared in the manifest) which could wake up the app.
2326      * @see com.android.internal.telephony.TelephonyIntents
2327      * Example:
2328      * <item>com.google.android.carrierAPK/.CarrierSignalReceiverA:
2329      * com.android.internal.telephony.CARRIER_SIGNAL_REDIRECTED,
2330      * com.android.internal.telephony.CARRIER_SIGNAL_PCO_VALUE
2331      * </item>
2332      * <item>com.google.android.carrierAPK/.CarrierSignalReceiverB:
2333      * com.android.internal.telephony.CARRIER_SIGNAL_PCO_VALUE
2334      * </item>
2335      * @hide
2336      */
2337     public static final String KEY_CARRIER_APP_WAKE_SIGNAL_CONFIG_STRING_ARRAY =
2338             "carrier_app_wake_signal_config";
2339 
2340     /**
2341      * Each config includes the componentName of the carrier app, followed by a list of interesting
2342      * signals for the app during run-time. The list of signals(intents) are targeting on run-time
2343      * broadcast receivers only, aiming to avoid unnecessary wake-ups and should not be declared in
2344      * the app's manifest.
2345      * @see com.android.internal.telephony.TelephonyIntents
2346      * Example:
2347      * <item>com.google.android.carrierAPK/.CarrierSignalReceiverA:
2348      * com.android.internal.telephony.CARRIER_SIGNAL_REQUEST_NETWORK_FAILED,
2349      * com.android.internal.telephony.CARRIER_SIGNAL_PCO_VALUE
2350      * </item>
2351      * <item>com.google.android.carrierAPK/.CarrierSignalReceiverB:
2352      * com.android.internal.telephony.CARRIER_SIGNAL_REQUEST_NETWORK_FAILED
2353      * </item>
2354      * @hide
2355      */
2356     public static final String KEY_CARRIER_APP_NO_WAKE_SIGNAL_CONFIG_STRING_ARRAY =
2357             "carrier_app_no_wake_signal_config";
2358 
2359     /**
2360      * Determines whether the carrier app needed to be involved when users try to finish setting up
2361      * the SIM card to get network service.
2362      */
2363     public static final String KEY_CARRIER_APP_REQUIRED_DURING_SIM_SETUP_BOOL =
2364             "carrier_app_required_during_setup_bool";
2365 
2366     /**
2367      * Default value for {@link Settings.Global#DATA_ROAMING}
2368      * @hide
2369      */
2370     public static final String KEY_CARRIER_DEFAULT_DATA_ROAMING_ENABLED_BOOL =
2371             "carrier_default_data_roaming_enabled_bool";
2372 
2373     /**
2374      * Determines whether the carrier supports making non-emergency phone calls while the phone is
2375      * in emergency callback mode. Default value is {@code true}, meaning that non-emergency calls
2376      * are allowed in emergency callback mode.
2377      */
2378     public static final String KEY_ALLOW_NON_EMERGENCY_CALLS_IN_ECM_BOOL =
2379             "allow_non_emergency_calls_in_ecm_bool";
2380 
2381     /**
2382      * Time that the telephony framework stays in "emergency SMS mode" after an emergency SMS is
2383      * sent to the network. This is used by carriers to configure the time
2384      * {@link TelephonyManager#isInEmergencySmsMode()} will be true after an emergency SMS is sent.
2385      * This is used by GNSS to override user location permissions so that the carrier network can
2386      * get the user's location for emergency services.
2387      *
2388      * The default is 0, which means that this feature is disabled. The maximum value for this timer
2389      * is 300000 mS (5 minutes).
2390      *
2391      * @hide
2392      */
2393     public static final String KEY_EMERGENCY_SMS_MODE_TIMER_MS_INT =
2394             "emergency_sms_mode_timer_ms_int";
2395 
2396     /**
2397      * Flag indicating whether to allow carrier video calls to emergency numbers.
2398      * When {@code true}, video calls to emergency numbers will be allowed. When {@code false},
2399      * video calls to emergency numbers will be initiated as audio-only calls instead.
2400      */
2401     public static final String KEY_ALLOW_EMERGENCY_VIDEO_CALLS_BOOL =
2402             "allow_emergency_video_calls_bool";
2403 
2404     /**
2405      * Flag indicating whether or not an ongoing call will be held when an outgoing emergency call
2406      * is placed. If true, ongoing calls will be put on hold when an emergency call is placed. If
2407      * false, placing an emergency call will trigger the disconnect of all ongoing calls before
2408      * the emergency call is placed.
2409      */
2410     public static final String KEY_ALLOW_HOLD_CALL_DURING_EMERGENCY_BOOL =
2411             "allow_hold_call_during_emergency_bool";
2412 
2413     /**
2414      * Flag indicating whether or not the carrier supports the periodic exchange of phone numbers
2415      * in the user's address book with the carrier's presence server in order to retrieve the RCS
2416      * capabilities for each contact used in the RCS User Capability Exchange (UCE) procedure. See
2417      * RCC.71, section 3 for more information.
2418      * <p>
2419      * The flag {@link Ims#KEY_ENABLE_PRESENCE_PUBLISH_BOOL} must also be enabled if this flag is
2420      * enabled, as sending a periodic SIP PUBLISH with this device's RCS capabilities is a
2421      * requirement for capability exchange to begin.
2422      * <p>
2423      * When presence is supported, the device should use the
2424      * {@link android.provider.ContactsContract.Data#CARRIER_PRESENCE} bit mask and set the
2425      * {@link android.provider.ContactsContract.Data#CARRIER_PRESENCE_VT_CAPABLE} bit to indicate
2426      * whether each contact supports video calling. The UI is made aware that presence is enabled
2427      * via {@link android.telecom.PhoneAccount#CAPABILITY_VIDEO_CALLING_RELIES_ON_PRESENCE}
2428      * and can choose to hide or show the video calling icon based on whether a contact supports
2429      * video.
2430      *
2431      * @deprecated No longer used in framework code, however it may still be used by applications
2432      * that have not updated their code. This config should still be set to {@code true} if
2433      * {@link Ims#KEY_RCS_BULK_CAPABILITY_EXCHANGE_BOOL} is set to {@code true} and
2434      * {@link Ims#KEY_ENABLE_PRESENCE_CAPABILITY_EXCHANGE_BOOL} is set to {@code true}.
2435      */
2436     @Deprecated
2437     public static final String KEY_USE_RCS_PRESENCE_BOOL = "use_rcs_presence_bool";
2438 
2439     /**
2440      * Flag indicating whether the carrier supports RCS SIP OPTIONS indication for
2441      * User Capability Exchange (UCE).
2442      */
2443     public static final String KEY_USE_RCS_SIP_OPTIONS_BOOL = "use_rcs_sip_options_bool";
2444 
2445     /**
2446      * The duration in seconds that platform call and message blocking is disabled after the user
2447      * contacts emergency services. Platform considers values for below cases:
2448      *  1) 0 <= VALUE <= 604800(one week): the value will be used as the duration directly.
2449      *  2) VALUE > 604800(one week): will use the default value as duration instead.
2450      *  3) VALUE < 0: block will be disabled forever until user re-enable block manually,
2451      *     the suggested value to disable forever is -1.
2452      * See {@code android.provider.BlockedNumberContract#notifyEmergencyContact(Context)}
2453      * See {@code android.provider.BlockedNumberContract#isBlocked(Context, String)}.
2454      */
2455     public static final String KEY_DURATION_BLOCKING_DISABLED_AFTER_EMERGENCY_INT =
2456             "duration_blocking_disabled_after_emergency_int";
2457 
2458     /**
2459      * Determines whether to enable enhanced call blocking feature on the device.
2460      * android.provider.BlockedNumberContract.SystemContract#ENHANCED_SETTING_KEY_BLOCK_UNREGISTERED
2461      * android.provider.BlockedNumberContract.SystemContract#ENHANCED_SETTING_KEY_BLOCK_PRIVATE
2462      * android.provider.BlockedNumberContract.SystemContract#ENHANCED_SETTING_KEY_BLOCK_PAYPHONE
2463      * android.provider.BlockedNumberContract.SystemContract#ENHANCED_SETTING_KEY_BLOCK_UNKNOWN
2464      * android.provider.BlockedNumberContract.SystemContract#ENHANCED_SETTING_KEY_BLOCK_UNAVAILABLE
2465      *
2466      * <p>
2467      * 1. For Single SIM(SS) device, it can be customized in both carrier_config_mccmnc.xml
2468      *    and vendor.xml.
2469      * <p>
2470      * 2. For Dual SIM(DS) device, it should be customized in vendor.xml, since call blocking
2471      *    function is used regardless of SIM.
2472      * <p>
2473      * If {@code true} enable enhanced call blocking feature on the device, {@code false} otherwise.
2474      */
2475     public static final String KEY_SUPPORT_ENHANCED_CALL_BLOCKING_BOOL =
2476             "support_enhanced_call_blocking_bool";
2477 
2478     /**
2479      * For carriers which require an empty flash to be sent before sending the normal 3-way calling
2480      * flash, the duration in milliseconds of the empty flash to send. When {@code 0}, no empty
2481      * flash is sent.
2482      * @deprecated Legacy CDMA is unsupported.
2483      */
2484     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
2485     @Deprecated
2486     public static final String KEY_CDMA_3WAYCALL_FLASH_DELAY_INT = "cdma_3waycall_flash_delay_int";
2487 
2488     /**
2489      * The CDMA roaming mode (aka CDMA system select).
2490      *
2491      * <p>The value should be one of the CDMA_ROAMING_MODE_ constants in {@link TelephonyManager}.
2492      * Values other than {@link TelephonyManager#CDMA_ROAMING_MODE_RADIO_DEFAULT} (which is the
2493      * default) will take precedence over user selection.
2494      *
2495      * @see TelephonyManager#CDMA_ROAMING_MODE_RADIO_DEFAULT
2496      * @see TelephonyManager#CDMA_ROAMING_MODE_HOME
2497      * @see TelephonyManager#CDMA_ROAMING_MODE_AFFILIATED
2498      * @see TelephonyManager#CDMA_ROAMING_MODE_ANY
2499      *
2500      * @deprecated Legacy CDMA is unsupported.
2501      */
2502     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
2503     @Deprecated
2504     public static final String KEY_CDMA_ROAMING_MODE_INT = "cdma_roaming_mode_int";
2505 
2506     /**
2507      * Determines whether 1X voice calls is supported for some CDMA carriers.
2508      * Default value is true.
2509      * @deprecated Legacy CDMA is unsupported.
2510      * @hide
2511      */
2512     @FlaggedApi(Flags.FLAG_DEPRECATE_CDMA)
2513     @Deprecated
2514     @SystemApi
2515     public static final String KEY_SUPPORT_CDMA_1X_VOICE_CALLS_BOOL =
2516             "support_cdma_1x_voice_calls_bool";
2517 
2518     /**
2519      * Boolean indicating if support is provided for directly dialing FDN number from FDN list.
2520      * If false, this feature is not supported.
2521      * @hide
2522      */
2523     public static final String KEY_SUPPORT_DIRECT_FDN_DIALING_BOOL =
2524             "support_direct_fdn_dialing_bool";
2525 
2526     /**
2527      * Int indicating the max number length for FDN
2528      * @hide
2529      */
2530     public static final String KEY_FDN_NUMBER_LENGTH_LIMIT_INT = "fdn_number_length_limit_int";
2531 
2532     /**
2533      * Report IMEI as device id even if it's a CDMA/LTE phone.
2534      *
2535      * @deprecated Legacy CDMA is unsupported.
2536      * @hide
2537      */
2538     @Deprecated
2539     public static final String KEY_FORCE_IMEI_BOOL = "force_imei_bool";
2540 
2541     /**
2542      * The families of Radio Access Technologies that will get clustered and ratcheted,
2543      * ie, we will report transitions up within the family, but not down until we change
2544      * cells. This prevents flapping between base technologies and higher techs that are
2545      * granted on demand within the cell.
2546      * @hide
2547      */
2548     public static final String KEY_RATCHET_RAT_FAMILIES = "ratchet_rat_families";
2549 
2550     /**
2551      * Flag indicating whether some telephony logic will treat a call which was formerly a video
2552      * call as if it is still a video call. When {@code true}:
2553      * <p>
2554      * Logic which will automatically drop a video call which takes place over WIFI when a
2555      * voice call is answered (see {@link #KEY_DROP_VIDEO_CALL_WHEN_ANSWERING_AUDIO_CALL_BOOL}.
2556      * <p>
2557      * Logic which determines whether the user can use TTY calling.
2558      */
2559     public static final String KEY_TREAT_DOWNGRADED_VIDEO_CALLS_AS_VIDEO_CALLS_BOOL =
2560             "treat_downgraded_video_calls_as_video_calls_bool";
2561 
2562     /**
2563      * When {@code true}, if the user is in an ongoing video call over WIFI and answers an incoming
2564      * audio call, the video call will be disconnected before the audio call is answered. This is
2565      * in contrast to the usual expected behavior where a foreground video call would be put into
2566      * the background and held when an incoming audio call is answered.
2567      */
2568     public static final String KEY_DROP_VIDEO_CALL_WHEN_ANSWERING_AUDIO_CALL_BOOL =
2569             "drop_video_call_when_answering_audio_call_bool";
2570 
2571     /**
2572      * Flag indicating whether the carrier supports merging wifi calls when VoWIFI is disabled.
2573      * This can happen in the case of a carrier which allows offloading video calls to WIFI
2574      * separately of whether voice over wifi is enabled. In such a scenario when two video calls
2575      * are downgraded to voice, they remain over wifi. However, if VoWIFI is disabled, these calls
2576      * cannot be merged.
2577      */
2578     public static final String KEY_ALLOW_MERGE_WIFI_CALLS_WHEN_VOWIFI_OFF_BOOL =
2579             "allow_merge_wifi_calls_when_vowifi_off_bool";
2580 
2581     /**
2582      * Flag indicating whether the carrier supports the Hold command while in an IMS call.
2583      * <p>
2584      * The device configuration value {@code config_device_respects_hold_carrier_config} ultimately
2585      * controls whether this carrier configuration option is used.
2586      * Where {@code config_device_respects_hold_carrier_config} is false, the value of
2587      * this carrier configuration is ignored.
2588      * @hide
2589      */
2590     public static final String KEY_ALLOW_HOLD_IN_IMS_CALL_BOOL = "allow_hold_in_ims_call";
2591 
2592     /**
2593      * Flag indicating whether the carrier supports call deflection for an incoming IMS call.
2594      */
2595     public static final String KEY_CARRIER_ALLOW_DEFLECT_IMS_CALL_BOOL =
2596             "carrier_allow_deflect_ims_call_bool";
2597 
2598     /**
2599      * Flag indicating whether the carrier supports explicit call transfer for an IMS call.
2600      * @hide
2601      */
2602     public static final String KEY_CARRIER_ALLOW_TRANSFER_IMS_CALL_BOOL =
2603             "carrier_allow_transfer_ims_call_bool";
2604 
2605     /**
2606      * Flag indicating whether the carrier always wants to play an "on-hold" tone when a call has
2607      * been remotely held.
2608      * <p>
2609      * When {@code true}, if the IMS stack indicates that the call session has been held, a signal
2610      * will be sent from Telephony to play an audible "on-hold" tone played to the user.
2611      * When {@code false}, a hold tone will only be played if the audio session becomes inactive.
2612      * @hide
2613      */
2614     public static final String KEY_ALWAYS_PLAY_REMOTE_HOLD_TONE_BOOL =
2615             "always_play_remote_hold_tone_bool";
2616 
2617     /**
2618      * When true, the Telephony stack will automatically turn off airplane mode and retry a wifi
2619      * emergency call over the cell network if the initial attempt at dialing was met with a SIP 308
2620      * error.
2621      * @hide
2622      */
2623     public static final String KEY_AUTO_RETRY_FAILED_WIFI_EMERGENCY_CALL =
2624             "auto_retry_failed_wifi_emergency_call";
2625 
2626     /**
2627      * When true, indicates that adding a call is disabled when there is an ongoing video call
2628      * or when there is an ongoing call on wifi which was downgraded from video and VoWifi is
2629      * turned off.
2630      */
2631     public static final String KEY_ALLOW_ADD_CALL_DURING_VIDEO_CALL_BOOL =
2632             "allow_add_call_during_video_call";
2633 
2634     /**
2635      * When {@code true}, indicates that video calls can be put on hold in order to swap to another
2636      * call (e.g. a new outgoing call).
2637      * When {@code false}, indicates that video calls will be disconnected when swapping to another
2638      * call.
2639      * <p>
2640      * This is {@code true} by default.
2641      */
2642     public static final String KEY_ALLOW_HOLD_VIDEO_CALL_BOOL = "allow_hold_video_call_bool";
2643 
2644     /**
2645      * When true, indicates that the HD audio icon in the in-call screen should not be shown for
2646      * VoWifi calls.
2647      * @hide
2648      */
2649     public static final String KEY_WIFI_CALLS_CAN_BE_HD_AUDIO = "wifi_calls_can_be_hd_audio";
2650 
2651     /**
2652      * When true, indicates that the HD audio icon in the in-call screen should not be shown for
2653      * video calls.
2654      * @hide
2655      */
2656     public static final String KEY_VIDEO_CALLS_CAN_BE_HD_AUDIO = "video_calls_can_be_hd_audio";
2657 
2658     /**
2659      * When true, indicates that the HD audio icon in the in-call screen should be shown for
2660      * GSM/CDMA calls.
2661      * @hide
2662      */
2663     public static final String KEY_GSM_CDMA_CALLS_CAN_BE_HD_AUDIO =
2664             "gsm_cdma_calls_can_be_hd_audio";
2665 
2666     /**
2667      * Whether system apps are allowed to use fallback if carrier video call is not available.
2668      * Defaults to {@code true}.
2669      */
2670     public static final String KEY_ALLOW_VIDEO_CALLING_FALLBACK_BOOL =
2671             "allow_video_calling_fallback_bool";
2672 
2673     /**
2674      * Defines operator-specific {@link ImsReasonInfo} mappings.
2675      *
2676      * Format: "ORIGINAL_CODE|MESSAGE|NEW_CODE"
2677      * Where {@code ORIGINAL_CODE} corresponds to a {@link ImsReasonInfo#getCode()} code,
2678      * {@code MESSAGE} corresponds to an expected {@link ImsReasonInfo#getExtraMessage()} string,
2679      * and {@code NEW_CODE} is the new {@code ImsReasonInfo#CODE_*} which this combination of
2680      * original code and message shall be remapped to.
2681      *
2682      * Note: If {@code *} is specified for the original code, any ImsReasonInfo with the matching
2683      * {@code MESSAGE} will be remapped to {@code NEW_CODE}.
2684      * If {@code *} is specified for the message, any ImsReasonInfo with the matching
2685      * {@code ORIGINAL_CODE} will be remapped to {@code NEW_CODE}.
2686      * The wildcard for {@code ORIGINAL_CODE} takes precedence to the wildcard for {@code MESSAGE}.
2687      * A mapping with both wildcards has no effect.
2688      *
2689      * Example: "501|call completion elsewhere|1014"
2690      * When the {@link ImsReasonInfo#getCode()} is {@link ImsReasonInfo#CODE_USER_TERMINATED} and
2691      * the {@link ImsReasonInfo#getExtraMessage()} is {@code "call completion elsewhere"},
2692      * {@link ImsReasonInfo#CODE_ANSWERED_ELSEWHERE} shall be used as the {@link ImsReasonInfo}
2693      * code instead.
2694      * @hide
2695      */
2696     public static final String KEY_IMS_REASONINFO_MAPPING_STRING_ARRAY =
2697             "ims_reasoninfo_mapping_string_array";
2698 
2699     /**
2700      * When {@code false}, use default title for Enhanced 4G LTE Mode settings.
2701      * When {@code true}, use the variant.
2702      * @hide
2703      * @deprecated use {@link #KEY_ENHANCED_4G_LTE_TITLE_VARIANT_INT}.
2704      */
2705     @Deprecated
2706     public static final String KEY_ENHANCED_4G_LTE_TITLE_VARIANT_BOOL =
2707             "enhanced_4g_lte_title_variant_bool";
2708 
2709     /**
2710      * The index indicates the carrier specified title string of Enhanced 4G LTE Mode settings.
2711      * Default value is 0, which indicates the default title string.
2712      */
2713     public static final String KEY_ENHANCED_4G_LTE_TITLE_VARIANT_INT =
2714             "enhanced_4g_lte_title_variant_int";
2715 
2716     /**
2717      * Indicates whether the carrier wants to notify the user when handover of an LTE video call to
2718      * WIFI fails.
2719      * <p>
2720      * When {@code true}, if a video call starts on LTE and the modem reports a failure to handover
2721      * the call to WIFI or if no handover success is reported within 60 seconds of call initiation,
2722      * the {@link android.telephony.TelephonyManager#EVENT_HANDOVER_TO_WIFI_FAILED} event is raised
2723      * on the connection.
2724      * @hide
2725      */
2726     public static final String KEY_NOTIFY_VT_HANDOVER_TO_WIFI_FAILURE_BOOL =
2727             "notify_vt_handover_to_wifi_failure_bool";
2728 
2729     /**
2730      * A upper case list of CNAP names that are unhelpful to the user for distinguising calls and
2731      * should be filtered out of the CNAP information. This includes CNAP names such as "WIRELESS
2732      * CALLER" or "UNKNOWN NAME". By default, if there are no filtered names for this carrier, null
2733      * is returned.
2734      * @hide
2735      */
2736     public static final String KEY_FILTERED_CNAP_NAMES_STRING_ARRAY =
2737             "filtered_cnap_names_string_array";
2738 
2739     /**
2740      * The RCS configuration server URL. This URL is used to initiate RCS provisioning.
2741      */
2742     public static final String KEY_RCS_CONFIG_SERVER_URL_STRING = "rcs_config_server_url_string";
2743 
2744     /**
2745      * Determine whether user can change Wi-Fi Calling preference in roaming.
2746      * {@code false} - roaming preference cannot be changed by user independently. If
2747      *                 {@link #KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL} is false,
2748      *                 {@link #KEY_CARRIER_DEFAULT_WFC_IMS_ROAMING_MODE_INT} is used as the default
2749      *                 value. If {@link #KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL} is
2750      *                 true, roaming preference is the same as home preference and
2751      *                 {@link #KEY_CARRIER_DEFAULT_WFC_IMS_MODE_INT} is used as the default value.
2752      * {@code true}  - roaming preference can be changed by user independently if
2753      *                 {@link #KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL} is false. If
2754      *                 {@link #KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL} is true, this
2755      *                 configuration is ignored and roaming preference cannot be changed.
2756      */
2757     public static final String KEY_EDITABLE_WFC_ROAMING_MODE_BOOL =
2758             "editable_wfc_roaming_mode_bool";
2759 
2760     /**
2761      * Flag specifying whether to show blocking pay phone option in blocked numbers screen.
2762      * Only show the option if payphone call presentation is present in the carrier's region.
2763      */
2764     public static final java.lang.String KEY_SHOW_BLOCKING_PAY_PHONE_OPTION_BOOL =
2765             "show_blocking_pay_phone_option_bool";
2766 
2767     /**
2768      * Flag specifying whether the carrier will use the
2769      * WFC home network mode in roaming network.
2770      * {@code false} - roaming preference can be selected separately from the home preference.
2771      * {@code true}  - roaming preference is the same as home preference and
2772      *                 {@link #KEY_CARRIER_DEFAULT_WFC_IMS_MODE_INT} is used as the default value.
2773      */
2774     public static final String KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL =
2775             "use_wfc_home_network_mode_in_roaming_network_bool";
2776 
2777     /**
2778      * Flag specifying whether the carrier is allowed to use metered network to download a
2779      * certificate of Carrier-WiFi.
2780      * {@code false} - default value.
2781      *
2782      * @hide
2783      */
2784     public static final String KEY_ALLOW_METERED_NETWORK_FOR_CERT_DOWNLOAD_BOOL =
2785             "allow_metered_network_for_cert_download_bool";
2786 
2787     /**
2788      * Time delay (in ms) after which we show the notification to switch the preferred
2789      * network.
2790      * @hide
2791      */
2792     public static final String KEY_PREF_NETWORK_NOTIFICATION_DELAY_INT =
2793             "network_notification_delay_int";
2794 
2795     /**
2796      * Time delay (in ms) after which we show the notification for emergency calls,
2797      * while the device is registered over WFC. Default value is -1, which indicates
2798      * that this notification is not pertinent for a particular carrier. We've added a delay
2799      * to prevent false positives.
2800      */
2801     public static final String KEY_EMERGENCY_NOTIFICATION_DELAY_INT =
2802             "emergency_notification_delay_int";
2803 
2804     /**
2805      * When {@code true}, the carrier allows the user of the {@link
2806      * TelephonyManager#sendUssdRequest(String, TelephonyManager.UssdResponseCallback, Handler)}
2807      * API to perform USSD requests. {@code True} by default.
2808      * @hide
2809      */
2810     public static final String KEY_ALLOW_USSD_REQUESTS_VIA_TELEPHONY_MANAGER_BOOL =
2811             "allow_ussd_requests_via_telephony_manager_bool";
2812 
2813     /**
2814      * Indicates whether the carrier supports 3gpp call forwarding MMI codes while roaming. If
2815      * false, the user will be notified that call forwarding is not available when the MMI code
2816      * fails.
2817      */
2818     public static final String KEY_SUPPORT_3GPP_CALL_FORWARDING_WHILE_ROAMING_BOOL =
2819             "support_3gpp_call_forwarding_while_roaming_bool";
2820 
2821     /**
2822      * Boolean indicating whether to display voicemail number as default call forwarding number in
2823      * call forwarding settings.
2824      * If true, display vm number when cf number is null.
2825      * If false, display the cf number from network.
2826      * By default this value is false.
2827      * @hide
2828      */
2829     public static final String KEY_DISPLAY_VOICEMAIL_NUMBER_AS_DEFAULT_CALL_FORWARDING_NUMBER_BOOL =
2830             "display_voicemail_number_as_default_call_forwarding_number";
2831 
2832     /**
2833      * When {@code true}, the user will be notified when they attempt to place an international call
2834      * when the call is placed using wifi calling.
2835      * @hide
2836      */
2837     public static final String KEY_NOTIFY_INTERNATIONAL_CALL_ON_WFC_BOOL =
2838             "notify_international_call_on_wfc_bool";
2839 
2840     /**
2841      * Flag to hide Preset APN details. If true, user cannot enter ApnEditor view of Preset APN,
2842      * and cannot view details of the APN. If false, user can enter ApnEditor view of Preset APN.
2843      * Default value is false.
2844      */
2845     public static final String KEY_HIDE_PRESET_APN_DETAILS_BOOL = "hide_preset_apn_details_bool";
2846 
2847     /**
2848      * Flag specifying whether to show an alert dialog for video call charges.
2849      * By default this value is {@code false}.
2850      */
2851     public static final String KEY_SHOW_VIDEO_CALL_CHARGES_ALERT_DIALOG_BOOL =
2852             "show_video_call_charges_alert_dialog_bool";
2853 
2854     /**
2855      * An array containing custom call forwarding number prefixes that will be blocked while the
2856      * device is reporting that it is roaming. By default, there are no custom call
2857      * forwarding prefixes and none of these numbers will be filtered. If one or more entries are
2858      * present, the system will not complete the call and display an error message.
2859      *
2860      * To display a message to the user when call forwarding fails for 3gpp MMI codes while roaming,
2861      * use the {@link #KEY_SUPPORT_3GPP_CALL_FORWARDING_WHILE_ROAMING_BOOL} option instead.
2862      */
2863     public static final String KEY_CALL_FORWARDING_BLOCKS_WHILE_ROAMING_STRING_ARRAY =
2864             "call_forwarding_blocks_while_roaming_string_array";
2865 
2866     /**
2867      * Call forwarding number prefixes defined by {@link
2868      * #KEY_CALL_FORWARDING_BLOCKS_WHILE_ROAMING_STRING_ARRAY} which will be allowed while the
2869      * device is reporting that it is roaming and IMS is registered over LTE or Wi-Fi.
2870      * By default this value is {@code true}.
2871      * @hide
2872      */
2873     public static final String KEY_SUPPORT_IMS_CALL_FORWARDING_WHILE_ROAMING_BOOL =
2874             "support_ims_call_forwarding_while_roaming_bool";
2875 
2876     /**
2877      * The day of the month (1-31) on which the data cycle rolls over.
2878      * <p>
2879      * If the current month does not have this day, the cycle will roll over at
2880      * the start of the next month.
2881      * <p>
2882      * This setting may be still overridden by explicit user choice. By default,
2883      * {@link #DATA_CYCLE_USE_PLATFORM_DEFAULT} will be used.
2884      */
2885     public static final String KEY_MONTHLY_DATA_CYCLE_DAY_INT = "monthly_data_cycle_day_int";
2886 
2887     /**
2888      * When {@link #KEY_MONTHLY_DATA_CYCLE_DAY_INT}, {@link #KEY_DATA_LIMIT_THRESHOLD_BYTES_LONG},
2889      * or {@link #KEY_DATA_WARNING_THRESHOLD_BYTES_LONG} are set to this value, the platform default
2890      * value will be used for that key.
2891      */
2892     public static final int DATA_CYCLE_USE_PLATFORM_DEFAULT = -1;
2893 
2894     /**
2895      * Flag indicating that a data cycle threshold should be disabled.
2896      * <p>
2897      * If {@link #KEY_DATA_WARNING_THRESHOLD_BYTES_LONG} is set to this value, the platform's
2898      * default data warning, if one exists, will be disabled. A user selected data warning will not
2899      * be overridden.
2900      * <p>
2901      * If {@link #KEY_DATA_LIMIT_THRESHOLD_BYTES_LONG} is set to this value, the platform's
2902      * default data limit, if one exists, will be disabled. A user selected data limit will not be
2903      * overridden.
2904      */
2905     public static final int DATA_CYCLE_THRESHOLD_DISABLED = -2;
2906 
2907     /**
2908      * Controls the data usage warning.
2909      * <p>
2910      * If the user uses more than this amount of data in their billing cycle, as defined by
2911      * {@link #KEY_MONTHLY_DATA_CYCLE_DAY_INT}, the user will be alerted about the usage.
2912      * If the value is set to {@link #DATA_CYCLE_THRESHOLD_DISABLED}, the data usage warning will
2913      * be disabled.
2914      * <p>
2915      * This setting may be overridden by explicit user choice. By default,
2916      * {@link #DATA_CYCLE_USE_PLATFORM_DEFAULT} will be used.
2917      */
2918     public static final String KEY_DATA_WARNING_THRESHOLD_BYTES_LONG =
2919             "data_warning_threshold_bytes_long";
2920 
2921     /**
2922      * Controls if the device should automatically notify the user as they reach
2923      * their cellular data warning. When set to {@code false} the carrier is
2924      * expected to have implemented their own notification mechanism. {@code true} by default.
2925      */
2926     public static final String KEY_DATA_WARNING_NOTIFICATION_BOOL =
2927             "data_warning_notification_bool";
2928 
2929     /**
2930      * Controls if the device should automatically warn the user that sim voice & data function
2931      * might be limited due to dual sim scenario. When set to {@code true} display the notification,
2932      * {@code false} otherwise.
2933      * @hide
2934      */
2935     public static final String KEY_LIMITED_SIM_FUNCTION_NOTIFICATION_FOR_DSDS_BOOL =
2936             "limited_sim_function_notification_for_dsds_bool";
2937 
2938     /**
2939      * Controls the cellular data limit.
2940      * <p>
2941      * If the user uses more than this amount of data in their billing cycle, as defined by
2942      * {@link #KEY_MONTHLY_DATA_CYCLE_DAY_INT}, cellular data will be turned off by the user's
2943      * phone. If the value is set to {@link #DATA_CYCLE_THRESHOLD_DISABLED}, the data limit will be
2944      * disabled.
2945      * <p>
2946      * This setting may be overridden by explicit user choice. By default,
2947      * {@link #DATA_CYCLE_USE_PLATFORM_DEFAULT} will be used.
2948      */
2949     public static final String KEY_DATA_LIMIT_THRESHOLD_BYTES_LONG =
2950             "data_limit_threshold_bytes_long";
2951 
2952     /**
2953      * Controls if the device should automatically notify the user as they reach
2954      * their cellular data limit. When set to {@code false} the carrier is
2955      * expected to have implemented their own notification mechanism. {@code true} by default.
2956      */
2957     public static final String KEY_DATA_LIMIT_NOTIFICATION_BOOL = "data_limit_notification_bool";
2958 
2959     /**
2960      * Controls if the device should automatically notify the user when rapid
2961      * cellular data usage is observed. When set to {@code false} the carrier is
2962      * expected to have implemented their own notification mechanism. {@code true} by default.
2963      */
2964     public static final String KEY_DATA_RAPID_NOTIFICATION_BOOL = "data_rapid_notification_bool";
2965 
2966     /**
2967      * Offset to be reduced from rsrp threshold while calculating signal strength level.
2968      * @hide
2969      */
2970     public static final String KEY_LTE_EARFCNS_RSRP_BOOST_INT = "lte_earfcns_rsrp_boost_int";
2971 
2972     /**
2973      * List of EARFCN (E-UTRA Absolute Radio Frequency Channel Number,
2974      * Reference: 3GPP TS 36.104 5.4.3) inclusive ranges on which lte_earfcns_rsrp_boost_int
2975      * will be applied. Format of the String array is expected to be {"earfcn1_start-earfcn1_end",
2976      * "earfcn2_start-earfcn2_end" ... }
2977      * @hide
2978      */
2979     public static final String KEY_BOOSTED_LTE_EARFCNS_STRING_ARRAY =
2980             "boosted_lte_earfcns_string_array";
2981 
2982     /**
2983      * Offset to be reduced from rsrp threshold while calculating signal strength level.
2984      * @hide
2985      */
2986     public static final String KEY_NRARFCNS_RSRP_BOOST_INT_ARRAY = "nrarfcns_rsrp_boost_int_array";
2987 
2988     /**
2989      * List of NR ARFCN (5G Absolute Radio Frequency Channel Number,
2990      * Reference: 3GPP TS 36.108) inclusive ranges on which corresponding
2991      * nrarfcns_rsrp_boost_int_array will be applied. The size of this array and
2992      * nrarfcns_rsrp_boost_int_array must be the same.
2993      * Format of the String array is expected to be {"nrarfcn1_start-nrarfcn1_end",
2994      * "nrarfcn2_start-nrarfcn2_end" ... }
2995      * @hide
2996      */
2997     public static final String KEY_BOOSTED_NRARFCNS_STRING_ARRAY = "boosted_nrarfcns_string_array";
2998 
2999     /**
3000      * Determine whether to use only RSRP for the number of LTE signal bars.
3001      * @hide
3002      *
3003      * @deprecated use {@link #KEY_PARAMETERS_USED_FOR_LTE_SIGNAL_BAR_INT}.
3004      */
3005     // FIXME: this key and related keys must not be exposed without a consistent philosophy for
3006     // all RATs.
3007     @Deprecated
3008     public static final String KEY_USE_ONLY_RSRP_FOR_LTE_SIGNAL_BAR_BOOL =
3009             "use_only_rsrp_for_lte_signal_bar_bool";
3010 
3011     /**
3012      * Bit-field integer to determine whether to use Reference Signal Received Power (RSRP),
3013      * Reference Signal Received Quality (RSRQ), or/and Reference Signal Signal to Noise Ratio
3014      * (RSSNR) for the number of LTE signal bars and signal criteria reporting enabling.
3015      *
3016      * <p> If a measure is not set, signal criteria reporting from modem will not be triggered and
3017      * not be used for calculating signal level. If multiple measures are set bit, the parameter
3018      * whose value is smallest is used to indicate the signal level.
3019      * <UL>
3020      *  <LI>RSRP = 1 << 0</LI>
3021      *  <LI>RSRQ = 1 << 1</LI>
3022      *  <LI>RSSNR = 1 << 2</LI>
3023      * </UL>
3024      * <p> The value of this key must be bitwise OR of {@link CellSignalStrengthLte#USE_RSRP},
3025      * {@link CellSignalStrengthLte#USE_RSRQ}, {@link CellSignalStrengthLte#USE_RSSNR}.
3026      *
3027      * <p> For example, if both RSRP and RSRQ are used, the value of key is 3 (1 << 0 | 1 << 1).
3028      * If the key is invalid or not configured, a default value (RSRP = 1 << 0) will apply.
3029      *
3030      * @hide
3031      */
3032     public static final String KEY_PARAMETERS_USED_FOR_LTE_SIGNAL_BAR_INT =
3033             "parameters_used_for_lte_signal_bar_int";
3034 
3035     /**
3036      * List of 4 customized 5G SS reference signal received power (SSRSRP) thresholds.
3037      * <p>
3038      * Reference: 3GPP TS 38.215
3039      * <p>
3040      * 4 threshold integers must be within the boundaries [-140 dB, -44 dB], and the levels are:
3041      * <UL>
3042      *     <LI>"NONE: [-140, threshold1)"</LI>
3043      *     <LI>"POOR: [threshold1, threshold2)"</LI>
3044      *     <LI>"MODERATE: [threshold2, threshold3)"</LI>
3045      *     <LI>"GOOD:  [threshold3, threshold4)"</LI>
3046      *     <LI>"EXCELLENT:  [threshold4, -44]"</LI>
3047      * </UL>
3048      * <p>
3049      * This key is considered invalid if the format is violated. If the key is invalid or
3050      * not configured, a default value set will apply.
3051      */
3052     public static final String KEY_5G_NR_SSRSRP_THRESHOLDS_INT_ARRAY =
3053             "5g_nr_ssrsrp_thresholds_int_array";
3054 
3055     /**
3056      * List of 4 customized 5G SS reference signal received quality (SSRSRQ) thresholds.
3057      * <p>
3058      * Reference: 3GPP TS 38.215; 3GPP TS 38.133 section 10
3059      * <p>
3060      * 4 threshold integers must be within the boundaries [-43 dB, 20 dB], and the levels are:
3061      * <UL>
3062      *     <LI>"NONE: [-43, threshold1)"</LI>
3063      *     <LI>"POOR: [threshold1, threshold2)"</LI>
3064      *     <LI>"MODERATE: [threshold2, threshold3)"</LI>
3065      *     <LI>"GOOD:  [threshold3, threshold4)"</LI>
3066      *     <LI>"EXCELLENT:  [threshold4, 20]"</LI>
3067      * </UL>
3068      * <p>
3069      * This key is considered invalid if the format is violated. If the key is invalid or
3070      * not configured, a default value set will apply.
3071      */
3072     public static final String KEY_5G_NR_SSRSRQ_THRESHOLDS_INT_ARRAY =
3073             "5g_nr_ssrsrq_thresholds_int_array";
3074 
3075     /**
3076      * List of 4 customized 5G SS signal-to-noise and interference ratio (SSSINR) thresholds.
3077      * <p>
3078      * Reference: 3GPP TS 38.215,
3079      *            3GPP TS 38.133 10.1.16.1
3080      * <p>
3081      * 4 threshold integers must be within the boundaries [-23 dB, 40 dB], and the levels are:
3082      * <UL>
3083      *     <LI>"NONE: [-23, threshold1)"</LI>
3084      *     <LI>"POOR: [threshold1, threshold2)"</LI>
3085      *     <LI>"MODERATE: [threshold2, threshold3)"</LI>
3086      *     <LI>"GOOD:  [threshold3, threshold4)"</LI>
3087      *     <LI>"EXCELLENT:  [threshold4, 40]"</LI>
3088      * </UL>
3089      * <p>
3090      * This key is considered invalid if the format is violated. If the key is invalid or
3091      * not configured, a default value set will apply.
3092      */
3093     public static final String KEY_5G_NR_SSSINR_THRESHOLDS_INT_ARRAY =
3094             "5g_nr_sssinr_thresholds_int_array";
3095 
3096     /**
3097      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_SSRSRP} measurement
3098      * type defining the required magnitude change between reports.
3099      *
3100      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3101      * is set, the default value 2 is used.
3102      * @hide
3103      */
3104     public static final String KEY_NGRAN_SSRSRP_HYSTERESIS_DB_INT =
3105             "ngran_ssrsrp_hysteresis_db_int";
3106 
3107     /**
3108      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_SSRSRQ} measurement
3109      * type defining the required magnitude change between reports.
3110      *
3111      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3112      * is set, the default value 2 is used.
3113      * @hide
3114      */
3115     public static final String KEY_NGRAN_SSRSRQ_HYSTERESIS_DB_INT =
3116             "ngran_ssrsrq_hysteresis_db_int";
3117 
3118     /**
3119      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_SSSINR} measurement
3120      * type defining the required magnitude change between reports.
3121      *
3122      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3123      * is set, the default value 2 is used.
3124      * @hide
3125      */
3126     public static final String KEY_NGRAN_SSSINR_HYSTERESIS_DB_INT =
3127             "ngran_sssinr_hysteresis_db_int";
3128 
3129     /**
3130      * Bit-field integer to determine whether to use SS reference signal received power (SSRSRP),
3131      * SS reference signal received quality (SSRSRQ), or/and SS signal-to-noise and interference
3132      * ratio (SSSINR) for the number of 5G NR signal bars and signal criteria reporting enabling.
3133      *
3134      * <p> If a measure is not set, signal criteria reporting from modem will not be triggered and
3135      * not be used for calculating signal level. If multiple measures are set bit, the parameter
3136      * whose value is smallest is used to indicate the signal level.
3137      * <UL>
3138      *  <LI>SSRSRP = 1 << 0</LI>
3139      *  <LI>SSRSRQ = 1 << 1</LI>
3140      *  <LI>SSSINR = 1 << 2</LI>
3141      * </UL>
3142      *  The value of this key must be bitwise OR of {@link CellSignalStrengthNr#USE_SSRSRP},
3143      *  {@link CellSignalStrengthNr#USE_SSRSRQ}, {@link CellSignalStrengthNr#USE_SSSINR}.
3144      *
3145      * <p> For example, if both SSRSRP and SSSINR are used, the value of key is 5 (1 << 0 | 1 << 2).
3146      * If the key is invalid or not configured, a default value (SSRSRP = 1 << 0) will apply.
3147      *
3148      * <p> Reference: 3GPP TS 38.215,
3149      *                3GPP TS 38.133 10.1.16.1
3150      *
3151      * @hide
3152      */
3153     public static final String KEY_PARAMETERS_USE_FOR_5G_NR_SIGNAL_BAR_INT =
3154             "parameters_use_for_5g_nr_signal_bar_int";
3155 
3156     /**
3157      * There are two signal strengths, NR and LTE signal strength, during NR (non-standalone).
3158      * Boolean indicating whether to use LTE signal strength as primary during NR (non-standalone).
3159      * By default this value is true.
3160      *
3161      * @hide
3162      */
3163     public static final String KEY_SIGNAL_STRENGTH_NR_NSA_USE_LTE_AS_PRIMARY_BOOL =
3164             "signal_strength_nr_nsa_use_lte_as_primary_bool";
3165 
3166     /**
3167      * String array of default bandwidth values per network type.
3168      * The entries should be of form: "network_name:downlink,uplink", with values in Kbps.
3169      * For NR (5G), the following network names should be used:
3170      * - NR_NSA: NR NSA, sub-6 frequencies
3171      * - NR_NSA_MMWAVE: NR NSA, mmwave frequencies
3172      * - NR_SA: NR SA, sub-6 frequencies
3173      * - NR_SA_MMWAVE: NR SA, mmwave frequencies
3174      * @hide
3175      */
3176     public static final String KEY_BANDWIDTH_STRING_ARRAY = "bandwidth_string_array";
3177 
3178     /**
3179      * For NR (non-standalone), whether to use the LTE value instead of NR value as the default for
3180      * uplink bandwidth. Downlink bandwidth will still use the NR value as the default.
3181      * @hide
3182      */
3183     public static final String KEY_BANDWIDTH_NR_NSA_USE_LTE_VALUE_FOR_UPLINK_BOOL =
3184             "bandwidth_nr_nsa_use_lte_value_for_uplink_bool";
3185 
3186     /**
3187      * Key identifying if voice call barring notification is required to be shown to the user.
3188      * @hide
3189      */
3190     @UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
3191     public static final String KEY_DISABLE_VOICE_BARRING_NOTIFICATION_BOOL =
3192             "disable_voice_barring_notification_bool";
3193 
3194     /**
3195      * List of operators considered non-roaming which won't show roaming icon.
3196      * <p>
3197      * Can use mcc or mcc+mnc as item. For example, 302 or 21407.
3198      * If operators, 21404 and 21407, make roaming agreements, users of 21404 should not see
3199      * the roaming icon as using 21407 network.
3200      * @hide
3201      */
3202     public static final String KEY_NON_ROAMING_OPERATOR_STRING_ARRAY =
3203             "non_roaming_operator_string_array";
3204 
3205     /**
3206      * List of operators considered roaming with the roaming icon.
3207      * <p>
3208      * Can use mcc or mcc+mnc as item. For example, 302 or 21407.
3209      * If operators, 21404 and 21407, make roaming agreements, users of 21404 should see
3210      * the roaming icon as using 21407 network.
3211      * <p>
3212      * A match on this supersedes a match on {@link #KEY_NON_ROAMING_OPERATOR_STRING_ARRAY}.
3213      * @hide
3214      */
3215     public static final String KEY_ROAMING_OPERATOR_STRING_ARRAY = "roaming_operator_string_array";
3216 
3217     /**
3218      * Config to show the roaming indicator (i.e. the "R" icon) from the status bar when roaming.
3219      * The roaming indicator will be shown if this is {@code true} and will not be shown if this is
3220      * {@code false}.
3221      */
3222     public static final String KEY_SHOW_ROAMING_INDICATOR_BOOL = "show_roaming_indicator_bool";
3223 
3224     /**
3225      * URL from which the proto containing the public key of the Carrier used for
3226      * IMSI encryption will be downloaded.
3227      * @hide
3228      */
3229     public static final String IMSI_KEY_DOWNLOAD_URL_STRING = "imsi_key_download_url_string";
3230 
3231     /**
3232      * String representation of a carrier's public key used for IMSI encryption for ePDG. If this
3233      * is provided, the device will use it as a fallback when no key exists on device, but the key
3234      * download will still initiate.
3235      * Example string:
3236      *         "-----BEGIN CERTIFICATE-----\nabcde12345abcde12345abcde12345abcde1234
3237      * 5abcde12345abcde12345\nabcde12345abcde12345abcde12345abcde12345a\n-----END CERTIFICATE-----"
3238      * @hide
3239      */
3240     public static final String IMSI_CARRIER_PUBLIC_KEY_EPDG_STRING =
3241             "imsi_carrier_public_key_epdg_string";
3242 
3243     /**
3244      * String representation of a carrier's public key used for IMSI encryption for WLAN. If this
3245      * is provided, the device will use it as a fallback when no key exists on device, but the key
3246      * download will still initiate.
3247      * Example string:
3248      *         "-----BEGIN CERTIFICATE-----\nabcde12345abcde12345abcde12345abcde1234
3249      * 5abcde12345abcde12345\nabcde12345abcde12345abcde12345abcde12345a\n-----END CERTIFICATE-----"
3250      * @hide
3251      */
3252     public static final String IMSI_CARRIER_PUBLIC_KEY_WLAN_STRING =
3253             "imsi_carrier_public_key_wlan_string";
3254 
3255     /**
3256      * Identifies if the key is available for WLAN or EPDG or both. The value is a bitmask.
3257      * 0 indicates that neither EPDG or WLAN is enabled.
3258      * 1 indicates that key type TelephonyManager#KEY_TYPE_EPDG is enabled.
3259      * 2 indicates that key type TelephonyManager#KEY_TYPE_WLAN is enabled.
3260      * 3 indicates that both are enabled.
3261      */
3262     public static final String IMSI_KEY_AVAILABILITY_INT = "imsi_key_availability_int";
3263 
3264     /**
3265      * Key identifying if the CDMA Caller ID presentation and suppression MMI codes
3266      * should be converted to 3GPP CLIR codes when a multimode (CDMA+UMTS+LTE) device is roaming
3267      * on a 3GPP network. Specifically *67<number> will be converted to #31#<number> and
3268      * *82<number> will be converted to *31#<number> before dialing a call when this key is
3269      * set TRUE and device is roaming on a 3GPP network.
3270      * @deprecated Legacy CDMA is unsupported.
3271      * @hide
3272      */
3273     @Deprecated
3274     public static final String KEY_CONVERT_CDMA_CALLER_ID_MMI_CODES_WHILE_ROAMING_ON_3GPP_BOOL =
3275             "convert_cdma_caller_id_mmi_codes_while_roaming_on_3gpp_bool";
3276 
3277     /**
3278      * Flag specifying whether IMS registration state menu is shown in Status Info setting,
3279      * default to false.
3280      */
3281     public static final String KEY_SHOW_IMS_REGISTRATION_STATUS_BOOL =
3282             "show_ims_registration_status_bool";
3283 
3284     /**
3285      * Flag indicating whether the carrier supports RTT over IMS.
3286      */
3287     public static final String KEY_RTT_SUPPORTED_BOOL = "rtt_supported_bool";
3288 
3289     /**
3290      * Boolean flag indicating whether the carrier supports TTY.
3291      * <p>
3292      * Note that {@link #KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL} controls availability of TTY over
3293      * VoLTE; if this carrier configuration is disabled, then
3294      * {@link #KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL} is also implicitly disabled.
3295      * <p>
3296      * {@link TelecomManager#isTtySupported()} should be used to determine if a device supports TTY,
3297      * and this carrier config key should be used to see if the current carrier supports it.
3298      */
3299     public static final String KEY_TTY_SUPPORTED_BOOL = "tty_supported_bool";
3300 
3301     /**
3302      * Indicates if the carrier supports auto-upgrading a call to RTT when receiving a call from a
3303      * RTT-supported device.
3304      */
3305     public static final String KEY_RTT_AUTO_UPGRADE_BOOL = "rtt_auto_upgrade_bool";
3306 
3307     /**
3308      * Indicates if the carrier supports RTT during a video call.
3309      */
3310     public static final String KEY_RTT_SUPPORTED_FOR_VT_BOOL = "rtt_supported_for_vt_bool";
3311 
3312     /**
3313      * Indicates if the carrier supports upgrading a call that was previously an RTT call to VT.
3314      */
3315     public static final String KEY_VT_UPGRADE_SUPPORTED_FOR_DOWNGRADED_RTT_CALL_BOOL =
3316             "vt_upgrade_supported_for_downgraded_rtt_call";
3317 
3318     /**
3319      * Indicates if the carrier supports upgrading a call that was previously a VT call to RTT.
3320      */
3321     public static final String KEY_RTT_UPGRADE_SUPPORTED_FOR_DOWNGRADED_VT_CALL_BOOL =
3322             "rtt_upgrade_supported_for_downgraded_vt_call";
3323 
3324     /**
3325      * Indicates if the carrier supports upgrading a voice call to an RTT call during the call.
3326      */
3327     public static final String KEY_RTT_UPGRADE_SUPPORTED_BOOL = "rtt_upgrade_supported_bool";
3328 
3329     /**
3330      * Indicates if the carrier supports downgrading a RTT call to a voice call during the call.
3331      */
3332     public static final String KEY_RTT_DOWNGRADE_SUPPORTED_BOOL = "rtt_downgrade_supported_bool";
3333 
3334     /**
3335      * Indicates if the TTY HCO and VCO options should be hidden in the accessibility menu
3336      * if the device is capable of RTT.
3337      */
3338     public static final String KEY_HIDE_TTY_HCO_VCO_WITH_RTT_BOOL = "hide_tty_hco_vco_with_rtt";
3339 
3340     /**
3341      * The flag to disable the popup dialog which warns the user of data charges.
3342      */
3343     public static final String KEY_DISABLE_CHARGE_INDICATION_BOOL =
3344             "disable_charge_indication_bool";
3345 
3346     /**
3347      * Boolean indicating whether to skip the call forwarding (CF) fail-to-disable dialog.
3348      * The logic used to determine whether we succeeded in disabling is carrier specific,
3349      * so the dialog may not always be accurate.
3350      * {@code false} - show CF fail-to-disable dialog.
3351      * {@code true}  - skip showing CF fail-to-disable dialog.
3352      *
3353      * @hide
3354      */
3355     public static final String KEY_SKIP_CF_FAIL_TO_DISABLE_DIALOG_BOOL =
3356             "skip_cf_fail_to_disable_dialog_bool";
3357 
3358     /**
3359      * Flag specifying whether operator supports including no reply condition timer option on
3360      * CFNRy (3GPP TS 24.082 3: Call Forwarding on No Reply) in the call forwarding settings UI.
3361      * {@code true}  - include no reply condition timer option on CFNRy
3362      * {@code false} - don't include no reply condition timer option on CFNRy
3363      *
3364      * @hide
3365      */
3366     public static final String KEY_SUPPORT_NO_REPLY_TIMER_FOR_CFNRY_BOOL =
3367             "support_no_reply_timer_for_cfnry_bool";
3368 
3369     /**
3370      * No reply time value to be sent to network for call forwarding on no reply
3371      * (CFNRy 3GPP TS 24.082 version 17.0 section 3).
3372      * Controls time in seconds for the no reply condition on in the call forwarding
3373      * settings UI.
3374      * This is available when {@link #KEY_SUPPORT_NO_REPLY_TIMER_FOR_CFNRY_BOOL} is true.
3375      *
3376      * @hide
3377      */
3378     public static final String KEY_NO_REPLY_TIMER_FOR_CFNRY_SEC_INT =
3379             "no_reply_timer_for_cfnry_sec_int";
3380 
3381     /**
3382      * List of the FAC (feature access codes) to dial as a normal call.
3383      * @hide
3384      */
3385     public static final String KEY_FEATURE_ACCESS_CODES_STRING_ARRAY =
3386             "feature_access_codes_string_array";
3387 
3388     /**
3389      * Determines if the carrier wants to identify high definition calls in the call log.
3390      * @hide
3391      */
3392     public static final String KEY_IDENTIFY_HIGH_DEFINITION_CALLS_IN_CALL_LOG_BOOL =
3393             "identify_high_definition_calls_in_call_log_bool";
3394 
3395     /**
3396      * Flag specifying whether to use the {@link ServiceState} roaming status, which can be
3397      * affected by other carrier configs (e.g.
3398      * {@link #KEY_GSM_NONROAMING_NETWORKS_STRING_ARRAY}), when setting the SPN display.
3399      * <p>
3400      * If {@code true}, the SPN display uses {@link ServiceState#getRoaming}.
3401      * If {@code false} the SPN display checks if the current MCC/MNC is different from the
3402      * SIM card's MCC/MNC.
3403      *
3404      * @see #KEY_GSM_ROAMING_NETWORKS_STRING_ARRAY
3405      * @see #KEY_GSM_NONROAMING_NETWORKS_STRING_ARRAY
3406      * @see #KEY_NON_ROAMING_OPERATOR_STRING_ARRAY
3407      * @see #KEY_ROAMING_OPERATOR_STRING_ARRAY
3408      * @see #KEY_FORCE_HOME_NETWORK_BOOL
3409      *
3410      * @hide
3411      */
3412     public static final String KEY_SPN_DISPLAY_RULE_USE_ROAMING_FROM_SERVICE_STATE_BOOL =
3413             "spn_display_rule_use_roaming_from_service_state_bool";
3414 
3415     /**
3416      * Determines whether any carrier has been identified and its specific config has been applied,
3417      * default to false.
3418      */
3419     public static final String KEY_CARRIER_CONFIG_APPLIED_BOOL = "carrier_config_applied_bool";
3420 
3421     /**
3422      * Determines whether we should show a warning asking the user to check with their carrier
3423      * on pricing when the user enabled data roaming,
3424      * default to false.
3425      */
3426     public static final String KEY_CHECK_PRICING_WITH_CARRIER_FOR_DATA_ROAMING_BOOL =
3427             "check_pricing_with_carrier_data_roaming_bool";
3428 
3429     /**
3430      * Determines whether we should show a notification when the phone established a data
3431      * connection in roaming network, to warn users about possible roaming charges.
3432      *
3433      * @see #KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_EXCLUDED_MCCS_STRING_ARRAY
3434      * @see #KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_INCLUDED_MCC_MNCS_STRING_ARRAY
3435      * @hide
3436      */
3437     public static final String KEY_SHOW_DATA_CONNECTED_ROAMING_NOTIFICATION_BOOL =
3438             "show_data_connected_roaming_notification";
3439 
3440     /**
3441      * Determines what MCCs are exceptions for the value of
3442      * {@link #KEY_SHOW_DATA_CONNECTED_ROAMING_NOTIFICATION_BOOL}.
3443      * An empty list indicates that there are no exceptions.
3444      *
3445      * @see #KEY_SHOW_DATA_CONNECTED_ROAMING_NOTIFICATION_BOOL
3446      * @see #KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_INCLUDED_MCC_MNCS_STRING_ARRAY
3447      * @hide
3448      */
3449     public static final String
3450             KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_EXCLUDED_MCCS_STRING_ARRAY =
3451             "data_connected_roaming_notification_excluded_mccs_string_array";
3452 
3453     /**
3454      * Determines what MCC+MNCs are exceptions for the MCCs specified in
3455      * {@link #KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_EXCLUDED_MCCS_STRING_ARRAY}, meaning the
3456      * value for the MCC+MNC is {@link #KEY_SHOW_DATA_CONNECTED_ROAMING_NOTIFICATION_BOOL}.
3457      * An empty list indicates that there are no MNC-specific exceptions.
3458      *
3459      * @see #KEY_SHOW_DATA_CONNECTED_ROAMING_NOTIFICATION_BOOL
3460      * @see #KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_EXCLUDED_MCCS_STRING_ARRAY
3461      * @hide
3462      */
3463     public static final String
3464             KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_INCLUDED_MCC_MNCS_STRING_ARRAY =
3465             "data_connected_roaming_notification_included_mcc_mncs_string_array";
3466 
3467     /**
3468      * A list of 4 LTE RSRP thresholds above which a signal level is considered POOR,
3469      * MODERATE, GOOD, or EXCELLENT, to be used in SignalStrength reporting.
3470      *
3471      * Note that the min and max thresholds are fixed at -140 and -44, as explained in
3472      * TS 136.133 9.1.4 - RSRP Measurement Report Mapping.
3473      * <p>
3474      * See SignalStrength#MAX_LTE_RSRP and SignalStrength#MIN_LTE_RSRP. Any signal level outside
3475      * these boundaries is considered invalid.
3476      * @hide
3477      */
3478     public static final String KEY_LTE_RSRP_THRESHOLDS_INT_ARRAY = "lte_rsrp_thresholds_int_array";
3479 
3480     /**
3481      * A list of 4 customized LTE Reference Signal Received Quality (RSRQ) thresholds.
3482      *
3483      * Reference: TS 136.133 v12.6.0 section 9.1.7 - RSRQ Measurement Report Mapping.
3484      *
3485      * 4 threshold integers must be within the boundaries [-34 dB, 3 dB], and the levels are:
3486      *     "NONE: [-34, threshold1)"
3487      *     "POOR: [threshold1, threshold2)"
3488      *     "MODERATE: [threshold2, threshold3)"
3489      *     "GOOD:  [threshold3, threshold4)"
3490      *     "EXCELLENT:  [threshold4, 3]"
3491      *
3492      * This key is considered invalid if the format is violated. If the key is invalid or
3493      * not configured, a default value set will apply.
3494      */
3495     public static final String KEY_LTE_RSRQ_THRESHOLDS_INT_ARRAY = "lte_rsrq_thresholds_int_array";
3496 
3497     /**
3498      * A list of 4 customized LTE Reference Signal Signal to Noise Ratio (RSSNR) thresholds.
3499      *
3500      * 4 threshold integers must be within the boundaries [-20 dB, 30 dB], and the levels are:
3501      *     "NONE: [-20, threshold1)"
3502      *     "POOR: [threshold1, threshold2)"
3503      *     "MODERATE: [threshold2, threshold3)"
3504      *     "GOOD:  [threshold3, threshold4)"
3505      *     "EXCELLENT:  [threshold4, 30]"
3506      *
3507      * This key is considered invalid if the format is violated. If the key is invalid or
3508      * not configured, a default value set will apply.
3509      */
3510     public static final String KEY_LTE_RSSNR_THRESHOLDS_INT_ARRAY =
3511             "lte_rssnr_thresholds_int_array";
3512 
3513     /**
3514      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_RSRP} measurement
3515      * type defining the required magnitude change between reports.
3516      *
3517      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3518      * is set, the default value 2 is used.
3519      * @hide
3520      */
3521     public static final String KEY_EUTRAN_RSRP_HYSTERESIS_DB_INT = "eutran_rsrp_hysteresis_db_int";
3522 
3523     /**
3524      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_RSRQ} measurement
3525      * type defining the required magnitude change between reports.
3526      *
3527      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3528      * is set, the default value 2 is used.
3529      * @hide
3530      */
3531     public static final String KEY_EUTRAN_RSRQ_HYSTERESIS_DB_INT = "eutran_rsrq_hysteresis_db_int";
3532 
3533     /**
3534      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_RSSNR} measurement
3535      * type defining the required magnitude change between reports.
3536      *
3537      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3538      * is set, the default value 2 is used.
3539      * @hide
3540      */
3541     public static final String KEY_EUTRAN_RSSNR_HYSTERESIS_DB_INT =
3542             "eutran_rssnr_hysteresis_db_int";
3543 
3544     /**
3545      * Decides when clients try to bind to iwlan network service, which package name will
3546      * the binding intent go to.
3547      * @hide
3548      */
3549     public static final String KEY_CARRIER_NETWORK_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING =
3550             "carrier_network_service_wlan_package_override_string";
3551 
3552     /**
3553      * Decides when clients try to bind to iwlan network service, which class name will
3554      * the binding intent go to.
3555      * @hide
3556      */
3557     public static final String KEY_CARRIER_NETWORK_SERVICE_WLAN_CLASS_OVERRIDE_STRING =
3558             "carrier_network_service_wlan_class_override_string";
3559 
3560     /**
3561      * Decides when clients try to bind to wwan (cellular) network service, which package name will
3562      * the binding intent go to.
3563      * @hide
3564      */
3565     public static final String KEY_CARRIER_NETWORK_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING =
3566             "carrier_network_service_wwan_package_override_string";
3567 
3568     /**
3569      * Decides when clients try to bind to wwan (cellular) network service, which class name will
3570      * the binding intent go to.
3571      * @hide
3572      */
3573     public static final String KEY_CARRIER_NETWORK_SERVICE_WWAN_CLASS_OVERRIDE_STRING =
3574             "carrier_network_service_wwan_class_override_string";
3575 
3576     /**
3577      * The package name of qualified networks service that telephony binds to.
3578      *
3579      * @hide
3580      */
3581     public static final String KEY_CARRIER_QUALIFIED_NETWORKS_SERVICE_PACKAGE_OVERRIDE_STRING =
3582             "carrier_qualified_networks_service_package_override_string";
3583 
3584     /**
3585      * The class name of qualified networks service that telephony binds to.
3586      *
3587      * @hide
3588      */
3589     public static final String KEY_CARRIER_QUALIFIED_NETWORKS_SERVICE_CLASS_OVERRIDE_STRING =
3590             "carrier_qualified_networks_service_class_override_string";
3591 
3592     /**
3593      * A list of 4 WCDMA RSCP thresholds above which a signal level is considered POOR,
3594      * MODERATE, GOOD, or EXCELLENT, to be used in SignalStrength reporting.
3595      *
3596      * Note that the min and max thresholds are fixed at -120 and -24, as set in 3GPP TS 27.007
3597      * section 8.69.
3598      * <p>
3599      * See CellSignalStrengthWcdma#WCDMA_RSCP_MAX and CellSignalStrengthWcdma#WCDMA_RSCP_MIN.
3600      * Any signal level outside these boundaries is considered invalid.
3601      * @hide
3602      */
3603     public static final String KEY_WCDMA_RSCP_THRESHOLDS_INT_ARRAY =
3604             "wcdma_rscp_thresholds_int_array";
3605 
3606     /**
3607      * A list of 4 WCDMA ECNO thresholds above which a signal level is considered POOR,
3608      * MODERATE, GOOD, or EXCELLENT, to be used in SignalStrength reporting.
3609      *
3610      * Note that the min and max thresholds are fixed at -24 and 1, as set in 3GPP TS 25.215
3611      * section 5.1.5.
3612      * Any signal level outside these boundaries is considered invalid.
3613      * <p>
3614      *
3615      * The default value is {@code {-24, -14, -6, 1}}.
3616      * @hide
3617      */
3618     public static final String KEY_WCDMA_ECNO_THRESHOLDS_INT_ARRAY =
3619             "wcdma_ecno_thresholds_int_array";
3620 
3621     /**
3622      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_RSCP} measurement
3623      * type defining the required magnitude change between reports.
3624      *
3625      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3626      * is set, the default value 2 is used.
3627      * @hide
3628      */
3629     public static final String KEY_UTRAN_RSCP_HYSTERESIS_DB_INT = "utran_rscp_hysteresis_db_int";
3630 
3631     /**
3632      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_ECNO} measurement
3633      * type defining the required magnitude change between reports.
3634      *
3635      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
3636      * is set, the default value 2 is used.
3637      * @hide
3638      */
3639     public static final String KEY_UTRAN_ECNO_HYSTERESIS_DB_INT = "utran_ecno_hysteresis_db_int";
3640 
3641     /**
3642      * The default measurement to use for signal strength reporting. If this is not specified, the
3643      * RSSI is used.
3644      * <p>
3645      * e.g.) To use RSCP by default, set the value to "rscp". The signal strength level will
3646      * then be determined by #KEY_WCDMA_RSCP_THRESHOLDS_INT_ARRAY
3647      * <p>
3648      * Currently this supports the value "rscp","rssi" and "ecno".
3649      * @hide
3650      */
3651     // FIXME: this key and related keys must not be exposed without a consistent philosophy for
3652     // all RATs.
3653     public static final String KEY_WCDMA_DEFAULT_SIGNAL_STRENGTH_MEASUREMENT_STRING =
3654             "wcdma_default_signal_strength_measurement_string";
3655 
3656     /**
3657      * When a partial sms / mms message stay in raw table for too long without being completed,
3658      * we expire them and delete them from the raw table. This carrier config defines the
3659      * expiration time. The default value is milliseconds in 7 days.
3660      * @hide
3661      */
3662     public static final String KEY_UNDELIVERED_SMS_MESSAGE_EXPIRATION_TIME =
3663             "undelivered_sms_message_expiration_time";
3664 
3665     /**
3666      * Specifies a carrier-defined {@link android.telecom.CallRedirectionService} which Telecom
3667      * will bind to for outgoing calls. An empty string indicates that no carrier-defined
3668      * {@link android.telecom.CallRedirectionService} is specified.
3669      */
3670     public static final String KEY_CALL_REDIRECTION_SERVICE_COMPONENT_NAME_STRING =
3671             "call_redirection_service_component_name_string";
3672 
3673     /**
3674      * Support for the original string display of CDMA MO call.
3675      * By default, it is disabled.
3676      *
3677      * @deprecated Legacy CDMA is unsupported.
3678      * @hide
3679      */
3680     @Deprecated
3681     public static final String KEY_CONFIG_SHOW_ORIG_DIAL_STRING_FOR_CDMA_BOOL =
3682             "config_show_orig_dial_string_for_cdma";
3683 
3684     /**
3685      * Flag specifying whether to show notification(call blocking disabled) when Enhanced Call
3686      * Blocking(KEY_SUPPORT_ENHANCED_CALL_BLOCKING_BOOL) is enabled and making emergency call.
3687      * When true, notification is shown always.
3688      * When false, notification is shown only when any setting of "Enhanced Blocked number" is
3689      * enabled.
3690      */
3691     public static final String KEY_SHOW_CALL_BLOCKING_DISABLED_NOTIFICATION_ALWAYS_BOOL =
3692             "show_call_blocking_disabled_notification_always_bool";
3693 
3694     /**
3695      * Some carriers only support SS over UT via INTERNET PDN.
3696      * When mobile data is OFF or data roaming OFF during roaming,
3697      * UI should block the call forwarding operation and notify the user
3698      * that the function only works if data is available.
3699      * @hide
3700      */
3701     public static final String KEY_CALL_FORWARDING_OVER_UT_WARNING_BOOL =
3702             "call_forwarding_over_ut_warning_bool";
3703 
3704     /**
3705      * Some carriers only support SS over UT via INTERNET PDN.
3706      * When mobile data is OFF or data roaming OFF during roaming,
3707      * UI should block the call barring operation and notify the user
3708      * that the function only works if data is available.
3709      * @hide
3710      */
3711     public static final String KEY_CALL_BARRING_OVER_UT_WARNING_BOOL =
3712             "call_barring_over_ut_warning_bool";
3713 
3714     /**
3715      * Some carriers only support SS over UT via INTERNET PDN.
3716      * When mobile data is OFF or data roaming OFF during roaming,
3717      * UI should block the caller id operation and notify the user
3718      * that the function only works if data is available.
3719      * @hide
3720      */
3721     public static final String KEY_CALLER_ID_OVER_UT_WARNING_BOOL =
3722             "caller_id_over_ut_warning_bool";
3723 
3724     /**
3725      * Some carriers only support SS over UT via INTERNET PDN.
3726      * When mobile data is OFF or data roaming OFF during roaming,
3727      * UI should block the call waiting operation and notify the user
3728      * that the function only works if data is available.
3729      * @hide
3730      */
3731     public static final String KEY_CALL_WAITING_OVER_UT_WARNING_BOOL =
3732             "call_waiting_over_ut_warning_bool";
3733 
3734     /**
3735      * Flag indicating whether to support "Network default" option in Caller ID settings for Calling
3736      * Line Identification Restriction (CLIR).
3737      */
3738     public static final String KEY_SUPPORT_CLIR_NETWORK_DEFAULT_BOOL =
3739             "support_clir_network_default_bool";
3740 
3741     /**
3742      * Determines whether the carrier want to support emergency dialer shortcut.
3743      * @hide
3744      */
3745     public static final String KEY_SUPPORT_EMERGENCY_DIALER_SHORTCUT_BOOL =
3746             "support_emergency_dialer_shortcut_bool";
3747 
3748     /**
3749      * Call forwarding uses USSD command without SS command.
3750      * When {@code true}, the call forwarding query/set by ussd command and UI only display Call
3751      * Forwarding when unanswered.
3752      * When {@code false}, don't use USSD to query/set call forwarding.
3753      * @hide
3754      */
3755     public static final String KEY_USE_CALL_FORWARDING_USSD_BOOL = "use_call_forwarding_ussd_bool";
3756 
3757     /**
3758      * This flag specifies whether to support for the caller id set command by ussd.
3759      * When {@code true}, device shall sync caller id ussd result to ss command.
3760      * When {@code false}, caller id don't support ussd command.
3761      * @hide
3762      */
3763     public static final String KEY_USE_CALLER_ID_USSD_BOOL = "use_caller_id_ussd_bool";
3764 
3765     /**
3766      * Call waiting uses USSD command without SS command.
3767      * When {@code true}, the call waiting query/set by ussd command.
3768      * When {@code false}, doesn't use USSD to query/set call waiting.
3769      * @hide
3770      */
3771     public static final String KEY_USE_CALL_WAITING_USSD_BOOL = "use_call_waiting_ussd_bool";
3772 
3773     /**
3774      * Specifies the service class for call waiting service.
3775      * Default value is
3776      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_VOICE}.
3777      * <p>
3778      * See 27.007 +CCFC or +CLCK.
3779      * The value set as below:
3780      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_NONE}
3781      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_VOICE}
3782      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_DATA}
3783      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_FAX}
3784      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_SMS}
3785      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_DATA_SYNC}
3786      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_DATA_ASYNC}
3787      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_PACKET}
3788      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_PAD}
3789      * {@link com.android.internal.telephony.CommandsInterface#SERVICE_CLASS_MAX}
3790      * @hide
3791      */
3792     public static final String KEY_CALL_WAITING_SERVICE_CLASS_INT =
3793             "call_waiting_service_class_int";
3794 
3795     /**
3796      * This configuration allows the system UI to display different 5G icons for different 5G
3797      * scenarios.
3798      *
3799      * There are six 5G scenarios for icon configuration:
3800      * 1. connected_mmwave: device currently connected to 5G cell as the primary or secondary cell
3801      *    and considered NR advanced.
3802      * 2. connected: device currently connected to 5G cell as the primary or secondary cell but not
3803      *    considered NR advanced.
3804      * 3. connected_rrc_idle: device currently connected to 5G cell as the primary or secondary cell
3805      *    and RRC currently in IDLE state.
3806      * 4. not_restricted_rrc_idle: device camped on a network that has 5G capability and the use of
3807      *    5G is not restricted and RRC currently in IDLE state.
3808      * 5. not_restricted_rrc_con: device camped on a network that has 5G capability and the use of
3809      *    5G is not restricted and RRC currently in CONNECTED state.
3810      * 6. restricted: device camped on a network that has 5G capability but the use of 5G is
3811      *    restricted.
3812      *
3813      * The configured string contains multiple key-value pairs separated by comma. For each pair,
3814      * the key and value are separated by a colon. The key corresponds to a 5G status above and
3815      * the value is the icon name. Use "None" as the icon name if no icon should be shown in a
3816      * specific 5G scenario. If the scenario is "None", config can skip this key and value.
3817      *
3818      * Icon name options: "5G_Plus", "5G".
3819      *
3820      * Here is an example:
3821      * UE wants to display 5G_Plus icon for scenario#1, and 5G icon for scenario#2; otherwise not
3822      * define.
3823      * The configuration is: "connected_mmwave:5G_Plus,connected:5G"
3824      * @hide
3825      */
3826     public static final String KEY_5G_ICON_CONFIGURATION_STRING = "5g_icon_configuration_string";
3827 
3828     /**
3829      * This configuration allows the system UI to determine how long to continue to display 5G icons
3830      * when the device switches between different 5G scenarios.
3831      *
3832      * There are eight 5G scenarios:
3833      * 1. connected_mmwave: device currently connected to 5G cell as the primary or secondary cell
3834      *    and considered NR advanced.
3835      * 2. connected: device currently connected to 5G cell as the primary or secondary cell but not
3836      *    considered NR advanced.
3837      * 3. connected_rrc_idle: device currently connected to 5G cell as the primary or secondary cell
3838      *    and RRC currently in IDLE state.
3839      * 4. not_restricted_rrc_idle: device camped on a network that has 5G capability and the use of
3840      *    5G is not restricted and RRC currently in IDLE state.
3841      * 5. not_restricted_rrc_con: device camped on a network that has 5G capability and the use of
3842      *    5G is not restricted and RRC currently in CONNECTED state.
3843      * 6. restricted: device camped on a network that has 5G capability but the use of 5G is
3844      *    restricted.
3845      * 7. legacy: device is not camped on a network that has 5G capability
3846      * 8. any: any of the above scenarios
3847      *
3848      * The configured string contains various timer rules separated by a semicolon.
3849      * Each rule will have three items: prior 5G scenario, current 5G scenario, and grace period
3850      * in seconds before changing the icon. When the 5G state changes from the prior to the current
3851      * 5G scenario, the system UI will continue to show the icon for the prior 5G scenario (defined
3852      * in {@link #KEY_5G_ICON_CONFIGURATION_STRING}) for the amount of time specified by the grace
3853      * period. If the prior 5G scenario is reestablished, the timer will reset and start again if
3854      * the UE changes 5G scenarios again. Defined states (5G scenarios #1-7) take precedence over
3855      * 'any' (5G scenario #8), and unspecified transitions have a default grace period of 0.
3856      * The order of rules in the configuration determines the priority (the first applicable timer
3857      * rule will be used).
3858      *
3859      * Here is an example: "connected_mmwave,connected,30;connected_mmwave,any,10;connected,any,10"
3860      * This configuration defines 3 timers:
3861      * 1. When UE goes from 'connected_mmwave' to 'connected', system UI will continue to display
3862      *    the 5G icon for 'connected_mmwave' for 30 seconds.
3863      * 2. When UE goes from 'connected_mmwave' to any other state (except for connected, since
3864      *    rule 1 would be used instead), system UI will continue to display the 5G icon for
3865      *    'connected_mmwave' for 10 seconds.
3866      * 3. When UE goes from 'connected' to any other state, system UI will continue to display the
3867      *    5G icon for 'connected' for 10 seconds.
3868      *
3869      * @hide
3870      */
3871     public static final String KEY_5G_ICON_DISPLAY_GRACE_PERIOD_STRING =
3872             "5g_icon_display_grace_period_string";
3873 
3874     /**
3875      * This configuration extends {@link #KEY_5G_ICON_DISPLAY_GRACE_PERIOD_STRING} to allow the
3876      * system UI to continue displaying 5G icons after the initial timer expires.
3877      *
3878      * There are eight 5G scenarios:
3879      * 1. connected_mmwave: device currently connected to 5G cell as the primary or secondary cell
3880      *    and considered NR advanced.
3881      * 2. connected: device currently connected to 5G cell as the primary or secondary cell but not
3882      *    considered NR advanced.
3883      * 3. connected_rrc_idle: device currently connected to 5G cell as the primary or secondary cell
3884      *    and RRC currently in IDLE state.
3885      * 4. not_restricted_rrc_idle: device camped on a network that has 5G capability and the use of
3886      *    5G is not restricted and RRC currently in IDLE state.
3887      * 5. not_restricted_rrc_con: device camped on a network that has 5G capability and the use of
3888      *    5G is not restricted and RRC currently in CONNECTED state.
3889      * 6. restricted: device camped on a network that has 5G capability but the use of 5G is
3890      *    restricted.
3891      * 7. legacy: device is not camped on a network that has 5G capability
3892      * 8. any: any of the above scenarios
3893      *
3894      * The configured string contains various timer rules separated by a semicolon.
3895      * Each rule will have three items: primary 5G scenario, secondary 5G scenario, and
3896      * grace period in seconds before changing the icon. When the timer for the primary 5G timer
3897      * expires, the system UI will continue to show the icon for the primary 5G scenario (defined
3898      * in {@link #KEY_5G_ICON_CONFIGURATION_STRING}) for the amount of time specified by the grace
3899      * period. If the primary 5G scenario is reestablished, the timers will reset and the system UI
3900      * will continue to display the icon for the primary 5G scenario without interruption. If the
3901      * secondary 5G scenario is lost, the timer will reset and the icon will reflect the true state.
3902      * Defined states (5G scenarios #1-7) take precedence over 'any' (5G scenario #8), and
3903      * unspecified transitions have a default grace period of 0. The order of rules in the
3904      * configuration determines the priority (the first applicable timer rule will be used).
3905      *
3906      * Here is an example: "connected,not_restricted_rrc_idle,30"
3907      * This configuration defines a secondary timer that extends the primary 'connected' timer.
3908      * When the primary 'connected' timer expires while the UE is in the 'not_restricted_rrc_idle'
3909      * 5G state, system UI will continue to display the 5G icon for 'connected' for 30 seconds.
3910      * If the 5G state returns to 'connected', the timer will be reset without change to the icon,
3911      * and if the 5G state changes to neither 'connected' not 'not_restricted_rrc_idle', the icon
3912      * will change to reflect the true state.
3913      *
3914      * The value can be overridden by {@link #KEY_NR_ADVANCED_BANDS_SECONDARY_TIMER_SECONDS_INT}
3915      * @hide
3916      */
3917     public static final String KEY_5G_ICON_DISPLAY_SECONDARY_GRACE_PERIOD_STRING =
3918             "5g_icon_display_secondary_grace_period_string";
3919 
3920     /**
3921      * When an NR advanced connection is lost and a Physical Cell ID (PCI) change occurs within
3922      * the primary timer{@link #KEY_5G_ICON_DISPLAY_GRACE_PERIOD_STRING}, delay updating the network
3923      * icon.
3924      *
3925      * <p>This delay is implemented because a rapid PCI change often indicates the device is
3926      * switching to a nearby cell tower to quickly restore the NR advanced connection. Displaying
3927      * an intermediate network icon (like 4G/LTE) might be misleading if the 5G connection is
3928      * restored shortly after. This value sets the delay in seconds; 0 disables the feature.</p>
3929      *
3930      * @hide
3931      */
3932     public static final String KEY_NR_ADVANCED_PCI_CHANGE_SECONDARY_TIMER_SECONDS_INT =
3933             "nr_advanced_pci_change_secondary_timer_seconds_int";
3934 
3935 
3936     /**
3937      * The secondary grace periods in seconds to use if NR advanced icon was shown due to connecting
3938      * to bands specified in {@link #KEY_ADDITIONAL_NR_ADVANCED_BANDS_INT_ARRAY}.
3939      *
3940      * The default value is 0, meaning the original value in
3941      * {@link #KEY_5G_ICON_DISPLAY_SECONDARY_GRACE_PERIOD_STRING} is used. Otherwise, it overrides
3942      * the value in {@link #KEY_5G_ICON_DISPLAY_SECONDARY_GRACE_PERIOD_STRING}.
3943      *
3944      * @hide
3945      */
3946     public static final String KEY_NR_ADVANCED_BANDS_SECONDARY_TIMER_SECONDS_INT =
3947             "nr_advanced_bands_secondary_timer_seconds_int";
3948 
3949     /**
3950      * Whether device resets all of NR timers when device camped on a network that haven't 5G
3951      * capability and RRC currently in IDLE state.
3952      *
3953      * The default value is false;
3954      *
3955      * @hide
3956      */
3957     public static final String KEY_NR_TIMERS_RESET_IF_NON_ENDC_AND_RRC_IDLE_BOOL =
3958             "nr_timers_reset_if_non_endc_and_rrc_idle_bool";
3959 
3960     /**
3961      * Whether device resets all of NR timers when device is in a voice call and QOS is established.
3962      * The default value is true;
3963      *
3964      * @see #KEY_5G_ICON_DISPLAY_GRACE_PERIOD_STRING
3965      * @see #KEY_5G_ICON_DISPLAY_SECONDARY_GRACE_PERIOD_STRING
3966      *
3967      * @hide
3968      */
3969     public static final String KEY_NR_TIMERS_RESET_ON_VOICE_QOS_BOOL =
3970             "nr_timers_reset_on_voice_qos_bool";
3971 
3972     /**
3973      * Whether device resets all of NR timers when the PLMN changes.
3974      * The default value is false;
3975      *
3976      * @see #KEY_5G_ICON_DISPLAY_GRACE_PERIOD_STRING
3977      * @see #KEY_5G_ICON_DISPLAY_SECONDARY_GRACE_PERIOD_STRING
3978      *
3979      * @hide
3980      */
3981     public static final String KEY_NR_TIMERS_RESET_ON_PLMN_CHANGE_BOOL =
3982             "nr_timers_reset_on_plmn_change_bool";
3983 
3984     /**
3985      * A list of additional NR advanced band would map to
3986      * {@link TelephonyDisplayInfo#OVERRIDE_NETWORK_TYPE_NR_ADVANCED} when the device is on that
3987      * band.
3988      *
3989      * @hide
3990      */
3991     public static final String KEY_ADDITIONAL_NR_ADVANCED_BANDS_INT_ARRAY =
3992             "additional_nr_advanced_bands_int_array";
3993 
3994     /**
3995      * This configuration allows the framework to control the NR advanced capable by protocol
3996      * configuration options(PCO).
3997      *
3998      * If this config is 0, then the nr advanced capable is enabled.
3999      * If this config is not 0 and PCO container with this config's address is 1, then the nr
4000      * advanced capable is enabled.
4001      * If this config is not 0 and PCO container with this config's address is 0, then the nr
4002      * advanced capable is disabled.
4003      *
4004      * @hide
4005      */
4006     public static final String KEY_NR_ADVANCED_CAPABLE_PCO_ID_INT =
4007             "nr_advanced_capable_pco_id_int";
4008 
4009     /**
4010      * Enabled NR advanced (i.e. 5G+) icon while roaming. The default value is {@code true}, meaming
4011      * the same NR advanced logic used for home network will be used for roaming network as well.
4012      * Set this to {@code false} will disable NR advanced icon while the device is roaming,
4013      * regardless meeting NR advanced criteria or not.
4014      *
4015      * @hide
4016      */
4017     public static final String KEY_ENABLE_NR_ADVANCED_WHILE_ROAMING_BOOL =
4018             "enable_nr_advanced_for_roaming_bool";
4019 
4020     /**
4021      * This configuration allows the framework to use user data communication to detect Idle state,
4022      * and this is used on the 5G icon.
4023      *
4024      * There is a new way for RRC state detection at Android 12. If
4025      * {@link android.telephony.TelephonyManager#isRadioInterfaceCapabilitySupported}(
4026      * {@link TelephonyManager#CAPABILITY_PHYSICAL_CHANNEL_CONFIG_1_6_SUPPORTED}) returns true,
4027      * then framework can use PHYSICAL_CHANNEL_CONFIG for RRC state detection. Based on this
4028      * condition, some carriers want to use the legacy behavior that way is using user data
4029      * communication to detect the Idle state. Therefore, this configuration allows the framework
4030      * to use user data communication to detect Idle state.
4031      *
4032      * There are 3 situations reflects the carrier define Idle state.
4033      * 1. using PHYSICAL_CHANNEL_CONFIG to detect RRC Idle
4034      * 2. using all of data connections to detect RRC Idle.
4035      * 3. using data communication(consider internet data connection only) to detect data Idle.
4036      *
4037      * How to setup for above 3 cases?
4038      * For below part, we call the condition#1 is device support
4039      * {@link android.telephony.TelephonyManager#isRadioInterfaceCapabilitySupported}(
4040      * {@link TelephonyManager#CAPABILITY_PHYSICAL_CHANNEL_CONFIG_1_6_SUPPORTED}).
4041      * The condition#2 is carrier enable the KEY_LTE_ENDC_USING_USER_DATA_FOR_RRC_DETECTION_BOOL.
4042      *
4043      * For case#1, the condition#1 is true and the condition#2 is false.
4044      * For case#2, the condition#1 is false and the condition#2 is false.
4045      * For case#3, the condition#2 is true.
4046      * @hide
4047      */
4048     public static final String KEY_LTE_ENDC_USING_USER_DATA_FOR_RRC_DETECTION_BOOL =
4049             "lte_endc_using_user_data_for_rrc_detection_bool";
4050 
4051     /**
4052      * Controls time in milliseconds until DcTracker reevaluates 5G connection state.
4053      * @hide
4054      */
4055     public static final String KEY_5G_WATCHDOG_TIME_MS_LONG = "5g_watchdog_time_ms_long";
4056 
4057     /**
4058      * Which network types are unmetered. A string array that can contain network type names from
4059      * {@link TelephonyManager#getNetworkTypeName(int)} in addition to the following NR keys:
4060      * NR_NSA - NR NSA is unmetered for sub-6 frequencies
4061      * NR_NSA_MMWAVE - NR NSA is unmetered for mmwave frequencies
4062      * NR_SA - NR SA is unmetered for sub-6 frequencies
4063      * NR_SA_MMWAVE - NR SA is unmetered for mmwave frequencies
4064      *
4065      * Note that this config only applies if an unmetered SubscriptionPlan is set via {@link
4066      * SubscriptionManager#setSubscriptionPlans(int, List, long)} or an unmetered override is set
4067      * via {@link SubscriptionManager#setSubscriptionOverrideUnmetered(int, boolean, int[], long)}
4068      * or {@link SubscriptionManager#setSubscriptionOverrideUnmetered(int, boolean, long)}.
4069      * If neither SubscriptionPlans nor an override are set, then no network types can be unmetered
4070      * regardless of the value of this config.
4071      * @hide
4072      */
4073     public static final String KEY_UNMETERED_NETWORK_TYPES_STRING_ARRAY =
4074             "unmetered_network_types_string_array";
4075 
4076     /**
4077      * Which network types are unmetered when roaming. A string array that can contain network type
4078      * names from {@link TelephonyManager#getNetworkTypeName(int)} in addition to the following
4079      * NR keys:
4080      * NR_NSA - NR NSA is unmetered when roaming for sub-6 frequencies
4081      * NR_NSA_MMWAVE - NR NSA is unmetered when roaming for mmwave frequencies
4082      * NR_SA - NR SA is unmetered when roaming for sub-6 frequencies
4083      * NR_SA_MMWAVE - NR SA is unmetered when roaming for mmwave frequencies
4084      *
4085      * Note that this config only applies if an unmetered SubscriptionPlan is set via {@link
4086      * SubscriptionManager#setSubscriptionPlans(int, List, long)} or an unmetered override is set
4087      * via {@link SubscriptionManager#setSubscriptionOverrideUnmetered(int, boolean, int[], long)}
4088      * or {@link SubscriptionManager#setSubscriptionOverrideUnmetered(int, boolean, long)}.
4089      * If neither SubscriptionPlans nor an override are set, then no network types can be unmetered
4090      * when roaming regardless of the value of this config.
4091      * @hide
4092      */
4093     public static final String KEY_ROAMING_UNMETERED_NETWORK_TYPES_STRING_ARRAY =
4094             "roaming_unmetered_network_types_string_array";
4095 
4096     /**
4097      * Support ASCII 7-BIT encoding for long SMS. This carrier config is used to enable
4098      * this feature.
4099      * @hide
4100      */
4101     public static final String KEY_ASCII_7_BIT_SUPPORT_FOR_LONG_MESSAGE_BOOL =
4102             "ascii_7_bit_support_for_long_message_bool";
4103 
4104     /**
4105      * Controls whether to show wifi calling icon in statusbar when wifi calling is available.
4106      * @hide
4107      */
4108     public static final String KEY_SHOW_WIFI_CALLING_ICON_IN_STATUS_BAR_BOOL =
4109             "show_wifi_calling_icon_in_status_bar_bool";
4110 
4111     /**
4112      * Configuration to indicate that the carrier supports opportunistic data
4113      * auto provisioning. Based on this flag, the device downloads and activates
4114      * corresponding opportunistic profile.
4115      */
4116     public static final String KEY_CARRIER_SUPPORTS_OPP_DATA_AUTO_PROVISIONING_BOOL =
4117             "carrier_supports_opp_data_auto_provisioning_bool";
4118 
4119     /**
4120      * SMDP+ server address for downloading opportunistic eSIM profile.
4121      * FQDN (Fully Qualified Domain Name) of the SM-DP+ (e.g., smdp.gsma.com) restricted to the
4122      * Alphanumeric mode character set defined in table 5 of ISO/IEC 18004 excluding '$'.
4123      */
4124     public static final String KEY_SMDP_SERVER_ADDRESS_STRING = "smdp_server_address_string";
4125 
4126     /**
4127      * This timer value is used in the eSIM Exponential Backoff download retry algorithm.
4128      * Value should be in seconds.
4129      * <OL>
4130      *     <LI>When the first download failure occurs, retry download after BACKOFF_TIMER_VALUE
4131      * seconds.</LI>
4132      *
4133      * <LI>If download fails again then, retry after either BACKOFF_TIMER_VALUE,
4134      * 2xBACKOFF_TIMER_VALUE, or 3xBACKOFF_TIMER_VALUE seconds.</LI>
4135      *
4136      * <LI>In general after the cth failed attempt, retry after k * BACKOFF_TIMER_VALUE
4137      * seconds, where k is a random integer between 1 and 2^c − 1. Max c value is
4138      * {@link #KEY_ESIM_MAX_DOWNLOAD_RETRY_ATTEMPTS_INT}</LI>
4139      * </OL>
4140      */
4141     public static final String KEY_ESIM_DOWNLOAD_RETRY_BACKOFF_TIMER_SEC_INT =
4142             "esim_download_retry_backoff_timer_sec_int";
4143 
4144     /**
4145      * If eSIM profile download fails then, the number of retry attempts by UE
4146      * will be based on this configuration. If download still fails even after the
4147      * MAX attempts configured by this item then the retry is postponed until next
4148      * device bootup.
4149      */
4150     public static final String KEY_ESIM_MAX_DOWNLOAD_RETRY_ATTEMPTS_INT =
4151             "esim_max_download_retry_attempts_int";
4152 
4153     /**
4154      * List of opportunistic carrier-ids associated with CBRS Primary SIM. When CBRS pSIM is
4155      * inserted, opportunistic eSIM is download and this configuration is used for grouping pSIM
4156      * and opportunistic eSIM. Also when a new CBRS pSIM is inserted, old opportunistic eSIMs are
4157      * deleted using the carrier-ids in this configuration.
4158      *
4159      * @hide
4160      */
4161     public static final String KEY_OPPORTUNISTIC_CARRIER_IDS_INT_ARRAY =
4162             "opportunistic_carrier_ids_int_array";
4163 
4164     /**
4165      * Boolean configuration to control auto provisioning eSIM download in
4166      * OpportunisticNetworkService using only WiFi or both WiFi/Data.
4167      * True will download esim only via WiFi.
4168      * False will use both WiFi and Data connection.
4169      *
4170      * @hide
4171      */
4172     public static final String KEY_OPPORTUNISTIC_ESIM_DOWNLOAD_VIA_WIFI_ONLY_BOOL =
4173             "opportunistic_esim_download_via_wifi_only_bool";
4174 
4175     /**
4176      * Controls RSRP threshold, in dBm, at which OpportunisticNetworkService will decide whether
4177      * the opportunistic network is good enough for internet data.
4178      *
4179      * <p>The value of {@link CellSignalStrengthLte#getRsrp()} will be compared with this
4180      * threshold.
4181      */
4182     public static final String KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_RSRP_INT =
4183             "opportunistic_network_entry_threshold_rsrp_int";
4184 
4185     /**
4186      * Controls RSSNR threshold, in dB, at which OpportunisticNetworkService will
4187      * decide whether the opportunistic network is good enough for internet data.
4188      *
4189      * <p>The value of {@link CellSignalStrengthLte#getRssnr()} will be compared with this
4190      * threshold.
4191      */
4192     public static final String KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_RSSNR_INT =
4193             "opportunistic_network_entry_threshold_rssnr_int";
4194 
4195     /**
4196      * Controls RSRP threshold, in dBm, below which OpportunisticNetworkService will decide whether
4197      * the opportunistic network available is not good enough for internet data.
4198      *
4199      * <p>The value of {@link CellSignalStrengthLte#getRsrp()} will be compared with this
4200      * threshold.
4201      */
4202     public static final String KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSRP_INT =
4203             "opportunistic_network_exit_threshold_rsrp_int";
4204 
4205     /**
4206      * Controls RSSNR threshold, in dB, below which OpportunisticNetworkService will
4207      * decide whether the opportunistic network available is not good enough for internet data.
4208      *
4209      * <p>The value of {@link CellSignalStrengthLte#getRssnr()} will be compared with this
4210      * threshold.
4211      */
4212     public static final String KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSSNR_INT =
4213             "opportunistic_network_exit_threshold_rssnr_int";
4214 
4215     /**
4216      * Controls bandwidth threshold in Kbps at which OpportunisticNetworkService will decide whether
4217      * the opportunistic network is good enough for internet data.
4218      */
4219     public static final String KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_BANDWIDTH_INT =
4220             "opportunistic_network_entry_threshold_bandwidth_int";
4221 
4222     /**
4223      * Controls hysteresis time in milli seconds for which OpportunisticNetworkService
4224      * will wait before attaching to a network.
4225      */
4226     public static final String KEY_OPPORTUNISTIC_NETWORK_ENTRY_OR_EXIT_HYSTERESIS_TIME_LONG =
4227             "opportunistic_network_entry_or_exit_hysteresis_time_long";
4228 
4229     /**
4230      * Controls hysteresis time in milli seconds for which OpportunisticNetworkService
4231      * will wait before switching data to an opportunistic network.
4232      */
4233     public static final String KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_HYSTERESIS_TIME_LONG =
4234             "opportunistic_network_data_switch_hysteresis_time_long";
4235 
4236     /**
4237      * Controls hysteresis time in milli seconds for which OpportunisticNetworkService
4238      * will wait before switching data from opportunistic network to primary network.
4239      */
4240     public static final String KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG =
4241             "opportunistic_network_data_switch_exit_hysteresis_time_long";
4242 
4243     /**
4244      * Controls whether to do ping test before switching data to opportunistic network.
4245      * This carrier config is used to disable this feature.
4246      */
4247     public static final String KEY_PING_TEST_BEFORE_DATA_SWITCH_BOOL =
4248             "ping_test_before_data_switch_bool";
4249 
4250     /**
4251      * Controls whether to switch data to primary from opportunistic subscription
4252      * if primary is out of service. This control only affects system or 1st party app
4253      * initiated data switch, but will not override data switch initiated by privileged carrier apps
4254      * This carrier config is used to disable this feature.
4255      */
4256     public static final String KEY_SWITCH_DATA_TO_PRIMARY_IF_PRIMARY_IS_OOS_BOOL =
4257             "switch_data_to_primary_if_primary_is_oos_bool";
4258 
4259     /**
4260      * Controls the ping pong determination of opportunistic network.
4261      * If opportunistic network is determined as out of service or below
4262      * #KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSRP_INT or
4263      * #KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSSNR_INT within
4264      * #KEY_OPPORTUNISTIC_NETWORK_PING_PONG_TIME_LONG of switching to opportunistic network,
4265      * it will be determined as ping pong situation by system app or 1st party app.
4266      */
4267     public static final String KEY_OPPORTUNISTIC_NETWORK_PING_PONG_TIME_LONG =
4268             "opportunistic_network_ping_pong_time_long";
4269 
4270     /**
4271      * Controls back off time in milli seconds for switching back to
4272      * opportunistic subscription. This time will be added to
4273      * {@link CarrierConfigManager#KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_HYSTERESIS_TIME_LONG} to
4274      * determine hysteresis time if there is ping pong situation
4275      * (determined by system app or 1st party app) between primary and opportunistic
4276      * subscription. Ping ping situation is defined in
4277      * #KEY_OPPORTUNISTIC_NETWORK_PING_PONG_TIME_LONG.
4278      * If ping pong situation continuous #KEY_OPPORTUNISTIC_NETWORK_BACKOFF_TIME_LONG
4279      * will be added to previously determined hysteresis time.
4280      */
4281     public static final String KEY_OPPORTUNISTIC_NETWORK_BACKOFF_TIME_LONG =
4282             "opportunistic_network_backoff_time_long";
4283 
4284     /**
4285      * Controls the max back off time in milli seconds for switching back to
4286      * opportunistic subscription.
4287      * This time will be the max hysteresis that can be determined irrespective of there is
4288      * continuous ping pong situation or not as described in
4289      * #KEY_OPPORTUNISTIC_NETWORK_PING_PONG_TIME_LONG and
4290      * #KEY_OPPORTUNISTIC_NETWORK_BACKOFF_TIME_LONG.
4291      */
4292     public static final String KEY_OPPORTUNISTIC_NETWORK_MAX_BACKOFF_TIME_LONG =
4293             "opportunistic_network_max_backoff_time_long";
4294 
4295     /** @hide */
4296     public static class OpportunisticNetwork {
4297         /**
4298          * Prefix of all {@code OpportunisticNetwork.KEY_*} constants.
4299          *
4300          * @hide
4301          */
4302         public static final String PREFIX = "opportunistic.";
4303 
4304         /**
4305          * Controls SS-RSRP threshold in dBm at which 5G opportunistic network will be considered
4306          * good enough for internet data. Note other factors may be considered for the final
4307          * decision.
4308          *
4309          * <p>The value of {@link CellSignalStrengthNr#getSsRsrp()} will be compared with this
4310          * threshold.
4311          *
4312          * @hide
4313          */
4314         public static final String KEY_ENTRY_THRESHOLD_SS_RSRP_INT =
4315                 PREFIX + "entry_threshold_ss_rsrp_int";
4316 
4317         /**
4318          * Similar to {@link #KEY_ENTRY_THRESHOLD_SS_RSRP_INT} but supports different
4319          * thresholds for different 5G bands. For bands not specified here, the threshold
4320          * will be {@link #KEY_ENTRY_THRESHOLD_SS_RSRP_INT}.
4321          *
4322          * <p>For each key-value in the bundle: the key is the band number in string, which
4323          * shall be a decimal integer as defined in {@code NgranBands.BAND_*} constants;
4324          * the value is the threshold in int.
4325          *
4326          * @hide
4327          */
4328         public static final String KEY_ENTRY_THRESHOLD_SS_RSRP_INT_BUNDLE =
4329                 PREFIX + "entry_threshold_ss_rsrp_int_bundle";
4330 
4331         /**
4332          * Controls SS-RSRQ threshold in dB at which 5G opportunistic network will be considered
4333          * good enough for internet data. Note other factors may be considered for the final
4334          * decision.
4335          *
4336          * <p>The value of {@link CellSignalStrengthNr#getSsRsrq()} will be compared with this
4337          * threshold.
4338          *
4339          * @hide
4340          */
4341         public static final String KEY_ENTRY_THRESHOLD_SS_RSRQ_DOUBLE =
4342                 PREFIX + "entry_threshold_ss_rsrq_double";
4343 
4344         /**
4345          * Similar to {@link #KEY_ENTRY_THRESHOLD_SS_RSRQ_DOUBLE} but supports different
4346          * thresholds for different 5G bands. For bands not specified here, the threshold
4347          * will be {@link #KEY_ENTRY_THRESHOLD_SS_RSRQ_DOUBLE}.
4348          *
4349          * <p>For each key-value in the bundle: the key is the band number in string, which
4350          * shall be a decimal integer as defined in {@code NgranBands.BAND_*} constants;
4351          * the value is the threshold in double.
4352          *
4353          * @hide
4354          */
4355         public static final String KEY_ENTRY_THRESHOLD_SS_RSRQ_DOUBLE_BUNDLE =
4356                 PREFIX + "entry_threshold_ss_rsrq_double_bundle";
4357 
4358         /**
4359          * Controls SS-RSRP threshold in dBm below which 5G opportunistic network available will not
4360          * be considered good enough for internet data. Note other factors may be considered
4361          * for the final decision.
4362          *
4363          * <p>The value of {@link CellSignalStrengthNr#getSsRsrp()} will be compared with this
4364          * threshold.
4365          *
4366          * @hide
4367          */
4368         public static final String KEY_EXIT_THRESHOLD_SS_RSRP_INT =
4369                 PREFIX + "exit_threshold_ss_rsrp_int";
4370 
4371         /**
4372          * Similar to {@link #KEY_EXIT_THRESHOLD_SS_RSRP_INT} but supports different
4373          * thresholds for different 5G bands. For bands not specified here, the threshold
4374          * will be {@link #KEY_EXIT_THRESHOLD_SS_RSRP_INT}.
4375          *
4376          * <p>The syntax of its value is similar to
4377          * {@link #KEY_ENTRY_THRESHOLD_SS_RSRP_INT_BUNDLE}.
4378          *
4379          * @hide
4380          */
4381         public static final String KEY_EXIT_THRESHOLD_SS_RSRP_INT_BUNDLE =
4382                 PREFIX + "exit_threshold_ss_rsrp_int_bundle";
4383 
4384         /**
4385          * Controls SS-RSRQ threshold in dB below which 5G opportunistic network available will not
4386          * be considered good enough for internet data. Note other factors may be considered
4387          * for the final decision.
4388          *
4389          * <p>The value of {@link CellSignalStrengthNr#getSsRsrq()} will be compared with this
4390          * threshold.
4391          *
4392          * @hide
4393          */
4394         public static final String KEY_EXIT_THRESHOLD_SS_RSRQ_DOUBLE =
4395                 PREFIX + "exit_threshold_ss_rsrq_double";
4396 
4397         /**
4398          * Similar to {@link #KEY_EXIT_THRESHOLD_SS_RSRQ_DOUBLE} but supports different
4399          * thresholds for different 5G bands. For bands not specified here, the threshold
4400          * will be {@link #KEY_EXIT_THRESHOLD_SS_RSRQ_DOUBLE}.
4401          *
4402          * <p>The syntax of its value is similar to
4403          * {@link #KEY_ENTRY_THRESHOLD_SS_RSRQ_DOUBLE_BUNDLE}.
4404          *
4405          * @hide
4406          */
4407         public static final String KEY_EXIT_THRESHOLD_SS_RSRQ_DOUBLE_BUNDLE =
4408                 PREFIX + "exit_threshold_ss_rsrq_double_bundle";
4409 
4410         /**
4411          * Controls hysteresis time in milliseconds for which will be waited before switching
4412          * data to a 5G opportunistic network.
4413          *
4414          * @hide
4415          */
4416         public static final String KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG =
4417                 PREFIX + "5g_data_switch_hysteresis_time_long";
4418 
4419         /**
4420          * Similar to {@link #KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG} but supports
4421          * different values for different 5G bands. For bands not specified here, the threshold
4422          * will be {@link #KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG}.
4423          *
4424          * <p>For each key-value in the bundle: the key is the band number in string, which
4425          * shall be a decimal integer as defined in {@code NgranBands.BAND_*} constants;
4426          * the value is the time in long.
4427          *
4428          * @hide
4429          */
4430         public static final String KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG_BUNDLE =
4431                 PREFIX + "5g_data_switch_hysteresis_time_long_bundle";
4432 
4433         /**
4434          * Controls hysteresis time in milliseconds for which will be waited before switching from
4435          * 5G opportunistic network to primary network.
4436          *
4437          * @hide
4438          */
4439         public static final String KEY_5G_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG =
4440                 PREFIX + "5g_data_switch_exit_hysteresis_time_long";
4441 
4442         /**
4443          * Similar to {@link #KEY_5G_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG} but supports
4444          * different values for different 5G bands. For bands not specified here, the threshold
4445          * will be {@link #KEY_5G_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG}.
4446          *
4447          * <p>The syntax is similar to
4448          * {@link KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG_BUNDLE}.
4449          *
4450          * @hide
4451          */
4452         public static final String KEY_5G_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG_BUNDLE =
4453                 PREFIX + "5g_data_switch_exit_hysteresis_time_long_bundle";
4454 
4455         /**
4456          * Controls back off time in milliseconds for switching back to
4457          * 5G opportunistic subscription. This time will be added to
4458          * {@link #KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG} to
4459          * determine hysteresis time if there is ping pong situation
4460          * (determined by system app or 1st party app) between primary and 5G opportunistic
4461          * subscription. Ping ping situation is defined in
4462          * {@link #KEY_5G_PING_PONG_TIME_LONG}.
4463          * If ping pong situation continuous {@link #KEY_5G_NETWORK_BACKOFF_TIME_LONG}
4464          * will be added to previously determined hysteresis time.
4465          *
4466          * @hide
4467          */
4468         public static final String KEY_5G_BACKOFF_TIME_LONG =
4469                 PREFIX + "5g_backoff_time_long";
4470 
4471         /**
4472          * Controls the max back off time in milliseconds for switching back to
4473          * 5G opportunistic subscription.
4474          * This time will be the max hysteresis that can be determined irrespective of there is
4475          * continuous ping pong situation or not as described in
4476          * {@link #KEY_5G_PING_PONG_TIME_LONG} and
4477          * {@link #KEY_5G_BACKOFF_TIME_LONG}.
4478          *
4479          * @hide
4480          */
4481         public static final String KEY_5G_MAX_BACKOFF_TIME_LONG =
4482                 PREFIX + "5g_max_backoff_time_long";
4483 
4484         /**
4485          * Controls the ping pong determination of 5G opportunistic network.
4486          * If opportunistic network is determined as out of service or below
4487          * {@link #KEY_EXIT_THRESHOLD_SS_RSRP_INT} or
4488          * {@link #KEY_EXIT_THRESHOLD_SS_RSRQ_DOUBLE} within
4489          * the time specified by this carrier config of switching to opportunistic network,
4490          * it will be determined as ping pong situation by system app or 1st party app.
4491          *
4492          * @hide
4493          */
4494         public static final String KEY_5G_PING_PONG_TIME_LONG =
4495                 PREFIX + "5g_ping_pong_time_long";
4496 
getDefaults()4497         private static PersistableBundle getDefaults() {
4498             PersistableBundle defaults = new PersistableBundle();
4499             // Default value is -111 dBm for all bands.
4500             sDefaults.putInt(KEY_ENTRY_THRESHOLD_SS_RSRP_INT, -111);
4501             sDefaults.putPersistableBundle(KEY_ENTRY_THRESHOLD_SS_RSRP_INT_BUNDLE,
4502                                            PersistableBundle.EMPTY);
4503             // Default value is -18.5 dB for all bands.
4504             sDefaults.putDouble(KEY_ENTRY_THRESHOLD_SS_RSRQ_DOUBLE, -18.5);
4505             sDefaults.putPersistableBundle(
4506                     KEY_ENTRY_THRESHOLD_SS_RSRQ_DOUBLE_BUNDLE,
4507                     PersistableBundle.EMPTY);
4508             // Default value is -120 dBm for all bands.
4509             sDefaults.putInt(KEY_EXIT_THRESHOLD_SS_RSRP_INT, -120);
4510             sDefaults.putPersistableBundle(KEY_EXIT_THRESHOLD_SS_RSRP_INT_BUNDLE,
4511                                            PersistableBundle.EMPTY);
4512             // Default value is -18.5 dB for all bands.
4513             sDefaults.putDouble(KEY_EXIT_THRESHOLD_SS_RSRQ_DOUBLE, -18.5);
4514             sDefaults.putPersistableBundle(
4515                     KEY_EXIT_THRESHOLD_SS_RSRQ_DOUBLE_BUNDLE,
4516                     PersistableBundle.EMPTY);
4517             // Default value is 2 seconds for all bands.
4518             defaults.putLong(KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG, 2000);
4519             defaults.putPersistableBundle(
4520                     KEY_5G_DATA_SWITCH_HYSTERESIS_TIME_LONG_BUNDLE,
4521                     PersistableBundle.EMPTY);
4522             // Default value is 2 seconds for all bands.
4523             defaults.putLong(KEY_5G_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG, 2000);
4524             defaults.putPersistableBundle(
4525                     KEY_5G_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG_BUNDLE,
4526                     PersistableBundle.EMPTY);
4527             // Default value is 10 seconds.
4528             sDefaults.putLong(KEY_5G_BACKOFF_TIME_LONG, 10000);
4529             // Default value is 60 seconds.
4530             sDefaults.putLong(KEY_5G_MAX_BACKOFF_TIME_LONG, 60000);
4531             // Default value is 60 seconds.
4532             sDefaults.putLong(KEY_5G_PING_PONG_TIME_LONG, 60000);
4533             return defaults;
4534         }
4535     }
4536 
4537     /**
4538      * Controls whether 4G opportunistic networks should be scanned for possible data switch.
4539      *
4540      * @hide
4541      */
4542     public static final String KEY_ENABLE_4G_OPPORTUNISTIC_NETWORK_SCAN_BOOL =
4543             "enabled_4g_opportunistic_network_scan_bool";
4544 
4545     /**
4546      * Only relevant when the device supports opportunistic networks but does not support
4547      * simultaneous 5G+5G. Controls how long, in milliseconds, to wait before opportunistic network
4548      * goes out of service before switching the 5G capability back to primary stack. The idea of
4549      * waiting a few seconds is to minimize the calling of the expensive capability switching
4550      * operation in the case where CBRS goes back into service shortly after going out of it.
4551      *
4552      * @hide
4553      */
4554     public static final String KEY_TIME_TO_SWITCH_BACK_TO_PRIMARY_IF_OPPORTUNISTIC_OOS_LONG =
4555             "time_to_switch_back_to_primary_if_opportunistic_oos_long";
4556 
4557     /**
4558      * Only relevant when the device supports opportunistic networks but does not support
4559      * simultaneous 5G+5G. Controls how long, in milliseconds, after 5G capability has switched back
4560      * to primary stack due to opportunistic network being OOS. The idea is to minimizing the
4561      * 'ping-ponging' effect where device is constantly witching capability back and forth between
4562      * primary and opportunistic stack.
4563      *
4564      * @hide
4565      */
4566     public static final String
4567             KEY_OPPORTUNISTIC_TIME_TO_SCAN_AFTER_CAPABILITY_SWITCH_TO_PRIMARY_LONG =
4568             "opportunistic_time_to_scan_after_capability_switch_to_primary_long";
4569 
4570     /**
4571      * Indicates zero or more emergency number prefix(es), because some carrier requires
4572      * if users dial an emergency number address with a specific prefix, the combination of the
4573      * prefix and the address is also a valid emergency number to dial. For example, an emergency
4574      * number prefix is 318, and the emergency number is 911. Both 318911 and 911 can be dialed by
4575      * users for emergency call. An empty array of string indicates that current carrier does not
4576      * have this requirement.
4577      */
4578     public static final String KEY_EMERGENCY_NUMBER_PREFIX_STRING_ARRAY =
4579             "emergency_number_prefix_string_array";
4580 
4581     /**
4582      * Indicates whether carrier treats "*67" or "*82" as a temporary mode CLIR.
4583      * @hide
4584      */
4585     public static final String KEY_CARRIER_SUPPORTS_CALLER_ID_VERTICAL_SERVICE_CODES_BOOL =
4586             "carrier_supports_caller_id_vertical_service_codes_bool";
4587 
4588     /**
4589      * Smart forwarding config. Smart forwarding is a feature to configure call forwarding to a
4590      * different SIM in the device when one SIM is not reachable. The config here specifies a smart
4591      * forwarding component that will launch UI for changing the configuration. An empty string
4592      * indicates that no smart forwarding component is specified.
4593      *
4594      * Currently, only one non-empty configuration of smart forwarding component within system will
4595      * be used when multiple SIMs are inserted.
4596      *
4597      * Empty string by default.
4598      *
4599      * @hide
4600      */
4601     public static final String KEY_SMART_FORWARDING_CONFIG_COMPONENT_NAME_STRING =
4602             "smart_forwarding_config_component_name_string";
4603 
4604     /**
4605      * Indicates when a carrier has a primary subscription and an opportunistic subscription active,
4606      * and when Internet data is switched to opportunistic network, whether to still show
4607      * signal bar of primary network. By default it will be false, meaning whenever data
4608      * is going over opportunistic network, signal bar will reflect signal strength and rat
4609      * icon of that network.
4610      */
4611     public static final String KEY_ALWAYS_SHOW_PRIMARY_SIGNAL_BAR_IN_OPPORTUNISTIC_NETWORK_BOOLEAN =
4612             "always_show_primary_signal_bar_in_opportunistic_network_boolean";
4613 
4614     /**
4615      * Upon data switching between subscriptions within a carrier group, if switch depends on
4616      * validation result, this value defines customized value of how long we wait for validation
4617      * success before we fail and revoke the switch.
4618      * Time out is in milliseconds.
4619      */
4620     public static final String KEY_DATA_SWITCH_VALIDATION_TIMEOUT_LONG =
4621             "data_switch_validation_timeout_long";
4622 
4623     /**
4624      * The minimum timeout of UDP port 4500 NAT / firewall entries on the Internet PDN of this
4625      * carrier network. This will be used by Android platform VPNs to tune IPsec NAT keepalive
4626      * interval. If this value is too low to provide uninterrupted inbound connectivity, then
4627      * Android system VPNs may indicate to applications that the VPN cannot support long-lived
4628      * TCP connections.
4629      * @hide
4630      */
4631     @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)
4632     public static final String KEY_MIN_UDP_PORT_4500_NAT_TIMEOUT_SEC_INT =
4633             "min_udp_port_4500_nat_timeout_sec_int";
4634 
4635     /**
4636      * The preferred IKE protocol for ESP packets.
4637      *
4638      * This will be used by Android platform VPNs to select preferred encapsulation type and IP
4639      * protocol type. The possible customization values are:
4640      *
4641      * AUTO IP VERSION and ENCAPSULATION TYPE SELECTION : "0"
4642      * IPv4 UDP                                         : "40"
4643      * IPv6 ESP                                         : "61"
4644      *
4645      * See the {@code PREFERRED_IKE_PROTOCOL_} constants in
4646      * {@link com.android.server.connectivity.Vpn}.
4647      * @hide
4648      */
4649     public static final String KEY_PREFERRED_IKE_PROTOCOL_INT = "preferred_ike_protocol_int";
4650 
4651     /**
4652      * Specifies whether the system should prefix the EAP method to the anonymous identity.
4653      * The following prefix will be added if this key is set to TRUE:
4654      *   EAP-AKA: "0"
4655      *   EAP-SIM: "1"
4656      *   EAP-AKA_PRIME: "6"
4657      */
4658     public static final String ENABLE_EAP_METHOD_PREFIX_BOOL = "enable_eap_method_prefix_bool";
4659 
4660     /**
4661      * Indicates that GBA_ME should be used for GBA authentication, as defined in 3GPP TS 33.220.
4662      * @hide
4663      */
4664     @SystemApi
4665     public static final int GBA_ME = 1;
4666 
4667     /**
4668      * Indicates that GBA_U should be used for GBA authentication, as defined in 3GPP TS 33.220.
4669      * @hide
4670      */
4671     @SystemApi
4672     public static final int GBA_U = 2;
4673 
4674     /**
4675      * Indicates that GBA_Digest should be used for GBA authentication, as defined
4676      * in 3GPP TS 33.220.
4677      * @hide
4678      */
4679     @SystemApi
4680     public static final int GBA_DIGEST = 3;
4681 
4682     /**
4683      * An integer representing the GBA mode to use for requesting credentials
4684      * via {@link TelephonyManager#bootstrapAuthenticationRequest}.
4685      *
4686      * One of {@link #GBA_ME}, {@link #GBA_U}, or {@link #GBA_DIGEST}.
4687      * @hide
4688      */
4689     @SystemApi
4690     public static final String KEY_GBA_MODE_INT = "gba_mode_int";
4691 
4692     /**
4693      * An integer representing the organization code to be used when building the
4694      * {@link UaSecurityProtocolIdentifier} used when requesting GBA authentication.
4695      *
4696      * See the {@code ORG_} constants in {@link UaSecurityProtocolIdentifier}.
4697      * @hide
4698      */
4699     @SystemApi
4700     public static final String KEY_GBA_UA_SECURITY_ORGANIZATION_INT =
4701             "gba_ua_security_organization_int";
4702 
4703     /**
4704      * An integer representing the security protocol to be used when building the
4705      * {@link UaSecurityProtocolIdentifier} used when requesting GBA authentication.
4706      *
4707      * See the {@code UA_SECURITY_PROTOCOL_} constants in {@link UaSecurityProtocolIdentifier}.
4708      * @hide
4709      */
4710     @SystemApi
4711     public static final String KEY_GBA_UA_SECURITY_PROTOCOL_INT = "gba_ua_security_protocol_int";
4712 
4713     /**
4714      * An integer representing the cipher suite to be used when building the
4715      * {@link UaSecurityProtocolIdentifier} used when requesting GBA authentication.
4716      *
4717      * See the {@code TLS_} constants in {@link android.telephony.gba.TlsParams}.
4718      * @hide
4719      */
4720     @SystemApi
4721     public static final String KEY_GBA_UA_TLS_CIPHER_SUITE_INT = "gba_ua_tls_cipher_suite_int";
4722 
4723     /**
4724      * The data stall recovery timers array in milliseconds, each element is the delay before
4725      * performining next recovery action.
4726      *
4727      * The default value of timers array are: [180000ms, 180000ms, 180000ms, 180000ms] (3 minutes)
4728      * Array[0]: It's the timer between RECOVERY_ACTION GET_DATA_CALL_LIST and CLEANUP, if data
4729      * stall symptom still occurred, it will perform next recovery action after 180000ms.
4730      * Array[1]: It's the timer between RECOVERY_ACTION CLEANUP and RE-REGISTER, if data stall
4731      * symptom still occurred, it will perform next recovery action after 180000ms.
4732      * Array[2]: It's the timer between RECOVERY_ACTION RE-REGISTER and RADIO_RESTART, if data stall
4733      * symptom still occurred, it will perform next recovery action after 180000ms.
4734      * Array[3]: It's the timer between RECOVERY_ACTION RADIO_RESTART and RESET_MODEM, if data stall
4735      * symptom still occurred, it will perform next recovery action after 180000ms.
4736      *
4737      * See the {@code RECOVERY_ACTION_*} constants in
4738      * {@link com.android.internal.telephony.data.DataStallRecoveryManager}
4739      * @hide
4740      */
4741     public static final String KEY_DATA_STALL_RECOVERY_TIMERS_LONG_ARRAY =
4742             "data_stall_recovery_timers_long_array";
4743 
4744     /**
4745      * The data stall recovery action boolean array, we use this array to determine if the
4746      * data stall recovery action needs to be skipped.
4747      *
4748      * For example, if the carrier use the same APN for both of IA and default type,
4749      * the data call will not disconnect in modem side (so the RECOVERY_ACTION_CLEANUP
4750      * did not effect). In this case, we can config the boolean variable of action
4751      * RECOVERY_ACTION_CLEANUP to true, then it can be ignored to speed up the recovery
4752      * action procedure.
4753      *
4754      * The default value of boolean array are: [false, false, true, false, false]
4755      * Array[0]: When performing the recovery action, we can use this boolean value to determine
4756      * if we need to perform RECOVERY_ACTION_GET_DATA_CALL_LIST.
4757      * Array[1]: If data stall symptom still occurred, we can use this boolean value to determine
4758      * if we need to perform RECOVERY_ACTION_CLEANUP. For example, if the carrier use the same APN
4759      * for both of IA and default type, the data call will not disconnect in modem side
4760      * (so the RECOVERY_ACTION_CLEANUP did not effect). In this case, we can config the boolean
4761      * variable of action RECOVERY_ACTION_CLEANUP to true, then it can be ignored to speed up the
4762      * recovery action procedure.
4763      * Array[2]: If data stall symptom still occurred, we can use this boolean value to determine
4764      * if we need to perform RE-REGISTER.
4765      * Array[3]: If data stall symptom still occurred, we can use this boolean value to determine
4766      * if we need to perform RECOVERY_ACTION_RADIO_RESTART.
4767      * Array[4]: If data stall symptom still occurred, we can use this boolean value to determine
4768      * if we need to perform RECOVERY_ACTION_MODEM_RESET.
4769      *
4770      * See the {@code RECOVERY_ACTION_*} constants in
4771      * {@link com.android.internal.telephony.data.DataStallRecoveryManager}
4772      * @hide
4773      */
4774     public static final String KEY_DATA_STALL_RECOVERY_SHOULD_SKIP_BOOL_ARRAY =
4775             "data_stall_recovery_should_skip_bool_array";
4776 
4777     /**
4778      * String array containing the list of names for service numbers provided by carriers. This key
4779      * should be used with {@link #KEY_CARRIER_SERVICE_NUMBER_STRING_ARRAY}. The names provided in
4780      * this array will be mapped 1:1 with the numbers provided in the {@link
4781      * #KEY_CARRIER_SERVICE_NUMBER_STRING_ARRAY} array.
4782      *
4783      * <p>The data would be considered valid if and only if:
4784      *
4785      * <ul>
4786      *   <li>The number of items in both the arrays are equal
4787      *   <li>The data added to the {@link #KEY_CARRIER_SERVICE_NUMBER_STRING_ARRAY} array is valid.
4788      *       See {@link #KEY_CARRIER_SERVICE_NUMBER_STRING_ARRAY} for more information.
4789      * </ul>
4790      *
4791      * <p>Example:
4792      *
4793      * <pre>{@code
4794      * <string-array name="carrier_service_name_array" num="2">
4795      *   <item value="Police"/>
4796      *   <item value="Ambulance"/>
4797      * </string-array>
4798      * }</pre>
4799      */
4800     public static final String KEY_CARRIER_SERVICE_NAME_STRING_ARRAY = "carrier_service_name_array";
4801 
4802     /**
4803      * String array containing the list of service numbers provided by carriers. This key should be
4804      * used with {@link #KEY_CARRIER_SERVICE_NAME_STRING_ARRAY}. The numbers provided in this array
4805      * will be mapped 1:1 with the names provided in the {@link
4806      * #KEY_CARRIER_SERVICE_NAME_STRING_ARRAY} array.
4807      *
4808      * <p>The data would be considered valid if and only if:
4809      *
4810      * <ul>
4811      *   <li>The number of items in both the arrays are equal
4812      *   <li>The item should contain dialable characters only which includes 0-9, -, *, #, (, ),
4813      *       SPACE.
4814      * </ul>
4815      *
4816      * <p>Example:
4817      *
4818      * <pre>{@code
4819      * <string-array name="carrier_service_number_array" num="2">
4820      *   <item value="*123"/>
4821      *   <item value="+ (111) 111-111"/>
4822      * </string-array>
4823      * }</pre>
4824      */
4825     public static final String KEY_CARRIER_SERVICE_NUMBER_STRING_ARRAY =
4826         "carrier_service_number_array";
4827 
4828     /**
4829      * Configs used by ImsServiceEntitlement.
4830      */
4831     public static final class ImsServiceEntitlement {
ImsServiceEntitlement()4832         private ImsServiceEntitlement() {}
4833 
4834         /** Prefix of all ImsServiceEntitlement.KEY_* constants. */
4835         public static final String KEY_PREFIX = "imsserviceentitlement.";
4836 
4837         /**
4838          * The address of the entitlement configuration server.
4839          *
4840          * Reference: GSMA TS.43-v5, section 2.1 Default Entitlement Configuration Server.
4841          */
4842         public static final String KEY_ENTITLEMENT_SERVER_URL_STRING =
4843                 KEY_PREFIX + "entitlement_server_url_string";
4844 
4845         /**
4846          * For some carriers, end-users may be presented with a web portal of the carrier before
4847          * being allowed to use the VoWiFi service.
4848          * To support this feature, the app hosts a {@link android.webkit.WebView} in the foreground
4849          * VoWiFi entitlement configuration flow to show the web portal.
4850          *
4851          * {@code true} - show the VoWiFi portal in a webview.
4852          *
4853          * Note: this is effective only if the {@link #KEY_WFC_EMERGENCY_ADDRESS_CARRIER_APP_STRING}
4854          * is set to this app.
4855          *
4856          * Reference: GSMA TS.43-v5, section 3, VoWiFi entitlement configuration.
4857          */
4858         public static final String KEY_SHOW_VOWIFI_WEBVIEW_BOOL =
4859                 KEY_PREFIX + "show_vowifi_webview_bool";
4860 
4861         /**
4862          * For some carriers, the network is not provisioned by default to support
4863          * IMS (VoLTE/VoWiFi/SMSoIP) service for all end users. Some type of network-side
4864          * provisioning must then take place before offering the IMS service to the end-user.
4865          *
4866          * {@code true} - need this ImsServiceEntitlement app to do IMS (VoLTE/VoWiFi/SMSoIP)
4867          * provisioning in the background before offering the IMS service to the end-user.
4868          *
4869          * Note: this is effective only if the carrier needs IMS provisioning, i.e.
4870          * {@link #KEY_CARRIER_VOLTE_PROVISIONING_REQUIRED_BOOL} is set to true.
4871          *
4872          * Reference: GSMA TS.43-v5, section 3 - 5, VoWiFi/VoLTE/SMSoIP entitlement configuration.
4873          */
4874         public static final String KEY_IMS_PROVISIONING_BOOL = KEY_PREFIX + "ims_provisioning_bool";
4875 
4876         /**
4877          * The FCM sender ID for the carrier.
4878          * Used to trigger a carrier network requested entitlement configuration
4879          * via Firebase Cloud Messaging (FCM). Do not set if the carrier doesn't use FCM for network
4880          * requested entitlement configuration.
4881          *
4882          * Reference: GSMA TS.43-v5, section 2.4, Network Requested Entitlement Configuration.
4883          *
4884          * @see <a href="https://firebase.google.com/docs/cloud-messaging/concept-options#senderid">
4885          *     About FCM messages - Credentials</a>
4886          */
4887         public static final String KEY_FCM_SENDER_ID_STRING = KEY_PREFIX + "fcm_sender_id_string";
4888 
4889         /**
4890          * Indicates the supported protocol version in the parameter entitlement_version.
4891          * The default value is 2. The possible value is 2 and 8.
4892          *
4893          * Reference: GSMA TS.43-v8 section 2.5 Protocol version control and
4894          * Table 3. GET Parameters for Entitlement Configuration in section 2.3
4895          * HTTP GET method Parameters.
4896          * @hide
4897          */
4898         public static final String KEY_ENTITLEMENT_VERSION_INT =
4899                 KEY_PREFIX + "entitlement_version_int";
4900 
4901         /**
4902          * Controls the service entitlement status when receiving the VERS characteristic
4903          * with both version and validity set to -1 or -2.
4904          * If {@code true}, default service entitlement status is enabled.
4905          * If {@code false}, default service entitlement status is disabled.
4906          *
4907          * Reference: GSMA TS.14-v8 section 2.1, overview
4908          * @hide
4909          */
4910         public static final String KEY_DEFAULT_SERVICE_ENTITLEMENT_STATUS_BOOL =
4911                 KEY_PREFIX + "default_service_entitlement_status_bool";
4912 
4913         /**
4914          * Indicates if UE can skip service entitlement check when the user turns on Wi-Fi Calling.
4915          * UE still shows Wi-Fi Calling emergency address update web view when the user clicks
4916          * "Update Emergency Address" on the WiFi calling setting.
4917          *
4918          * Note: this is effective only if the {@link #KEY_WFC_EMERGENCY_ADDRESS_CARRIER_APP_STRING}
4919          * is set to this app.
4920          * @hide
4921          */
4922         public static final String KEY_SKIP_WFC_ACTIVATION_BOOL =
4923                 KEY_PREFIX + "skip_wfc_activation_bool";
4924 
getDefaults()4925         private static PersistableBundle getDefaults() {
4926             PersistableBundle defaults = new PersistableBundle();
4927             defaults.putString(KEY_ENTITLEMENT_SERVER_URL_STRING, "");
4928             defaults.putString(KEY_FCM_SENDER_ID_STRING, "");
4929             defaults.putBoolean(KEY_SHOW_VOWIFI_WEBVIEW_BOOL, false);
4930             defaults.putBoolean(KEY_IMS_PROVISIONING_BOOL, false);
4931             defaults.putBoolean(KEY_DEFAULT_SERVICE_ENTITLEMENT_STATUS_BOOL, false);
4932             defaults.putBoolean(KEY_SKIP_WFC_ACTIVATION_BOOL, false);
4933             defaults.putInt(KEY_ENTITLEMENT_VERSION_INT, 2);
4934             return defaults;
4935         }
4936     }
4937 
4938     /**
4939      * GPS configs. See the GNSS HAL documentation for more details.
4940      */
4941     public static final class Gps {
Gps()4942         private Gps() {}
4943 
4944         /** Prefix of all Gps.KEY_* constants. */
4945         public static final String KEY_PREFIX = "gps.";
4946 
4947         /**
4948          * Location information during (and after) an emergency call is only provided over control
4949          * plane signaling from the network.
4950          * @hide
4951          */
4952         public static final int SUPL_EMERGENCY_MODE_TYPE_CP_ONLY = 0;
4953 
4954         /**
4955          * Location information during (and after) an emergency call is provided over the data
4956          * plane and serviced by the framework GNSS service, but if it fails, the carrier also
4957          * supports control plane backup signaling.
4958          * @hide
4959          */
4960         public static final int SUPL_EMERGENCY_MODE_TYPE_CP_FALLBACK = 1;
4961 
4962         /**
4963          * Location information during (and after) an emergency call is provided over the data plane
4964          * and serviced by the framework GNSS service only. There is no backup signalling over the
4965          * control plane if it fails.
4966          * @hide
4967          */
4968         public static final int SUPL_EMERGENCY_MODE_TYPE_DP_ONLY = 2;
4969 
4970         /**
4971          * Determine whether current lpp_mode used for E-911 needs to be kept persistently.
4972          * {@code false} - not keeping the lpp_mode means using default configuration of gps.conf
4973          *                 when sim is not presented.
4974          * {@code true}  - current lpp_profile of carrier will be kepted persistently
4975          *                 even after sim is removed. This is default.
4976          */
4977         public static final String KEY_PERSIST_LPP_MODE_BOOL = KEY_PREFIX + "persist_lpp_mode_bool";
4978 
4979         /**
4980          * SUPL server host for SET Initiated & non-ES Network-Initiated SUPL requests.
4981          * Default to supl.google.com
4982          * @hide
4983          */
4984         public static final String KEY_SUPL_HOST_STRING = KEY_PREFIX + "supl_host";
4985 
4986         /**
4987          * SUPL server port. Default to 7275.
4988          * @hide
4989          */
4990         public static final String KEY_SUPL_PORT_STRING = KEY_PREFIX + "supl_port";
4991 
4992         /**
4993          * The SUPL version requested by Carrier. This is a bit mask
4994          * with bits 0:7 representing a service indicator field, bits 8:15
4995          * representing the minor version and bits 16:23 representing the
4996          * major version. Default to 0x20000.
4997          * @hide
4998          */
4999         public static final String KEY_SUPL_VER_STRING = KEY_PREFIX + "supl_ver";
5000 
5001         /**
5002          * SUPL_MODE configuration bit mask
5003          * 1 - Mobile Station Based. This is default.
5004          * 2 - Mobile Station Assisted.
5005          * @hide
5006          */
5007         public static final String KEY_SUPL_MODE_STRING = KEY_PREFIX + "supl_mode";
5008 
5009         /**
5010          * Whether to limit responses to SUPL ES mode requests only during user emergency sessions
5011          * (e.g. E911), and SUPL non-ES requests to only outside of non user emergency sessions.
5012          * 0 - no.
5013          * 1 - yes. This is default.
5014          * @hide
5015          */
5016         public static final String KEY_SUPL_ES_STRING = KEY_PREFIX + "supl_es";
5017 
5018         /**
5019          * LTE Positioning Profile settings bit mask.
5020          * 0 - Radio Resource Location Protocol in user plane and control plane. This is default.
5021          * 1 - Enable LTE Positioning Protocol in user plane.
5022          * 2 - Enable LTE Positioning Protocol in control plane.
5023          * @hide
5024          */
5025         public static final String KEY_LPP_PROFILE_STRING = KEY_PREFIX + "lpp_profile";
5026 
5027         /**
5028          * Determine whether to use emergency PDN for emergency SUPL.
5029          * 0 - no.
5030          * 1 - yes. This is default.
5031          * @hide
5032          */
5033         public static final String KEY_USE_EMERGENCY_PDN_FOR_EMERGENCY_SUPL_STRING =
5034                 KEY_PREFIX + "use_emergency_pdn_for_emergency_supl";
5035 
5036         /**
5037          * A_GLONASS_POS_PROTOCOL_SELECT bit mask.
5038          * 0 - Don't use A-GLONASS. This is default.
5039          * 1 - Use A-GLONASS in Radio Resource Control(RRC) control-plane.
5040          * 2 - Use A-GLONASS in Radio Resource Location user-plane.
5041          * 4 - Use A-GLONASS in LTE Positioning Protocol User plane.
5042          * @hide
5043          */
5044         public static final String KEY_A_GLONASS_POS_PROTOCOL_SELECT_STRING =
5045                 KEY_PREFIX + "a_glonass_pos_protocol_select";
5046 
5047         /**
5048          * GPS_LOCK configuration bit mask to specify GPS device behavior toward other services,
5049          * when Location Settings are off.
5050          * "0" - No lock.
5051          * "1" - Lock Mobile Originated GPS functionalities.
5052          * "2" - Lock Network initiated GPS functionalities.
5053          * "3" - Lock both. This is default.
5054          * @hide
5055          */
5056         public static final String KEY_GPS_LOCK_STRING = KEY_PREFIX + "gps_lock";
5057 
5058         /**
5059          * Control Plane / SUPL NI emergency extension time in seconds. Default to "0".
5060          * @hide
5061          */
5062         public static final String KEY_ES_EXTENSION_SEC_STRING = KEY_PREFIX + "es_extension_sec";
5063 
5064         /**
5065          * Space separated list of Android package names of proxy applications representing
5066          * the non-framework entities requesting location directly from GNSS without involving
5067          * the framework, as managed by IGnssVisibilityControl.hal. For example,
5068          * "com.example.mdt com.example.ims".
5069          * @hide
5070          */
5071         public static final String KEY_NFW_PROXY_APPS_STRING = KEY_PREFIX + "nfw_proxy_apps";
5072 
5073         /**
5074          * Determines whether or not SUPL ES mode supports a control-plane mechanism to get a user's
5075          * location in the event that data plane SUPL fails or is otherwise unavailable.
5076          * <p>
5077          * An integer value determines the support type of this carrier. If this carrier only
5078          * supports data plane SUPL ES, then the value will be
5079          * {@link #SUPL_EMERGENCY_MODE_TYPE_DP_ONLY}. If the carrier supports control plane fallback
5080          * for emergency SUPL, the value will be {@link #SUPL_EMERGENCY_MODE_TYPE_CP_FALLBACK}.
5081          * If the carrier does not support data plane SUPL using the framework, the value will be
5082          * {@link #SUPL_EMERGENCY_MODE_TYPE_CP_ONLY}.
5083          * <p>
5084          * The default value for this configuration is {@link #SUPL_EMERGENCY_MODE_TYPE_CP_ONLY}.
5085          * @hide
5086          */
5087         public static final String KEY_ES_SUPL_CONTROL_PLANE_SUPPORT_INT =
5088                 KEY_PREFIX + "es_supl_control_plane_support_int";
5089 
5090         /**
5091          * A list of roaming PLMNs where SUPL ES mode does not support a control-plane mechanism to
5092          * get a user's location in the event that data plane SUPL fails or is otherwise
5093          * unavailable.
5094          * <p>
5095          * A string array of PLMNs that do not support a control-plane mechanism for getting a
5096          * user's location for SUPL ES.
5097          * @hide
5098          */
5099         public static final String KEY_ES_SUPL_DATA_PLANE_ONLY_ROAMING_PLMN_STRING_ARRAY =
5100                 KEY_PREFIX + "es_supl_data_plane_only_roaming_plmn_string_array";
5101 
5102         /**
5103          * Determine whether to enable Net Initiated SUPL (NI SUPL) message injection.
5104          * If enabled, the GnssLocationProvider will monitor for WAP PUSH or MT SMS NI SUPL intents
5105          * and subsequently inject the NI SUPL packet into the GNSS HAL.
5106          * {@code false} - Disable NI SUPL message injection. This is default.
5107          * {@code true} - Enable NI SUPL message injection.
5108          */
5109         @FlaggedApi(android.location.flags.Flags
5110                 .FLAG_ENABLE_NI_SUPL_MESSAGE_INJECTION_BY_CARRIER_CONFIG_BUGFIX)
5111         public static final String KEY_ENABLE_NI_SUPL_MESSAGE_INJECTION_BOOL =
5112                 KEY_PREFIX + "enable_ni_supl_message_injection_bool";
5113 
getDefaults()5114         private static PersistableBundle getDefaults() {
5115             PersistableBundle defaults = new PersistableBundle();
5116             defaults.putBoolean(KEY_PERSIST_LPP_MODE_BOOL, true);
5117             defaults.putString(KEY_SUPL_HOST_STRING, "supl.google.com");
5118             defaults.putString(KEY_SUPL_PORT_STRING, "7275");
5119             defaults.putString(KEY_SUPL_VER_STRING, "0x20000");
5120             defaults.putString(KEY_SUPL_MODE_STRING, "1");
5121             defaults.putString(KEY_SUPL_ES_STRING, "1");
5122             defaults.putString(KEY_LPP_PROFILE_STRING, "2");
5123             defaults.putString(KEY_USE_EMERGENCY_PDN_FOR_EMERGENCY_SUPL_STRING, "1");
5124             defaults.putString(KEY_A_GLONASS_POS_PROTOCOL_SELECT_STRING, "0");
5125             defaults.putString(KEY_GPS_LOCK_STRING, "3");
5126             defaults.putString(KEY_ES_EXTENSION_SEC_STRING, "0");
5127             defaults.putString(KEY_NFW_PROXY_APPS_STRING, "");
5128             defaults.putInt(KEY_ES_SUPL_CONTROL_PLANE_SUPPORT_INT,
5129                     SUPL_EMERGENCY_MODE_TYPE_CP_ONLY);
5130             defaults.putStringArray(KEY_ES_SUPL_DATA_PLANE_ONLY_ROAMING_PLMN_STRING_ARRAY, null);
5131             if (android.location.flags.Flags.enableNiSuplMessageInjectionByCarrierConfigBugfix()) {
5132                 defaults.putBoolean(KEY_ENABLE_NI_SUPL_MESSAGE_INJECTION_BOOL, false);
5133             }
5134             return defaults;
5135         }
5136     }
5137 
5138     /**
5139      * An int array containing CDMA enhanced roaming indicator values for Home (non-roaming)
5140      * network.
5141      * The default values come from 3GPP2 C.R1001 table 8.1-1.
5142      * Enhanced Roaming Indicator Number Assignments
5143      *
5144      * @deprecated Legacy CDMA is unsupported.
5145      * @hide
5146      */
5147     @Deprecated
5148     public static final String KEY_CDMA_ENHANCED_ROAMING_INDICATOR_FOR_HOME_NETWORK_INT_ARRAY =
5149             "cdma_enhanced_roaming_indicator_for_home_network_int_array";
5150 
5151     /**
5152      * Determines whether wifi calling location privacy policy is shown.
5153      */
5154     public static final String KEY_SHOW_WFC_LOCATION_PRIVACY_POLICY_BOOL =
5155             "show_wfc_location_privacy_policy_bool";
5156 
5157     /**
5158      * Indicates use 3GPP application to replace 3GPP2 application even if it's a CDMA/CDMA-LTE
5159      * phone, because some carriers' CSIM application is present but not supported.
5160      * @hide
5161      */
5162     public static final String KEY_USE_USIM_BOOL = "use_usim_bool";
5163 
5164     /**
5165      * Determines whether the carrier wants to cancel the cs reject notification automatically
5166      * when the voice registration state changes.
5167      * If true, the notification will be automatically removed
5168      *          when the voice registration state changes.
5169      * If false, the notification will persist until the user dismisses it,
5170      *           the SIM is removed, or the device is rebooted.
5171      * @hide
5172      */
5173     public static final String KEY_AUTO_CANCEL_CS_REJECT_NOTIFICATION =
5174             "carrier_auto_cancel_cs_notification";
5175 
5176     /**
5177      * Passing this value as {@link #KEY_SUBSCRIPTION_GROUP_UUID_STRING} will remove the
5178      * subscription from a group instead of adding it to a group.
5179      *
5180      * <p>This value will work all the way back to {@link android.os.Build.VERSION_CODES#Q}.
5181      */
5182     public static final String REMOVE_GROUP_UUID_STRING = "00000000-0000-0000-0000-000000000000";
5183 
5184     /**
5185      * The UUID of a Group of related subscriptions in which to place the current subscription.
5186      *
5187      * A grouped subscription will behave for billing purposes and other UI purposes as though it
5188      * is a transparent extension of other subscriptions in the group.
5189      *
5190      * <p>If set to {@link #REMOVE_GROUP_UUID_STRING}, then the subscription will be removed from
5191      * its current group.
5192      *
5193      * <p>This key will work all the way back to {@link android.os.Build.VERSION_CODES#Q}.
5194      */
5195     public static final String KEY_SUBSCRIPTION_GROUP_UUID_STRING =
5196             "subscription_group_uuid_string";
5197 
5198     /**
5199      * Controls the cellular usage setting.
5200      *
5201      * The usage setting indicates whether a device will remain attached to a network based on
5202      * the primary use case for the service. A device will detach and search for a more-preferred
5203      * network if the primary use case (voice or data) is not satisfied. Depending on the type
5204      * of device, it may operate in a voice or data-centric mode by default.
5205      *
5206      * <p>Sets the usage setting in accordance with 3gpp 24.301 sec 4.3 and 3gpp 24.501 sec 4.3.
5207      * Also refer to "UE's usage setting" as defined in 3gpp 24.301 section 3.1 and 3gpp 23.221
5208      * Annex A.
5209      *
5210      * Either omit this key or pass a value of
5211      * {@link SubscriptionManager#USAGE_SETTING_UNKNOWN unknown} to preserve the current setting.
5212      *
5213      * <p>Devices that support configuration of the cellular usage setting, including devices
5214      * with HAL capability to set the cellular usage setting, must honor this setting accordingly.
5215      *
5216      * {@link SubscriptionManager#USAGE_SETTING_DEFAULT default},
5217      * {@link SubscriptionManager#USAGE_SETTING_VOICE_CENTRIC voice-centric},
5218      * or {@link SubscriptionManager#USAGE_SETTING_DATA_CENTRIC data-centric}.
5219      * {@see SubscriptionInfo#getUsageSetting}
5220      *
5221      */
5222     public static final String KEY_CELLULAR_USAGE_SETTING_INT = "cellular_usage_setting_int";
5223 
5224     /**
5225      * Data switch validation minimal gap time, in milliseconds.
5226      *
5227      * Which means, if the same subscription on the same network (based on MCC+MNC+TAC+subId)
5228      * was recently validated (within this time gap), and Telephony receives a request to switch to
5229      * it again, Telephony will skip the validation part and switch to it as soon as connection
5230      * is setup, as if it's already validated.
5231      *
5232      * If the network was validated within the gap but the latest validation result is false, the
5233      * validation will not be skipped.
5234      *
5235      * If not set or set to 0, validation will never be skipped.
5236      * The max acceptable value of this config is 24 hours.
5237      *
5238      * @hide
5239      * @deprecated Use {@link #KEY_DATA_SWITCH_VALIDATION_MIN_INTERVAL_MILLIS_LONG} instead.
5240      */
5241     @Deprecated
5242     public static final String KEY_DATA_SWITCH_VALIDATION_MIN_GAP_LONG =
5243             "data_switch_validation_min_gap_long";
5244 
5245     /**
5246      * Data switch validation minimal interval, in milliseconds.
5247      *
5248      * If a connection to the default (Internet) PDN for the current subscription is validated on
5249      * a given operator within a given tracking area, re-validations to that matching operator will
5250      * be skipped if they would occur within the specified interval. Instead, the connection will
5251      * automatically considered validated.
5252      *
5253      * If the network was validated within the interval but the latest validation result was false,
5254      * the validation will not be skipped. If not set or set to 0, validation will not be skipped.
5255      *
5256      * The valid range of value is between 0 millisecond and 24 hours, inclusive in both sides. The
5257      * default value is 24 hours.
5258      *
5259      * @see android.net.NetworkCapabilities#NET_CAPABILITY_VALIDATED
5260      */
5261     public static final String KEY_DATA_SWITCH_VALIDATION_MIN_INTERVAL_MILLIS_LONG =
5262             KEY_DATA_SWITCH_VALIDATION_MIN_GAP_LONG;
5263 
5264     /**
5265      * A boolean property indicating whether this subscription should be managed as an opportunistic
5266      * subscription.
5267      *
5268      * If true, then this subscription will be selected based on available coverage and will not be
5269      * available for a user in settings menus for selecting macro network providers. If unset,
5270      * defaults to “false”.
5271      *
5272      * <p>This key will work all the way back to {@link android.os.Build.VERSION_CODES#Q}.
5273      */
5274     public static final String KEY_IS_OPPORTUNISTIC_SUBSCRIPTION_BOOL =
5275             "is_opportunistic_subscription_bool";
5276 
5277     /**
5278      * The flatten string {@link android.content.ComponentName componentName} of carrier
5279      * provisioning app receiver.
5280      *
5281      * <p>
5282      * The RadioInfo activity(*#*#INFO#*#*) will broadcast an intent to this receiver when the
5283      * "Carrier Provisioning Info" or "Trigger Carrier Provisioning" button clicked.
5284      *
5285      * <p>
5286      * e.g., com.google.android.carrierPackageName/.CarrierReceiverName
5287      *
5288      * @hide
5289      */
5290     public static final String KEY_CARRIER_PROVISIONING_APP_STRING =
5291             "carrier_provisioning_app_string";
5292 
5293     /**
5294      * Configs used by the IMS stack.
5295      */
5296     public static final class Ims {
5297         /** Prefix of all Ims.KEY_* constants. */
5298         public static final String KEY_PREFIX = "ims.";
5299 
5300         /**
5301          * Delay in milliseconds to turn off wifi when IMS is registered over wifi.
5302          */
5303         public static final String KEY_WIFI_OFF_DEFERRING_TIME_MILLIS_INT =
5304                 KEY_PREFIX + "wifi_off_deferring_time_millis_int";
5305 
5306         /**
5307          * A boolean flag specifying whether or not this carrier requires one IMS registration for
5308          * all IMS services (MMTEL and RCS).
5309          * <p>
5310          * If set to {@code true}, the IMS Service must use one IMS registration for all IMS
5311          * services. If set to {@code false}, IMS services may use separate IMS registrations for
5312          * MMTEL and RCS.
5313          * <p>
5314          * The default value for this configuration is {@code false}.
5315          */
5316         public static final String KEY_IMS_SINGLE_REGISTRATION_REQUIRED_BOOL =
5317                 KEY_PREFIX + "ims_single_registration_required_bool";
5318 
5319         /**
5320          * A boolean flag specifying whether or not this carrier supports the device notifying the
5321          * network of its RCS capabilities using the SIP PUBLISH procedure defined for User
5322          * Capability Exchange (UCE). See RCC.71, section 3 for more information.
5323          * <p>
5324          * If this key's value is set to false, the procedure for RCS contact capability exchange
5325          * via SIP SUBSCRIBE/NOTIFY will also be disabled internally, and this key must also be set
5326          * to false to ensure apps do not improperly think that capability exchange via SIP PUBLISH
5327          * is enabled.
5328          * <p> The default value for this key is {@code false}.
5329          */
5330         public static final String KEY_ENABLE_PRESENCE_PUBLISH_BOOL =
5331                 KEY_PREFIX + "enable_presence_publish_bool";
5332 
5333         /**
5334          * Each string in this array contains a mapping between the service-id and version portion
5335          * of the service-description element and the associated IMS feature tag(s) that are
5336          * associated with each element (see RCC.07 Table 7).
5337          * <p>
5338          * Each string contains 3 parts, which define the mapping between service-description and
5339          * feature tag(s) that must be present in the IMS REGISTER for the RCS service to be
5340          * published as part of the RCS PUBLISH procedure:
5341          * [service-id]|[version]|[desc]|[feature_tag];[feature_tag];...
5342          * <ul>
5343          *   <li>[service-id]: the service-id element associated with the RCS capability.</li>
5344          *   <li>[version]: The version element associated with that service-id</li>
5345          *   <li>[desc]: The optional desecription element associated with that service-id</li>
5346          *   <li>[feature_tag];[feature_tag]: The list of all feature tags associated with this
5347          *       capability that MUST ALL be present in the IMS registration for this this
5348          *       capability to be published to the network.</li>
5349          * </ul>
5350          * <p>
5351          * Features managed by the framework will be considered capable when the ImsService reports
5352          * that those services are capable via the
5353          * {@link MmTelFeature#notifyCapabilitiesStatusChanged(MmTelFeature.MmTelCapabilities)} or
5354          * {@link RcsFeature#notifyCapabilitiesStatusChanged(RcsFeature.RcsImsCapabilities)} APIs.
5355          * For RCS services not managed by the framework, the capability of these services are
5356          * determined by looking at the feature tags associated with the IMS registration using the
5357          * {@link ImsRegistrationAttributes} API and mapping them to the service-description map.
5358          * <p>
5359          * The framework contains a default value of this key, which is based off of RCC.07
5360          * specification. Capabilities based of carrier extensions may be added to this list on a
5361          * carrier-by-carrier basis as required in order to support additional services in the
5362          * PUBLISH. If this list contains a service-id and version that overlaps with the default,
5363          * it will override the framework default.
5364          * @hide
5365          */
5366         public static final String KEY_PUBLISH_SERVICE_DESC_FEATURE_TAG_MAP_OVERRIDE_STRING_ARRAY =
5367                 KEY_PREFIX + "publish_service_desc_feature_tag_map_override_string_array";
5368 
5369         /**
5370          * Flag indicating whether or not this carrier supports the exchange of phone numbers with
5371          * the carrier's RCS presence server in order to retrieve the RCS capabilities of requested
5372          * contacts used in the RCS User Capability Exchange (UCE) procedure. See RCC.71, section 3
5373          * for more information.
5374          * <p>
5375          * When presence is supported, the device uses the SIP SUBSCRIBE/NOTIFY procedure internally
5376          * to retrieve the requested RCS capabilities. See
5377          * {@link android.telephony.ims.RcsUceAdapter} for more information on how RCS capabilities
5378          * can be retrieved from the carrier's network.
5379          */
5380         public static final String KEY_ENABLE_PRESENCE_CAPABILITY_EXCHANGE_BOOL =
5381                 KEY_PREFIX + "enable_presence_capability_exchange_bool";
5382 
5383         /**
5384          * Flag indicating whether or not the carrier expects the RCS UCE service to periodically
5385          * refresh the RCS capabilities cache of the user's contacts as well as request the
5386          * capabilities of call contacts when the SIM card is first inserted or when a new contact
5387          * is added, removed, or modified. This corresponds to the RCC.07 A.19
5388          * "DISABLE INITIAL ADDRESS BOOK SCAN" parameter.
5389          * <p>
5390          * If this flag is disabled, the capabilities cache will not be refreshed internally at all
5391          * and will only be updated if the cached capabilities are stale when an application
5392          * requests them.
5393          *
5394          * @see RcsUceAdapter#isUceSettingEnabled() more information about this feature and how
5395          * it is enabled by the user.
5396          */
5397         public static final String KEY_RCS_BULK_CAPABILITY_EXCHANGE_BOOL =
5398                 KEY_PREFIX + "rcs_bulk_capability_exchange_bool";
5399 
5400         /**
5401          * Flag indicating whether or not the carrier supports capability exchange with a list of
5402          * contacts. When {@code true}, the device will batch together multiple requests and
5403          * construct a RLMI document in the SIP SUBSCRIBE request (see RFC 4662). If {@code false},
5404          * the request will be split up into one SIP SUBSCRIBE request per contact.
5405          */
5406         public static final String KEY_ENABLE_PRESENCE_GROUP_SUBSCRIBE_BOOL =
5407                 KEY_PREFIX + "enable_presence_group_subscribe_bool";
5408 
5409         /**
5410          * SIP SUBSCRIBE retry duration used when device doesn't receive a response to SIP
5411          * SUBSCRIBE request.
5412          * If this value is not defined or defined as negative value, the device does not retry
5413          * the SIP SUBSCRIBE.
5414          * If the value is 0 then device retries immediately upon timeout.
5415          * If the value is > 0 then device waits for configured duration and retries after timeout
5416          * is detected
5417          * @hide
5418          */
5419         public static final String KEY_SUBSCRIBE_RETRY_DURATION_MILLIS_LONG =
5420                 KEY_PREFIX + "subscribe_retry_duration_millis_long";
5421 
5422         /**
5423          * Flag indicating whether or not to use SIP URI when send a presence subscribe.
5424          * When {@code true}, the device sets the To and Contact header to be SIP URI using
5425          * the TelephonyManager#getIsimDomain" API.
5426          * If {@code false}, the device uses a TEL URI.
5427          */
5428         public static final String KEY_USE_SIP_URI_FOR_PRESENCE_SUBSCRIBE_BOOL =
5429                 KEY_PREFIX + "use_sip_uri_for_presence_subscribe_bool";
5430 
5431         /**
5432          * Flag indicating whether or not to use TEL URI when setting the entity uri field and
5433          * contact element of each tuple.
5434          *
5435          * When {@code true}, the device sets the entity uri field and contact element to be
5436          * TEL URI. This is done by first searching for the first TEL URI provided in
5437          * p-associated-uri header. If there are no TEL URIs in the p-associated-uri header, we will
5438          * convert the first SIP URI provided in the header to a TEL URI. If there are no URIs in
5439          * the p-associated-uri header, we will then fall back to using the SIM card to generate the
5440          * TEL URI.
5441          * If {@code false}, the first URI provided in the p-associated-uri header is used,
5442          * independent of the URI scheme. If there are no URIs available from p-associated-uri
5443          * header, we will try to generate a SIP URI or TEL URI from the information provided by the
5444          * SIM card, depending on the information available.
5445          * @hide
5446          */
5447         public static final String KEY_USE_TEL_URI_FOR_PIDF_XML_BOOL =
5448                 KEY_PREFIX + "use_tel_uri_for_pidf_xml";
5449 
5450         /**
5451          * An integer key associated with the period of time in seconds the non-rcs capability
5452          * information of each contact is cached on the device.
5453          * <p>
5454          * The rcs capability cache expiration sec is managed by
5455          * {@code android.telephony.ims.ProvisioningManager} but non-rcs capability is managed by
5456          * {@link CarrierConfigManager} since non-rcs capability will be provided via ACS or carrier
5457          * config.
5458          * <p>
5459          * The default value is 2592000 secs (30 days), see RCC.07 Annex A.1.9.
5460          */
5461         public static final String KEY_NON_RCS_CAPABILITIES_CACHE_EXPIRATION_SEC_INT =
5462                 KEY_PREFIX + "non_rcs_capabilities_cache_expiration_sec_int";
5463 
5464         /**
5465          * Specifies the RCS feature tag allowed for the carrier.
5466          *
5467          * <p>The values refer to RCC.07 2.4.4.
5468          */
5469         public static final String KEY_RCS_FEATURE_TAG_ALLOWED_STRING_ARRAY =
5470                 KEY_PREFIX + "rcs_feature_tag_allowed_string_array";
5471 
5472         /**
5473          * Flag indicating whether or not carrier forbids device send the RCS request when the
5474          * device receive the network response with the SIP code 489 BAD EVENT.
5475          * <p>
5476          * The default value for this key is {@code false}.
5477          * @hide
5478          */
5479         public static final String KEY_RCS_REQUEST_FORBIDDEN_BY_SIP_489_BOOL =
5480                 KEY_PREFIX + "rcs_request_forbidden_by_sip_489_bool";
5481 
5482         /**
5483          * Indicates the interval that SUBSCRIBE requests from applications will be retried at when
5484          * the carrier network has responded to a previous request with a forbidden error.
5485          * <p>
5486          * The default value for this key is 20 minutes.
5487          * @hide
5488          */
5489         public static final String KEY_RCS_REQUEST_RETRY_INTERVAL_MILLIS_LONG =
5490                 KEY_PREFIX + "rcs_request_retry_interval_millis_long";
5491 
5492         /** SIP timer T1 as per 3GPP TS 24.229 Table 7.7.1 */
5493         public static final String KEY_SIP_TIMER_T1_MILLIS_INT =
5494                 KEY_PREFIX + "sip_timer_t1_millis_int";
5495 
5496         /** SIP timer T2 as per 3GPP TS 24.229 Table 7.7.1 */
5497         public static final String KEY_SIP_TIMER_T2_MILLIS_INT =
5498                 KEY_PREFIX + "sip_timer_t2_millis_int";
5499 
5500         /** SIP timer T4 as per 3GPP TS 24.229 Table 7.7.1 */
5501         public static final String KEY_SIP_TIMER_T4_MILLIS_INT =
5502                 KEY_PREFIX + "sip_timer_t4_millis_int";
5503 
5504         /** SIP timer B as per 3GPP TS 24.229 Table 7.7.1 */
5505         public static final String KEY_SIP_TIMER_B_MILLIS_INT =
5506                 KEY_PREFIX + "sip_timer_b_millis_int";
5507 
5508         /** SIP timer C as per 3GPP TS 24.229 Table 7.7.1 */
5509         public static final String KEY_SIP_TIMER_C_MILLIS_INT =
5510                 KEY_PREFIX + "sip_timer_c_millis_int";
5511 
5512         /** SIP timer D as per 3GPP TS 24.229 Table 7.7.1 */
5513         public static final String KEY_SIP_TIMER_D_MILLIS_INT =
5514                 KEY_PREFIX + "sip_timer_d_millis_int";
5515 
5516         /** SIP timer F as per 3GPP TS 24.229 Table 7.7.1 */
5517         public static final String KEY_SIP_TIMER_F_MILLIS_INT =
5518                 KEY_PREFIX + "sip_timer_f_millis_int";
5519 
5520         /** SIP timer H as per 3GPP TS 24.229 Table 7.7.1 */
5521         public static final String KEY_SIP_TIMER_H_MILLIS_INT =
5522                 KEY_PREFIX + "sip_timer_h_millis_int";
5523 
5524         /** SIP timer J as per 3GPP TS 24.229 Table 7.7.1 */
5525         public static final String KEY_SIP_TIMER_J_MILLIS_INT =
5526                 KEY_PREFIX + "sip_timer_j_millis_int";
5527 
5528         /** Specifies the SIP Server default port. */
5529         public static final String KEY_SIP_SERVER_PORT_NUMBER_INT =
5530                 KEY_PREFIX + "sip_server_port_number_int";
5531 
5532         /**
5533          * Specify the “phone-context” parameter as defined in
5534          * section 7.2A.10 in 3GPP TS 24.229.
5535          */
5536         public static final String KEY_PHONE_CONTEXT_DOMAIN_NAME_STRING =
5537                 KEY_PREFIX + "phone_context_domain_name_string";
5538 
5539         /** @hide */
5540         @IntDef({REQUEST_URI_FORMAT_TEL, REQUEST_URI_FORMAT_SIP})
5541         public @interface RequestUriFormatType {}
5542 
5543         /**
5544          *  Request URI is of type TEL URI.
5545          */
5546         public static final int REQUEST_URI_FORMAT_TEL = 0;
5547 
5548         /**
5549          *  Request URI is of type SIP URI.
5550          */
5551         public static final int REQUEST_URI_FORMAT_SIP = 1;
5552 
5553         /**
5554          * Specify whether the request URI is SIP URI
5555          * {@link #REQUEST_URI_FORMAT_SIP} or
5556          * TEL URI {@link #REQUEST_URI_FORMAT_TEL}.
5557          */
5558         public static final String KEY_REQUEST_URI_TYPE_INT =
5559                 KEY_PREFIX + "request_uri_type_int";
5560 
5561         /**
5562          * Flag indicating whether Globally Routable User agent (GRUU)
5563          * in supported HEADER is included or not.
5564          *
5565          * <p> Reference: RFC 5627.
5566          */
5567         public static final String KEY_GRUU_ENABLED_BOOL =
5568                 KEY_PREFIX + "gruu_enabled_bool";
5569 
5570         /**
5571          * Flag indicating whether to keep/release IMS PDN in case of
5572          * moving to non VOPS area.
5573          *
5574          * <p>if {@code True}, keep IMS PDN in case of moving to non VOPS area.
5575          * if {@code false}, otherwise.
5576          */
5577         public static final String KEY_KEEP_PDN_UP_IN_NO_VOPS_BOOL =
5578                 KEY_PREFIX + "keep_pdn_up_in_no_vops_bool";
5579 
5580         /** @hide */
5581         @IntDef({
5582             PREFERRED_TRANSPORT_UDP,
5583             PREFERRED_TRANSPORT_TCP,
5584             PREFERRED_TRANSPORT_DYNAMIC_UDP_TCP,
5585             PREFERRED_TRANSPORT_TLS
5586         })
5587         public @interface PreferredTransportType {}
5588 
5589         /** Preferred Transport is always UDP. */
5590         public static final int PREFERRED_TRANSPORT_UDP = 0;
5591 
5592         /** Preferred Transport is always TCP. */
5593         public static final int PREFERRED_TRANSPORT_TCP = 1;
5594 
5595         /**
5596          *  Preferred Transport is both UDP and TCP and selected based
5597          *  on MTU size specified in {@link #KEY_IPV4_SIP_MTU_SIZE_CELLULAR_INT}
5598          *  and {@link #KEY_IPV6_SIP_MTU_SIZE_CELLULAR_INT}.
5599          *
5600          *  <p>Default transport is UDP. If message size is larger
5601          *  than MTU, then TCP shall be used.
5602          */
5603         public static final int PREFERRED_TRANSPORT_DYNAMIC_UDP_TCP = 2;
5604 
5605         /** Preferred Transport is TLS. */
5606         public static final int PREFERRED_TRANSPORT_TLS = 3;
5607 
5608         /**
5609          * Specify the preferred transport protocol for SIP messages.
5610          *
5611          * <p>Possible values are,
5612          * {@link #PREFERRED_TRANSPORT_UDP},
5613          * {@link #PREFERRED_TRANSPORT_TCP},
5614          * {@link #PREFERRED_TRANSPORT_DYNAMIC_UDP_TCP}
5615          */
5616         public static final String KEY_SIP_PREFERRED_TRANSPORT_INT =
5617                 KEY_PREFIX + "sip_preferred_transport_int";
5618 
5619         /**
5620          * Specify the maximum IPV4 MTU size of SIP message on Cellular.
5621          *
5622          * <p>If {@link #KEY_SIP_PREFERRED_TRANSPORT_INT} is
5623          * {@link #PREFERRED_TRANSPORT_DYNAMIC_UDP_TCP} and SIP message MTU size
5624          * is more than this value, then SIP transport will be TCP, else the
5625          * SIP transport is UDP.
5626          */
5627         public static final String KEY_IPV4_SIP_MTU_SIZE_CELLULAR_INT =
5628                 KEY_PREFIX + "ipv4_sip_mtu_size_cellular_int";
5629 
5630         /**
5631          * Specify the maximum IPV6 MTU size of SIP message on Cellular.
5632          *
5633          * <p>If {@link #KEY_SIP_PREFERRED_TRANSPORT_INT} is
5634          * {@link #PREFERRED_TRANSPORT_DYNAMIC_UDP_TCP} and SIP message MTU size
5635          * is more than this value, then SIP transport will be TCP, else the
5636          * SIP transport is UDP.
5637          */
5638         public static final String KEY_IPV6_SIP_MTU_SIZE_CELLULAR_INT =
5639                 KEY_PREFIX + "ipv6_sip_mtu_size_cellular_int";
5640 
5641         /**
5642          * This config determines whether IMS PDN needs to be enabled
5643          * when VOPS support is not available in both home and roaming scenarios.
5644          *
5645          * <p>This is applicable before IMS PDN is up, to decide whether
5646          * IMS PDN needs to be enabled based on VOPS support in home/roaming.
5647          *
5648          * <p>Possible values are,
5649          * {@link #NETWORK_TYPE_HOME},
5650          * {@link #NETWORK_TYPE_ROAMING}
5651          * An empty array indicates IMS PDN depends on VOPS on both home
5652          * and roaming scenarios.
5653          */
5654         public static final String KEY_IMS_PDN_ENABLED_IN_NO_VOPS_SUPPORT_INT_ARRAY =
5655                 KEY_PREFIX + "ims_pdn_enabled_in_no_vops_support_int_array";
5656 
5657         /**
5658          * Flag indicating whether IPSec enabled for SIP messages.
5659          *
5660          * <p> Reference: 3GPP TS 33.203 and RFC 3329.
5661          */
5662         public static final String KEY_SIP_OVER_IPSEC_ENABLED_BOOL =
5663                 KEY_PREFIX + "sip_over_ipsec_enabled_bool";
5664 
5665         /** @hide */
5666         @IntDef({IPSEC_AUTHENTICATION_ALGORITHM_HMAC_MD5, IPSEC_AUTHENTICATION_ALGORITHM_HMAC_SHA1})
5667         public @interface IpsecAuthenticationAlgorithmType {}
5668 
5669         /** IPSec Authentication algorithm is HMAC-MD5. see Annex H of TS 33.203 */
5670         public static final int IPSEC_AUTHENTICATION_ALGORITHM_HMAC_MD5 = 0;
5671 
5672         /** IPSec Authentication algorithm is HMAC-SHA1. see Annex H of TS 33.203 */
5673         public static final int IPSEC_AUTHENTICATION_ALGORITHM_HMAC_SHA1 = 1;
5674 
5675         /**
5676          * List of supported IPSEC Authentication algorithms.
5677          *
5678          * <p>Possible values are,
5679          * {@link #IPSEC_AUTHENTICATION_ALGORITHM_HMAC_MD5},
5680          * {@link #IPSEC_AUTHENTICATION_ALGORITHM_HMAC_SHA1}
5681          */
5682         public static final String KEY_IPSEC_AUTHENTICATION_ALGORITHMS_INT_ARRAY =
5683                 KEY_PREFIX + "ipsec_authentication_algorithms_int_array";
5684 
5685         /** @hide */
5686         @IntDef({
5687             IPSEC_ENCRYPTION_ALGORITHM_NULL,
5688             IPSEC_ENCRYPTION_ALGORITHM_DES_EDE3_CBC,
5689             IPSEC_ENCRYPTION_ALGORITHM_AES_CBC
5690         })
5691         public @interface IpsecEncryptionAlgorithmType {}
5692 
5693         /** IPSec Encryption algorithm is NULL. see Annex H of TS 33.203 */
5694         public static final int IPSEC_ENCRYPTION_ALGORITHM_NULL = 0;
5695 
5696         /** IPSec Encryption algorithm is DES_EDE3_CBC. see Annex H of TS 33.203 */
5697         public static final int IPSEC_ENCRYPTION_ALGORITHM_DES_EDE3_CBC = 1;
5698 
5699         /** IPSec Encryption algorithm is AES_CBC. see Annex H of TS 33.203 */
5700         public static final int IPSEC_ENCRYPTION_ALGORITHM_AES_CBC = 2;
5701 
5702         /**
5703          * List of supported IPSEC encryption algorithms.
5704          *
5705          * <p>Possible values are,
5706          * {@link #IPSEC_ENCRYPTION_ALGORITHM_NULL},
5707          * {@link #IPSEC_ENCRYPTION_ALGORITHM_DES_EDE3_CBC},
5708          * {@link #IPSEC_ENCRYPTION_ALGORITHM_AES_CBC}
5709          */
5710         public static final String KEY_IPSEC_ENCRYPTION_ALGORITHMS_INT_ARRAY =
5711                 KEY_PREFIX + "ipsec_encryption_algorithms_int_array";
5712 
5713         /**
5714          * Expiry timer for IMS Registration in seconds.
5715          * <p>Reference: RFC 3261 Section 20.19.
5716          */
5717         public static final String KEY_REGISTRATION_EXPIRY_TIMER_SEC_INT =
5718                 KEY_PREFIX + "registration_expiry_timer_sec_int";
5719 
5720         /** Registration Retry Base-time as per RFC 5626 Section 4.5. */
5721         public static final String KEY_REGISTRATION_RETRY_BASE_TIMER_MILLIS_INT =
5722                 KEY_PREFIX + "registration_retry_base_timer_millis_int";
5723 
5724         /** Registration Retry max-time as per RFC 5626 Section 4.5. */
5725         public static final String KEY_REGISTRATION_RETRY_MAX_TIMER_MILLIS_INT =
5726                 KEY_PREFIX + "registration_retry_max_timer_millis_int";
5727 
5728         /**
5729          * Flag indicating whether subscription to registration event package
5730          * is supported or not.
5731          */
5732         public static final String KEY_REGISTRATION_EVENT_PACKAGE_SUPPORTED_BOOL =
5733                 KEY_PREFIX + "registration_event_package_supported_bool";
5734 
5735         /**
5736          * Expiry timer for SUBSCRIBE in seconds.
5737          * <p>Reference: RFC 3261 Section 20.19.
5738          */
5739         public static final String KEY_REGISTRATION_SUBSCRIBE_EXPIRY_TIMER_SEC_INT =
5740                 KEY_PREFIX + "registration_subscribe_expiry_timer_sec_int";
5741 
5742         /** @hide */
5743         @IntDef({
5744             GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_WIFI,
5745             GEOLOCATION_PIDF_FOR_EMERGENCY_ON_WIFI,
5746             GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_CELLULAR,
5747             GEOLOCATION_PIDF_FOR_EMERGENCY_ON_CELLULAR
5748         })
5749         public @interface GeolocationPidfAllowedType {}
5750 
5751         /**
5752          * Indicates geolocation PIDF XML needs to be included for
5753          * normal/non-emergency call scenario on WiFi
5754          *
5755          * <p>Geolocation for normal/non-emergency call should only include
5756          * country code.
5757          */
5758         public static final int GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_WIFI = 1;
5759 
5760         /**
5761          * Indicates geolocation PIDF XML needs to be included for emergency
5762          * call scenario on WiFi
5763          */
5764         public static final int GEOLOCATION_PIDF_FOR_EMERGENCY_ON_WIFI = 2;
5765 
5766         /**
5767          * Indicates geolocation PIDF XML needs to be included for normal/non-emergency
5768          * call scenario on Cellular
5769          *
5770          * <p>Geolocation for normal/non-emergency call should only include
5771          * country code.
5772          */
5773         public static final int GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_CELLULAR = 3;
5774 
5775         /**
5776          * Indicates geolocation PIDF XML needs to be included for emergency
5777          * call scenario on Cellular
5778          */
5779         public static final int GEOLOCATION_PIDF_FOR_EMERGENCY_ON_CELLULAR = 4;
5780 
5781         /**
5782          * List of cases where geolocation PIDF XML needs to be included in the
5783          * SIP REGISTER over WiFi and Cellular.
5784          *
5785          * <p>Possible values are,
5786          * {@link #GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_WIFI},
5787          * {@link #GEOLOCATION_PIDF_FOR_EMERGENCY_ON_WIFI},
5788          * {@link #GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_CELLULAR},
5789          * {@link #GEOLOCATION_PIDF_FOR_EMERGENCY_ON_CELLULAR}
5790          *
5791          * <p>An empty array indicates geolocation PIDF XML should not be included in
5792          * the SIP REGISTER over WiFi and Cellular.
5793          */
5794         public static final String KEY_GEOLOCATION_PIDF_IN_SIP_REGISTER_SUPPORT_INT_ARRAY =
5795                 KEY_PREFIX + "geolocation_pidf_in_sip_register_support_int_array";
5796 
5797         /**
5798          * List of cases where geolocation PIDF XML needs to be included in the
5799          * SIP INVITE over WiFi and Cellular.
5800          *
5801          * <p>Possible values are,
5802          * {@link #GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_WIFI},
5803          * {@link #GEOLOCATION_PIDF_FOR_EMERGENCY_ON_WIFI},
5804          * {@link #GEOLOCATION_PIDF_FOR_NON_EMERGENCY_ON_CELLULAR},
5805          * {@link #GEOLOCATION_PIDF_FOR_EMERGENCY_ON_CELLULAR}
5806          *
5807          * <p>An empty array indicates geolocation PIDF XML should not be included
5808          * in the SIP INVITE over WiFi and Cellular.
5809          */
5810         public static final String KEY_GEOLOCATION_PIDF_IN_SIP_INVITE_SUPPORT_INT_ARRAY =
5811                 KEY_PREFIX + "geolocation_pidf_in_sip_invite_support_int_array";
5812 
5813         /**
5814          * Specifies the IMS User Agent in template format.
5815          *
5816          * <p>Example: #MANUFACTURER#_#MODEL#_Android#AV#_#BUILD#".
5817          * IMS Stack should internally substitute the tokens with the
5818          * values from the respective android properties.
5819          *
5820          * <p>List of allowed tokens and the corresponding android properties are,
5821          * <UL>
5822          *   <LI>MANUFACTURER : ro.product.manufacturer</LI>
5823          *   <LI>MODEL :  ro.product.model</LI>
5824          *   <LI>AV : ro.build.version.release"</LI>
5825          *   <LI>BUILD : ro.build.id</LI>
5826          * </UL>
5827          * <p> Vendor IMS Stack should strip any whitespace characters present
5828          * in the android properties values before replacing the token.
5829          *
5830          * <p> An empty string is invalid as per IR92 section 2.6. This key is
5831          * considered invalid if the format is violated. If the key is invalid or
5832          * not configured, IMS stack should use internal default values.
5833          */
5834         public static final String KEY_IMS_USER_AGENT_STRING =
5835                 KEY_PREFIX + "ims_user_agent_string";
5836 
5837         /** @hide */
5838         @IntDef({
5839             NETWORK_TYPE_HOME,
5840             NETWORK_TYPE_ROAMING
5841         })
5842         public @interface NetworkType {}
5843 
5844         /** Indicates HOME Network. */
5845         public static final int NETWORK_TYPE_HOME = 0;
5846 
5847         /** Indicates Roaming Network. */
5848         public static final int NETWORK_TYPE_ROAMING = 1;
5849 
5850         /** @hide */
5851         @IntDef({
5852             RTCP_INACTIVITY_ON_HOLD,
5853             RTCP_INACTIVITY_ON_CONNECTED,
5854             RTP_INACTIVITY_ON_CONNECTED,
5855             E911_RTCP_INACTIVITY_ON_CONNECTED,
5856             E911_RTP_INACTIVITY_ON_CONNECTED
5857         })
5858         public @interface MediaInactivityReason {}
5859 
5860         /**  RTCP inactivity occurred when call is on HOLD. */
5861         public static final int RTCP_INACTIVITY_ON_HOLD = 0;
5862 
5863         /**  RTCP inactivity occurred when call is connected. */
5864         public static final int RTCP_INACTIVITY_ON_CONNECTED = 1;
5865 
5866         /**  RTP inactivity occurred when call is connected. */
5867         public static final int RTP_INACTIVITY_ON_CONNECTED = 2;
5868 
5869         /**  E911 RTCP inactivity occurred when call is connected. */
5870         public static final int E911_RTCP_INACTIVITY_ON_CONNECTED = 3;
5871 
5872         /**  E911 RTP inactivity occurred when call is connected. */
5873         public static final int E911_RTP_INACTIVITY_ON_CONNECTED = 4;
5874 
5875         /**
5876          * List of different RAT technologies on which IMS
5877          * is supported.
5878          *
5879          * <p>Possible values are,
5880          * {@link AccessNetworkConstants.AccessNetworkType#NGRAN}
5881          * {@link AccessNetworkConstants.AccessNetworkType#EUTRAN}
5882          * {@link AccessNetworkConstants.AccessNetworkType#IWLAN}
5883          * {@link AccessNetworkConstants.AccessNetworkType#UTRAN}
5884          * {@link AccessNetworkConstants.AccessNetworkType#GERAN}
5885          */
5886         public static final String KEY_SUPPORTED_RATS_INT_ARRAY =
5887                 KEY_PREFIX + "supported_rats_int_array";
5888 
5889         /**
5890          * A bundle which specifies the MMTEL capability and registration technology
5891          * that requires provisioning. If a tuple is not present, the
5892          * framework will not require that the tuple requires provisioning before
5893          * enabling the capability.
5894          * <p> Possible keys in this bundle are
5895          * <ul>
5896          *     <li>{@link #KEY_CAPABILITY_TYPE_VOICE_INT_ARRAY}</li>
5897          *     <li>{@link #KEY_CAPABILITY_TYPE_VIDEO_INT_ARRAY}</li>
5898          *     <li>{@link #KEY_CAPABILITY_TYPE_UT_INT_ARRAY}</li>
5899          *     <li>{@link #KEY_CAPABILITY_TYPE_SMS_INT_ARRAY}</li>
5900          *     <li>{@link #KEY_CAPABILITY_TYPE_CALL_COMPOSER_INT_ARRAY}</li>
5901          * </ul>
5902          * <p> The values are defined as {@code REGISTRATION_TECH_*} constants in
5903          * {@link android.telephony.ims.stub.ImsRegistrationImplBase}.
5904          *
5905          * changing mmtel_requires_provisioning_bundle requires changes to
5906          * carrier_volte_provisioning_required_bool and vice versa
5907          * {@link Ims#KEY_CARRIER_VOLTE_PROVISIONING_REQUIRED_BOOL}
5908          */
5909         public static final String KEY_MMTEL_REQUIRES_PROVISIONING_BUNDLE =
5910                 KEY_PREFIX + "mmtel_requires_provisioning_bundle";
5911 
5912         /**
5913          * List of different RAT technologies on which Provisioning for Voice calling (IR.92)
5914          * is supported.
5915          * <p>Possible values are,
5916          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_LTE}
5917          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_IWLAN}
5918          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_CROSS_SIM}
5919          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_NR}
5920          * @see MmTelFeature.MmTelCapabilities#CAPABILITY_TYPE_VOICE
5921          */
5922         public static final String KEY_CAPABILITY_TYPE_VOICE_INT_ARRAY =
5923                 KEY_PREFIX + "capability_type_voice_int_array";
5924 
5925         /**
5926          * List of different RAT technologies on which Provisioning for Video Telephony (IR.94)
5927          * is supported.
5928          * <p>Possible values are,
5929          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_LTE}
5930          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_IWLAN}
5931          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_CROSS_SIM}
5932          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_NR}
5933          * @see MmTelFeature.MmTelCapabilities#CAPABILITY_TYPE_VIDEO
5934          */
5935         public static final String KEY_CAPABILITY_TYPE_VIDEO_INT_ARRAY =
5936                 KEY_PREFIX + "capability_type_video_int_array";
5937 
5938         /**
5939          * List of different RAT technologies on which Provisioning for XCAP over Ut for
5940          * supplementary services. (IR.92) is supported.
5941          * <p>Possible values are,
5942          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_LTE}
5943          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_IWLAN}
5944          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_CROSS_SIM}
5945          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_NR}
5946          * @see MmTelFeature.MmTelCapabilities#CAPABILITY_TYPE_UT
5947          */
5948         public static final String KEY_CAPABILITY_TYPE_UT_INT_ARRAY =
5949                 KEY_PREFIX + "capability_type_ut_int_array";
5950 
5951         /**
5952          * List of different RAT technologies on which Provisioning for SMS (IR.92) is supported.
5953          * <p>Possible values are,
5954          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_LTE}
5955          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_IWLAN}
5956          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_CROSS_SIM}
5957          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_NR}
5958          * @see MmTelFeature.MmTelCapabilities#CAPABILITY_TYPE_SMS
5959          */
5960         public static final String KEY_CAPABILITY_TYPE_SMS_INT_ARRAY =
5961                 KEY_PREFIX + "capability_type_sms_int_array";
5962 
5963         /**
5964          * List of different RAT technologies on which Provisioning for Call Composer
5965          * (section 2.4 of RCC.20) is supported.
5966          * <p>Possible values are,
5967          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_LTE}
5968          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_IWLAN}
5969          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_CROSS_SIM}
5970          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_NR}
5971          * @see MmTelFeature.MmTelCapabilities#CAPABILITY_TYPE_CALL_COMPOSER
5972          */
5973         public static final String KEY_CAPABILITY_TYPE_CALL_COMPOSER_INT_ARRAY =
5974                 KEY_PREFIX + "capability_type_call_composer_int_array";
5975 
5976         /**
5977          * A bundle which specifies the RCS capability and registration technology
5978          * that requires provisioning. If a tuple is not present, the
5979          * framework will not require that the tuple requires provisioning before
5980          * enabling the capability.
5981          * <p> Possible keys in this bundle are
5982          * <ul>
5983          *     <li>{@link #KEY_CAPABILITY_TYPE_OPTIONS_UCE_INT_ARRAY}</li>
5984          *     <li>{@link #KEY_CAPABILITY_TYPE_PRESENCE_UCE_INT_ARRAY}</li>
5985          * </ul>
5986          * <p> The values are defined as {@code REGISTRATION_TECH_*} constants in
5987          * {@link android.telephony.ims.stub.ImsRegistrationImplBase}.
5988          */
5989         public static final String KEY_RCS_REQUIRES_PROVISIONING_BUNDLE =
5990                 KEY_PREFIX + "rcs_requires_provisioning_bundle";
5991 
5992         /**
5993          * This carrier supports User Capability Exchange using SIP OPTIONS as defined by the
5994          * framework. If set, the RcsFeature should support capability exchange using SIP OPTIONS.
5995          * If not set, this RcsFeature should not service capability requests.
5996          * <p>Possible values are,
5997          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_LTE}
5998          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_IWLAN}
5999          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_CROSS_SIM}
6000          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_NR}
6001          */
6002         public static final String KEY_CAPABILITY_TYPE_OPTIONS_UCE_INT_ARRAY =
6003                 KEY_PREFIX + "capability_type_options_uce_int_array";
6004 
6005         /**
6006          * This carrier supports User Capability Exchange using a presence server as defined by the
6007          * framework. If set, the RcsFeature should support capability exchange using a presence
6008          * server. If not set, this RcsFeature should not publish capabilities or service capability
6009          * requests using presence.
6010          * <p>Possible values are,
6011          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_LTE}
6012          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_IWLAN}
6013          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_CROSS_SIM}
6014          * {@link android.telephony.ims.stub.ImsRegistrationImplBase#REGISTRATION_TECH_NR}
6015          */
6016         public static final String KEY_CAPABILITY_TYPE_PRESENCE_UCE_INT_ARRAY =
6017                 KEY_PREFIX + "capability_type_presence_uce_int_array";
6018 
6019         /**
6020          * Specifies the policy for disabling NR SA mode. Default value is
6021          *{@link #SA_DISABLE_POLICY_NONE}.
6022          * The value set as below:
6023          * <ul>
6024          * <li>0: {@link #SA_DISABLE_POLICY_NONE }</li>
6025          * <li>1: {@link #SA_DISABLE_POLICY_WFC_ESTABLISHED }</li>
6026          * <li>2: {@link #SA_DISABLE_POLICY_WFC_ESTABLISHED_WHEN_VONR_DISABLED  }</li>
6027          * <li>3: {@link #SA_DISABLE_POLICY_VOWIFI_REGISTERED  }</li>
6028          * </ul>
6029          * @hide
6030          */
6031         public static final String KEY_NR_SA_DISABLE_POLICY_INT =
6032                 KEY_PREFIX + "sa_disable_policy_int";
6033 
6034         /** @hide */
6035         @IntDef({
6036                 NR_SA_DISABLE_POLICY_NONE,
6037                 NR_SA_DISABLE_POLICY_WFC_ESTABLISHED,
6038                 NR_SA_DISABLE_POLICY_WFC_ESTABLISHED_WHEN_VONR_DISABLED,
6039                 NR_SA_DISABLE_POLICY_VOWIFI_REGISTERED
6040         })
6041         public @interface NrSaDisablePolicy {}
6042 
6043         /**
6044          * Do not disables NR SA mode.
6045          * @hide
6046          */
6047         public static final int NR_SA_DISABLE_POLICY_NONE = 0;
6048 
6049         /**
6050          * Disables NR SA mode when VoWiFi call is established in order to improve the delay or
6051          * voice mute when the handover from ePDG to NR is not supported in UE or network.
6052          * @hide
6053          */
6054         public static final int NR_SA_DISABLE_POLICY_WFC_ESTABLISHED = 1;
6055 
6056         /**
6057          * Disables NR SA mode when VoWiFi call is established when VoNR is disabled in order to
6058          * improve the delay or voice mute when the handover from ePDG to NR is not supported
6059          * in UE or network.
6060          * @hide
6061          */
6062         public static final int NR_SA_DISABLE_POLICY_WFC_ESTABLISHED_WHEN_VONR_DISABLED = 2;
6063 
6064         /**
6065          * Disables NR SA mode when IMS is registered over WiFi in order to improve the delay or
6066          * voice mute when the handover from ePDG to NR is not supported in UE or network.
6067          * @hide
6068          */
6069         public static final int NR_SA_DISABLE_POLICY_VOWIFI_REGISTERED = 3;
6070 
6071         /**
6072          * This specifies whether the carrier support the global number format or not.
6073          * {@link SubscriptionManager#getPhoneNumber(int)},
6074          * {@link SubscriptionManager#getPhoneNumber(int, int)} with
6075          * {@link SubscriptionManager#PHONE_NUMBER_SOURCE_IMS}
6076          * In order to provide the phone number to the APIs, the framework extracts the phone
6077          * number from the message received from the carrier server. If the carrier does not use
6078          * global number format, the framework could not provide phone number.
6079          * <p>
6080          * If not set or set to false value, the framework handle only global number format URI.
6081          * @hide
6082          */
6083         public static final String KEY_ALLOW_NON_GLOBAL_PHONE_NUMBER_FORMAT_BOOL =
6084                 KEY_PREFIX + "allow_non_global_phone_number_format_bool";
6085 
Ims()6086         private Ims() {}
6087 
getDefaults()6088         private static PersistableBundle getDefaults() {
6089             PersistableBundle defaults = new PersistableBundle();
6090             defaults.putInt(KEY_WIFI_OFF_DEFERRING_TIME_MILLIS_INT, 4000);
6091             defaults.putBoolean(KEY_IMS_SINGLE_REGISTRATION_REQUIRED_BOOL, false);
6092             defaults.putBoolean(KEY_ENABLE_PRESENCE_PUBLISH_BOOL, false);
6093             defaults.putStringArray(KEY_PUBLISH_SERVICE_DESC_FEATURE_TAG_MAP_OVERRIDE_STRING_ARRAY,
6094                     new String[0]);
6095             defaults.putBoolean(KEY_ENABLE_PRESENCE_CAPABILITY_EXCHANGE_BOOL, false);
6096             defaults.putBoolean(KEY_RCS_BULK_CAPABILITY_EXCHANGE_BOOL, false);
6097             defaults.putBoolean(KEY_ENABLE_PRESENCE_GROUP_SUBSCRIBE_BOOL, false);
6098             defaults.putLong(KEY_SUBSCRIBE_RETRY_DURATION_MILLIS_LONG, -1);
6099             defaults.putBoolean(KEY_USE_SIP_URI_FOR_PRESENCE_SUBSCRIBE_BOOL, false);
6100             defaults.putInt(KEY_NON_RCS_CAPABILITIES_CACHE_EXPIRATION_SEC_INT, 30 * 24 * 60 * 60);
6101             defaults.putBoolean(KEY_RCS_REQUEST_FORBIDDEN_BY_SIP_489_BOOL, false);
6102             defaults.putLong(KEY_RCS_REQUEST_RETRY_INTERVAL_MILLIS_LONG, 20 * 60 * 1000);
6103             defaults.putStringArray(KEY_RCS_FEATURE_TAG_ALLOWED_STRING_ARRAY, new String[]{
6104                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.oma.cpm.msg\"",
6105                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.oma.cpm.largemsg\"",
6106                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.oma.cpm.deferred\"",
6107                     "+g.gsma.rcs.cpm.pager-large",
6108                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.oma.cpm.session\"",
6109                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.oma.cpm.filetransfer\"",
6110                     "+g.3gpp.iari-ref=\"urn%3Aurn-7%3A3gpp-application.ims.iari.rcs.fthttp\"",
6111                     "+g.3gpp.iari-ref=\"urn%3Aurn-7%3A3gpp-application.ims.iari.rcs.ftsms\"",
6112                     "+g.3gpp.iari-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.gsma.callcomposer\"",
6113                     "+g.gsma.callcomposer",
6114                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.gsma.callunanswered\"",
6115                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.gsma.sharedmap\"",
6116                     "+g.3gpp.icsi-ref=\"urn%3Aurn-7%3A3gpp-service.ims.icsi.gsma.sharedsketch\"",
6117                     "+g.3gpp.iari-ref=\"urn%3Aurn-7%3A3gpp-application.ims.iari.rcs.geopush\"",
6118                     "+g.3gpp.iari-ref=\"urn%3Aurn-7%3A3gpp-application.ims.iari.rcs.geosms\"",
6119                     "+g.3gpp.iari-ref=\"urn%3Aurn-7%3A3gpp-application.ims.iari.rcs.chatbot\"",
6120                     "+g.3gpp.iari-ref=\"urn%3Aurn-7%3A3gpp-application.ims.iari.rcs.chatbot.sa\"",
6121                     "+g.gsma.rcs.botversion=\"#=1,#=2\"",
6122                     "+g.gsma.rcs.cpimext"});
6123 
6124             /**
6125              * @see #KEY_MMTEL_REQUIRES_PROVISIONING_BUNDLE
6126              */
6127             defaults.putPersistableBundle(
6128                     KEY_MMTEL_REQUIRES_PROVISIONING_BUNDLE, new PersistableBundle());
6129             /**
6130              * @see #KEY_RCS_REQUIRES_PROVISIONING_BUNDLE
6131              */
6132             defaults.putPersistableBundle(
6133                     KEY_RCS_REQUIRES_PROVISIONING_BUNDLE, new PersistableBundle());
6134 
6135             defaults.putBoolean(KEY_GRUU_ENABLED_BOOL, false);
6136             defaults.putBoolean(KEY_SIP_OVER_IPSEC_ENABLED_BOOL, true);
6137             defaults.putBoolean(KEY_KEEP_PDN_UP_IN_NO_VOPS_BOOL, false);
6138             defaults.putBoolean(KEY_REGISTRATION_EVENT_PACKAGE_SUPPORTED_BOOL, true);
6139 
6140             defaults.putInt(KEY_SIP_TIMER_T1_MILLIS_INT, 2000);
6141             defaults.putInt(KEY_SIP_TIMER_T2_MILLIS_INT, 16000);
6142             defaults.putInt(KEY_SIP_TIMER_T4_MILLIS_INT, 17000);
6143             defaults.putInt(KEY_SIP_TIMER_B_MILLIS_INT, 128000);
6144             defaults.putInt(KEY_SIP_TIMER_C_MILLIS_INT, 210000);
6145             defaults.putInt(KEY_SIP_TIMER_D_MILLIS_INT, 130000);
6146             defaults.putInt(KEY_SIP_TIMER_F_MILLIS_INT, 128000);
6147             defaults.putInt(KEY_SIP_TIMER_H_MILLIS_INT, 128000);
6148             defaults.putInt(KEY_SIP_TIMER_J_MILLIS_INT, 128000);
6149             defaults.putInt(KEY_SIP_SERVER_PORT_NUMBER_INT, 5060);
6150             defaults.putInt(KEY_REQUEST_URI_TYPE_INT, REQUEST_URI_FORMAT_TEL);
6151             defaults.putInt(KEY_SIP_PREFERRED_TRANSPORT_INT, PREFERRED_TRANSPORT_DYNAMIC_UDP_TCP);
6152             defaults.putInt(KEY_IPV4_SIP_MTU_SIZE_CELLULAR_INT, 1500);
6153             defaults.putInt(KEY_IPV6_SIP_MTU_SIZE_CELLULAR_INT, 1500);
6154             defaults.putInt(KEY_REGISTRATION_EXPIRY_TIMER_SEC_INT, 600000);
6155             defaults.putInt(KEY_REGISTRATION_RETRY_BASE_TIMER_MILLIS_INT, 30000);
6156             defaults.putInt(KEY_REGISTRATION_RETRY_MAX_TIMER_MILLIS_INT, 1800000);
6157             defaults.putInt(KEY_REGISTRATION_SUBSCRIBE_EXPIRY_TIMER_SEC_INT, 600000);
6158             defaults.putInt(KEY_NR_SA_DISABLE_POLICY_INT, NR_SA_DISABLE_POLICY_NONE);
6159 
6160             defaults.putIntArray(
6161                     KEY_IPSEC_AUTHENTICATION_ALGORITHMS_INT_ARRAY,
6162                     new int[] {
6163                         IPSEC_AUTHENTICATION_ALGORITHM_HMAC_MD5,
6164                         IPSEC_AUTHENTICATION_ALGORITHM_HMAC_SHA1
6165                     });
6166             defaults.putIntArray(
6167                     KEY_IPSEC_ENCRYPTION_ALGORITHMS_INT_ARRAY,
6168                     new int[] {
6169                         IPSEC_ENCRYPTION_ALGORITHM_NULL,
6170                         IPSEC_ENCRYPTION_ALGORITHM_DES_EDE3_CBC,
6171                         IPSEC_ENCRYPTION_ALGORITHM_AES_CBC
6172                     });
6173             defaults.putIntArray(
6174                     KEY_IMS_PDN_ENABLED_IN_NO_VOPS_SUPPORT_INT_ARRAY,
6175                     new int[] {
6176                     });
6177             defaults.putIntArray(
6178                     KEY_GEOLOCATION_PIDF_IN_SIP_REGISTER_SUPPORT_INT_ARRAY,
6179                     new int[] {
6180                         GEOLOCATION_PIDF_FOR_EMERGENCY_ON_WIFI
6181                     });
6182             defaults.putIntArray(
6183                     KEY_GEOLOCATION_PIDF_IN_SIP_INVITE_SUPPORT_INT_ARRAY,
6184                     new int[] {
6185                         GEOLOCATION_PIDF_FOR_EMERGENCY_ON_WIFI
6186                     });
6187             defaults.putIntArray(
6188                     KEY_SUPPORTED_RATS_INT_ARRAY,
6189                     new int[] {
6190                         AccessNetworkType.NGRAN,
6191                         AccessNetworkType.EUTRAN,
6192                         AccessNetworkType.IWLAN
6193                     });
6194 
6195             defaults.putString(KEY_PHONE_CONTEXT_DOMAIN_NAME_STRING, "");
6196             defaults.putString(KEY_IMS_USER_AGENT_STRING,
6197                                "#MANUFACTURER#_#MODEL#_Android#AV#_#BUILD#");
6198 
6199             defaults.putBoolean(KEY_ALLOW_NON_GLOBAL_PHONE_NUMBER_FORMAT_BOOL, false);
6200 
6201             return defaults;
6202         }
6203     }
6204 
6205     /**
6206      * IMS Voice configs. This groups the configs required for IMS Voice - VoNR/VoLTE
6207      *
6208      * <p>Reference: IR.92
6209      */
6210     public static final class ImsVoice {
ImsVoice()6211         private ImsVoice() {}
6212 
6213         /** Prefix of all imsvoice.KEY_* constants. */
6214         public static final String KEY_PREFIX = "imsvoice.";
6215 
6216         /**
6217          * Flag specifying whether VoLTE should be available when on
6218          * roaming network.
6219          *
6220          * <p>If {@code false}: hard disabled.
6221          * If {@code true}: then depends on availability, etc.
6222          */
6223         public static final String KEY_CARRIER_VOLTE_ROAMING_AVAILABLE_BOOL =
6224                 KEY_PREFIX + "carrier_volte_roaming_available_bool";
6225 
6226         /**
6227          * Flag specifying whether to send vertical caller id service codes
6228          * (*67 and *82) in the dialed string in the SIP:INVITE.
6229          *
6230          * <p>If {@code true}, vertical caller id service codes *67 and *82
6231          * will be sent in the dialed string in the SIP:INVITE.
6232          * If {@code false}, *67 and *82 will be removed.
6233          */
6234         public static final String KEY_INCLUDE_CALLER_ID_SERVICE_CODES_IN_SIP_INVITE_BOOL =
6235                 KEY_PREFIX + "include_caller_id_service_codes_in_sip_invite_bool";
6236 
6237         /**
6238          * Flag indicating whether Multi-end point setting is enabled or not.
6239          */
6240         public static final String KEY_MULTIENDPOINT_SUPPORTED_BOOL =
6241                 KEY_PREFIX + "multiendpoint_supported_bool";
6242 
6243         /**
6244          * Flag indicating whether Supported header field with the option tag
6245          *  'timer' is enabled or not.
6246          *
6247          * <p>If {@code true}, session timer support is available.{@code false} otherwise.
6248          *
6249          * Reference: RFC 4028 Section 3
6250          */
6251         public static final String KEY_SESSION_TIMER_SUPPORTED_BOOL =
6252                 KEY_PREFIX + "session_timer_supported_bool";
6253 
6254         /**
6255          * Session-expires header field expressed in seconds as per
6256          * RFC 4028 Section 3.
6257          *
6258          * <p>This establishes the upper bound for the session refresh interval.
6259          */
6260         public static final String KEY_SESSION_EXPIRES_TIMER_SEC_INT =
6261                 KEY_PREFIX + "session_expires_timer_sec_int";
6262 
6263         /**
6264          * Indicates the minimum value for the session interval in seconds.
6265          * Represented as min-SE header field as per RFC 4028 Section 3.
6266          *
6267          * <p>This establishes the lower bound for the session refresh interval.
6268          */
6269         public static final String KEY_MINIMUM_SESSION_EXPIRES_TIMER_SEC_INT =
6270                 KEY_PREFIX + "minimum_session_expires_timer_sec_int";
6271 
6272         /** @hide */
6273         @IntDef({
6274             SESSION_REFRESHER_TYPE_UNKNOWN,
6275             SESSION_REFRESHER_TYPE_UAC,
6276             SESSION_REFRESHER_TYPE_UAS
6277         })
6278         public @interface SessionRefresherType {}
6279 
6280         /**
6281          * Session Refresher entity is unknown. This means UE does not include the
6282          * "refresher" parameter in the Session-Expires header field of
6283          * the SIP INVITE request.
6284          */
6285         public static final int SESSION_REFRESHER_TYPE_UNKNOWN = 0;
6286 
6287         /**
6288          * Session Refresher entity is User Agent Client (UAC).
6289          *
6290          * <p>Type of "refresher" parameter in the Session-Expires header field
6291          * of the SIP INVITE request is UAC.
6292          */
6293         public static final int SESSION_REFRESHER_TYPE_UAC = 1;
6294 
6295         /**
6296          * Session Refresher entity is User Agent Server (UAS).
6297          *
6298          * <p>Type of "refresher" parameter in the Session-Expires header field
6299          * of the SIP INVITE request is UAS.
6300          */
6301         public static final int SESSION_REFRESHER_TYPE_UAS = 2;
6302 
6303         /**
6304          * Session Refresher entity as per RFC 4028 and IR.92 Section 2.2.8.
6305          *
6306          * <p>This determines,
6307          * a) whether to include the "refresher" parameter
6308          * b) Type of refresher" parameter
6309          * in the Session-Expires header field of the SIP INVITE request.
6310          *
6311          * <p>Possible values are,
6312          * {@link #SESSION_REFRESHER_TYPE_UNKNOWN},
6313          * {@link #SESSION_REFRESHER_TYPE_UAC},
6314          * {@link #SESSION_REFRESHER_TYPE_UAS}
6315          */
6316         public static final String KEY_SESSION_REFRESHER_TYPE_INT =
6317                 KEY_PREFIX + "session_refresher_type_int";
6318 
6319         /** @hide */
6320         @IntDef({
6321             SESSION_PRIVACY_TYPE_HEADER,
6322             SESSION_PRIVACY_TYPE_NONE,
6323             SESSION_PRIVACY_TYPE_ID
6324         })
6325         public @interface SessionPrivacyType {}
6326 
6327         /**
6328          * Session privacy type is HEADER as per RFC 3323 Section 4.2.
6329          */
6330         public static final int SESSION_PRIVACY_TYPE_HEADER = 0;
6331 
6332         /**
6333          * Session privacy type is NONE as per RFC 3323 Section 4.2.
6334          */
6335         public static final int SESSION_PRIVACY_TYPE_NONE = 1;
6336 
6337         /**
6338          * Session privacy type is ID as per RFC 3325 Section 9.3.
6339          */
6340         public static final int SESSION_PRIVACY_TYPE_ID = 2;
6341 
6342         /**
6343          * Specify the session privacy type.
6344          *
6345          * <p>Reference: RFC 3323 Section 4.2, RFC 3325 Section 9.3.
6346          *
6347          * <p>Possible values are,
6348          * {@link #SESSION_PRIVACY_TYPE_HEADER},
6349          * {@link #SESSION_PRIVACY_TYPE_NONE},
6350          * {@link #SESSION_PRIVACY_TYPE_ID}
6351          */
6352         public static final String KEY_SESSION_PRIVACY_TYPE_INT =
6353                 KEY_PREFIX + "session_privacy_type_int";
6354 
6355         /**
6356          * Flag indicating whether PRACK must be enabled for all 18x messages.
6357          *
6358          * <p>If {@code false}, only 18x responses with SDP are sent reliably.
6359          * If {@code true},  SIP 18x responses (other than SIP 183 response)
6360          * are sent reliably.
6361          */
6362         public static final String KEY_PRACK_SUPPORTED_FOR_18X_BOOL =
6363                 KEY_PREFIX + "prack_supported_for_18x_bool";
6364 
6365         /** @hide */
6366         @IntDef({
6367             CONFERENCE_SUBSCRIBE_TYPE_IN_DIALOG,
6368             CONFERENCE_SUBSCRIBE_TYPE_OUT_OF_DIALOG
6369         })
6370         public @interface ConferenceSubscribeType {}
6371 
6372         /**
6373          * The SIP SUBSCRIBE to conference state events is sent in the
6374          * SIP INVITE dialog between the UE and the conference server.
6375          *
6376          * <p>Reference: IR.92 Section 2.3.3.
6377          */
6378         public static final int CONFERENCE_SUBSCRIBE_TYPE_IN_DIALOG = 0;
6379 
6380         /**
6381          * The SIP SUBSCRIBE to conference state events is sent out of
6382          * the SIP INVITE dialog between the UE and the conference server.
6383          *
6384          * <p>Reference: IR.92 Section 2.3.3.
6385          */
6386         public static final int CONFERENCE_SUBSCRIBE_TYPE_OUT_OF_DIALOG = 1;
6387 
6388         /**
6389          * This is used to specify whether the SIP SUBSCRIBE to conference state events,
6390          * is sent in or out of the SIP INVITE dialog between the UE and the
6391          * conference server.
6392          *
6393          * <p>Reference: IR.92 Section 2.3.3.
6394          *
6395          * <p>Possible values are,
6396          * {@link #CONFERENCE_SUBSCRIBE_TYPE_IN_DIALOG},
6397          * {@link #CONFERENCE_SUBSCRIBE_TYPE_OUT_OF_DIALOG}
6398          *
6399          * An empty array indicates SUBSCRIBE to conference event package
6400          * is not required.
6401          */
6402         public static final String KEY_CONFERENCE_SUBSCRIBE_TYPE_INT =
6403                 KEY_PREFIX + "conference_subscribe_type_int";
6404 
6405         /**
6406          * Flag specifying whether QoS preconditions are supported during call setup.
6407          *
6408          * <p>If {@code true}: QoS Preconditions are supported during call setup and
6409          * 'precondition' tag is included in the SIP INVITE header and precondition
6410          * parameters are sent in SDP as required.
6411          * <p>If {@code false}: QoS Preconditions are not supported during call setup.
6412          *
6413          * <p>Reference: 3GPP TS 24.229
6414          */
6415         public static final String KEY_VOICE_QOS_PRECONDITION_SUPPORTED_BOOL =
6416                 KEY_PREFIX + "voice_qos_precondition_supported_bool";
6417 
6418         /**
6419          * Flag specifying whether voice is allowed on default bearer.
6420          *
6421          * <p>If {@code true}: voice packets can be sent on default bearer. {@code false} otherwise.
6422          */
6423         public static final String KEY_VOICE_ON_DEFAULT_BEARER_SUPPORTED_BOOL =
6424                 KEY_PREFIX + "voice_on_default_bearer_supported_bool";
6425 
6426         /**
6427          * Specifies the dedicated bearer wait time during call establishment.
6428          *
6429          * <p>If dedicated bearer is not established within this time and if
6430          * {@link #KEY_VOICE_ON_DEFAULT_BEARER_SUPPORTED_BOOL} is false, then call setup would fail.
6431          * <p>If dedicated bearer is not established within this time and if
6432          * {@link #KEY_VOICE_ON_DEFAULT_BEARER_SUPPORTED_BOOL} is true, then the media is allowed
6433          * on default bearer.
6434          */
6435         public static final String KEY_DEDICATED_BEARER_WAIT_TIMER_MILLIS_INT =
6436                 KEY_PREFIX + "dedicated_bearer_wait_timer_millis_int";
6437 
6438         /** @hide */
6439         @IntDef({
6440             BASIC_SRVCC_SUPPORT,
6441             ALERTING_SRVCC_SUPPORT,
6442             PREALERTING_SRVCC_SUPPORT,
6443             MIDCALL_SRVCC_SUPPORT
6444         })
6445         public @interface SrvccType {}
6446 
6447         /**
6448          * Indicates support for basic SRVCC, typically 1 active call
6449          * as detailed in IR.92 Section A.3.
6450          */
6451         public static final int BASIC_SRVCC_SUPPORT = 0;
6452 
6453         /**
6454          * SRVCC access transfer for calls in alerting phase as per 3GPP 24.237
6455          * and IR.64 Section 4.4.
6456          * Media feature tag used: g.3gpp.srvcc-alerting.
6457          */
6458         public static final int ALERTING_SRVCC_SUPPORT = 1;
6459 
6460         /**
6461          * SRVCC access transfer for calls in pre-alerting phase as per 3GPP 24.237.
6462          * Media feature tag used: g.3gpp.ps2cs-srvcc-orig-pre-alerting.
6463          */
6464         public static final int PREALERTING_SRVCC_SUPPORT = 2;
6465 
6466         /**
6467          * SRVCC access transfer for calls in mid-call phase as per 3GPP 24.237.
6468          * and IR.64 Section 4.4.
6469          * <p>This means UE supports the MSC server assisted mid-call feature.
6470          * Media feature tag used: g.3gpp.mid-call.
6471          */
6472         public static final int MIDCALL_SRVCC_SUPPORT = 3;
6473 
6474         /**
6475          * List of different SRVCC types supported as defined in 3GPP 24.237.
6476          *
6477          * <p> Possible values are,
6478          * {@link #BASIC_SRVCC_SUPPORT},
6479          * {@link #ALERTING_SRVCC_SUPPORT},
6480          * {@link #PREALERTING_SRVCC_SUPPORT},
6481          * {@link #MIDCALL_SRVCC_SUPPORT}
6482          *
6483          * <p> Reference: IR.64, 3GPP 24.237, 3GPP 23.216
6484          */
6485         public static final String KEY_SRVCC_TYPE_INT_ARRAY =
6486                 KEY_PREFIX + "srvcc_type_int_array";
6487 
6488         /**
6489          * Specifies the ringing timer for Mobile terminated calls.
6490          *
6491          * <p>Ringing timer starts when the device sends SIP 180 Ringing in
6492          * response to a received SIP INVITE. If Ringing timer expires,
6493          * the device sends SIP 486 response.
6494          */
6495         public static final String KEY_RINGING_TIMER_MILLIS_INT =
6496                 KEY_PREFIX + "ringing_timer_millis_int";
6497 
6498         /**
6499          * Specifies the ringback timer for Mobile originated calls.
6500          *
6501          * <p>Ringback timer starts when the device receives SIP 180 Ringing
6502          * in response to its SIP INVITE. If Ringback timer expires,
6503          * the device sends SIP CANCEL.
6504          */
6505         public static final String KEY_RINGBACK_TIMER_MILLIS_INT =
6506                 KEY_PREFIX + "ringback_timer_millis_int";
6507 
6508         /**
6509          * Specifies the timeout value for RTP inactivity for audio media.
6510          * <p>On timer expiry, call will end.
6511          * See {@link #KEY_AUDIO_INACTIVITY_CALL_END_REASONS_INT_ARRAY} for more
6512          * details.
6513          * <p> Value of 0 means this timer is not enabled.
6514          */
6515         public static final String KEY_AUDIO_RTP_INACTIVITY_TIMER_MILLIS_INT =
6516                 KEY_PREFIX + "audio_rtp_inactivity_timer_millis_int";
6517 
6518         /**
6519          * Specifies the timeout value for RTCP inactivity for audio media.
6520          * <p>On timer expiry, call will end.
6521          * See {@link #KEY_AUDIO_INACTIVITY_CALL_END_REASONS_INT_ARRAY} for more
6522          * details.
6523          * <p> Value of 0 means this timer is not enabled.
6524          */
6525         public static final String KEY_AUDIO_RTCP_INACTIVITY_TIMER_MILLIS_INT =
6526                 KEY_PREFIX + "audio_rtcp_inactivity_timer_millis_int";
6527 
6528         /**
6529          * Used to specify the conference factory URI.
6530          *
6531          * <p>If this is empty, then conference URI is generated from MCC/MNC as
6532          * specified in clause 13.10 of 3GPP 23.003.
6533          */
6534         public static final String KEY_CONFERENCE_FACTORY_URI_STRING =
6535                 KEY_PREFIX + "conference_factory_uri_string";
6536 
6537         /** @hide */
6538         @IntDef({
6539             SESSION_REFRESH_METHOD_INVITE,
6540             SESSION_REFRESH_METHOD_UPDATE_PREFERRED
6541         })
6542         public @interface SessionRefreshMethod {}
6543 
6544         /**
6545          * SIP INVITE is used for Session Refresh
6546          */
6547         public static final int SESSION_REFRESH_METHOD_INVITE = 0;
6548 
6549         /**
6550          * Both SIP INVITE and UPDATE are used for session refresh.
6551          *
6552          * <p>SIP UPDATE will be used if UPDATE is in 'Allow' header.
6553          * If UPDATE is not in 'Allow' header, then INVITE will be used.
6554          */
6555         public static final int SESSION_REFRESH_METHOD_UPDATE_PREFERRED = 1;
6556 
6557         /**
6558          * This is used to specify the method used for session refresh.
6559          *
6560          * <p>Possible values are,
6561          * {@link #SESSION_REFRESH_METHOD_INVITE},
6562          * {@link #SESSION_REFRESH_METHOD_UPDATE_PREFERRED}
6563          */
6564         public static final String KEY_SESSION_REFRESH_METHOD_INT =
6565                 KEY_PREFIX + "session_refresh_method_int";
6566 
6567         /**
6568          * Flag specifying whether the 'From' header field is used for determination of
6569          * the originating party identity in Originating Identification Presentation(OIP)
6570          * service.
6571          *
6572          * <p>If {@code true}: Indicates that the 'From' header field is used for
6573          * determination of the originating party identity in OIP.
6574          * {@code false} otherwise.
6575          */
6576         public static final String KEY_OIP_SOURCE_FROM_HEADER_BOOL =
6577                 KEY_PREFIX + "oip_source_from_header_bool";
6578 
6579         /**
6580          * Specifies the timer value for INVITE to the first 1xx response
6581          * (including 100 trying). If no response is received at timer expiry,
6582          * call is redialed over CS.
6583          *
6584          * <p> Reference: 24.173 Table L.1
6585          */
6586         public static final String KEY_MO_CALL_REQUEST_TIMEOUT_MILLIS_INT =
6587                 KEY_PREFIX + "mo_call_request_timeout_millis_int";
6588 
6589         /**
6590          * List of various reasons of media inactivity for which
6591          * voice/emergency call will end.
6592          *
6593          * <p>Possible values are,
6594          * {@link Ims#RTCP_INACTIVITY_ON_HOLD},
6595          * {@link Ims#RTCP_INACTIVITY_ON_CONNECTED},
6596          * {@link Ims#RTP_INACTIVITY_ON_CONNECTED}
6597          * {@link Ims#E911_RTCP_INACTIVITY_ON_CONNECTED},
6598          * {@link Ims#E911_RTP_INACTIVITY_ON_CONNECTED}
6599          */
6600         public static final String KEY_AUDIO_INACTIVITY_CALL_END_REASONS_INT_ARRAY =
6601                 KEY_PREFIX + "audio_inactivity_call_end_reasons_int_array";
6602 
6603         /**
6604          * Specifies the AS (Application Specific) SDP modifier for audio media.
6605          *
6606          * <p>This value is expressed in kilobits per second.
6607          * Reference: RFC 3556 Section 2.
6608          */
6609         public static final String KEY_AUDIO_AS_BANDWIDTH_KBPS_INT =
6610                 KEY_PREFIX + "audio_as_bandwidth_kbps_int";
6611 
6612         /**
6613          * Specifies the RS SDP modifier for audio media. This indicates the RTCP
6614          * bandwidth allocated to active data senders for audio media.
6615          *
6616          * <p>This value is expressed in bits per second.
6617          * Reference: RFC 3556 Section 2.
6618          */
6619         public static final String KEY_AUDIO_RS_BANDWIDTH_BPS_INT =
6620                 KEY_PREFIX + "audio_rs_bandwidth_bps_int";
6621 
6622         /**
6623          * Specifies the RR SDP modifier for audio media. This indicates the RTCP
6624          * bandwidth allocated to receivers for audio media.
6625          *
6626          * <p>This value is expressed in bits per second.
6627          * Reference: RFC 3556 Section 2.
6628          */
6629         public static final String KEY_AUDIO_RR_BANDWIDTH_BPS_INT =
6630                 KEY_PREFIX + "audio_rr_bandwidth_bps_int";
6631 
6632         /**
6633          * Specifies the Audio Codec capability. This contains a list of payload types
6634          * representing different audio codec instances.
6635          *
6636          * <p> The priority of the codecs is EVS, AMRWB, AMRNB,  DTMF WB, DTMF NB
6637          * from highest to lowest. In each individual codec, the priority is determined
6638          * by the order of the payload types from highest to lowest.
6639          *
6640          * <p>Possible keys in this bundle are,
6641          * <UL>
6642          *     <LI>{@link #KEY_EVS_PAYLOAD_TYPE_INT_ARRAY}</LI>
6643          *     <LI>{@link #KEY_AMRWB_PAYLOAD_TYPE_INT_ARRAY}</LI>
6644          *     <LI>{@link #KEY_AMRNB_PAYLOAD_TYPE_INT_ARRAY}</LI>
6645          *     <LI>{@link #KEY_DTMFWB_PAYLOAD_TYPE_INT_ARRAY}</LI>
6646          *     <LI>{@link #KEY_DTMFNB_PAYLOAD_TYPE_INT_ARRAY}</LI>
6647          * </UL>
6648          * <p>To specify payload descriptions for each of the audio payload types, see
6649          * <UL>
6650          *     <LI>{@link #KEY_EVS_PAYLOAD_DESCRIPTION_BUNDLE}</LI>
6651          *     <LI>{@link #KEY_AMRNB_PAYLOAD_DESCRIPTION_BUNDLE}</LI>
6652          *     <LI>{@link #KEY_AMRWB_PAYLOAD_DESCRIPTION_BUNDLE}</LI>
6653          * </UL>
6654          */
6655         public static final String KEY_AUDIO_CODEC_CAPABILITY_PAYLOAD_TYPES_BUNDLE =
6656                 KEY_PREFIX + "audio_codec_capability_payload_types_bundle";
6657 
6658         /**
6659          * A list of integers representing the different payload types
6660          * in EVS codec in priority order from highest to lowest.
6661          * <p>Payload type is an integer in dynamic payload type range 96-127
6662          * as per RFC RFC 3551 Section 6.
6663          */
6664         public static final String KEY_EVS_PAYLOAD_TYPE_INT_ARRAY =
6665                 KEY_PREFIX + "evs_payload_type_int_array";
6666 
6667         /**
6668          * A list of integers representing the different payload types
6669          * in AMR-WB codec in priority order from highest to lowest.
6670          * <p>Payload type is an integer in dynamic payload type range 96-127
6671          * as per RFC RFC 3551 Section 6.
6672          */
6673         public static final String KEY_AMRWB_PAYLOAD_TYPE_INT_ARRAY =
6674                 KEY_PREFIX + "amrwb_payload_type_int_array";
6675 
6676         /**
6677          * A list of integers representing the different payload types
6678          * in AMR-NB codec in priority order from highest to lowest.
6679          * <p>Payload type is an integer in dynamic payload type range 96-127
6680          * as per RFC RFC 3551 Section 6.
6681          */
6682         public static final String KEY_AMRNB_PAYLOAD_TYPE_INT_ARRAY =
6683                 KEY_PREFIX + "amrnb_payload_type_int_array";
6684 
6685         /**
6686          * A list of integers representing the different payload types
6687          * in DTMF WB codec in priority order from highest to lowest.
6688          * <p>Payload type is an integer in dynamic payload type range 96-127
6689          * as per RFC RFC 3551 Section 6.
6690          */
6691         public static final String KEY_DTMFWB_PAYLOAD_TYPE_INT_ARRAY =
6692                 KEY_PREFIX + "dtmfwb_payload_type_int_array";
6693 
6694         /**
6695          * A list of integers representing the different payload types
6696          * in DTMF NB codec in priority order from highest to lowest.
6697          * <p>Payload type is an integer in dynamic payload type range 96-127
6698          * as per RFC RFC 3551 Section 6.
6699          */
6700         public static final String KEY_DTMFNB_PAYLOAD_TYPE_INT_ARRAY =
6701                 KEY_PREFIX + "dtmfnb_payload_type_int_array";
6702 
6703         /**
6704          * This indicates the threshold for RTP packet loss rate in percentage. If measured packet
6705          * loss rate crosses this, a callback with {@link MediaQualityStatus} will be invoked to
6706          * listeners.
6707          * See {@link android.telephony.TelephonyCallback.MediaQualityStatusChangedListener}
6708          *
6709          * <p/>
6710          * Valid threshold range : 0 ~ 100
6711          *
6712          * @hide
6713          */
6714         public static final String KEY_VOICE_RTP_PACKET_LOSS_RATE_THRESHOLD_INT =
6715                 KEY_PREFIX + "rtp_packet_loss_rate_threshold_int";
6716 
6717         /**
6718          * This indicates the threshold for RTP jitter value in milliseconds (RFC3550). If measured
6719          * jitter value crosses this, a callback with {@link MediaQualityStatus} will be invoked
6720          * to listeners.
6721          * See {@link android.telephony.TelephonyCallback.MediaQualityStatusChangedListener}
6722          *
6723          * <p/>
6724          * Valid threshold range : 0 ~ 10000
6725          *
6726          * @hide
6727          */
6728         public static final String KEY_VOICE_RTP_JITTER_THRESHOLD_MILLIS_INT =
6729                 KEY_PREFIX + "rtp_jitter_threshold_millis_int";
6730 
6731         /**
6732          * This indicates the threshold for RTP inactivity time in milliseconds. If measured
6733          * inactivity timer crosses this, a callback with {@link MediaQualityStatus} will be invoked
6734          * to listeners.
6735          * See {@link android.telephony.TelephonyCallback.MediaQualityStatusChangedListener}
6736          *
6737          * <p/>
6738          * Valid threshold range : 0 ~ 60000
6739          *
6740          * @hide
6741          */
6742         public static final String KEY_VOICE_RTP_INACTIVITY_TIME_THRESHOLD_MILLIS_LONG =
6743                 KEY_PREFIX + "rtp_inactivity_time_threshold_millis_long";
6744 
6745         /** @hide */
6746         @IntDef({
6747             BANDWIDTH_EFFICIENT,
6748             OCTET_ALIGNED
6749         })
6750         public @interface AmrPayloadFormat {}
6751 
6752         /** AMR NB/WB Payload format is bandwidth-efficient. */
6753         public static final int BANDWIDTH_EFFICIENT = 0;
6754 
6755         /** AMR NB/WB Payload format is octet-aligned. */
6756         public static final int OCTET_ALIGNED = 1;
6757 
6758         /**
6759          * Specifies the payload format of the AMR-NB/AMR-WB codec.
6760          *
6761          * <p>Possible values are,
6762          * {@link #BANDWIDTH_EFFICIENT},
6763          * {@link #OCTET_ALIGNED}
6764 
6765          * <p>If value is not specified, payload format is
6766          * {@link #BANDWIDTH_EFFICIENT}.
6767          *
6768          * <p>Reference: RFC 4867 Section 8.1.
6769          */
6770         public static final String KEY_AMR_CODEC_ATTRIBUTE_PAYLOAD_FORMAT_INT =
6771                 KEY_PREFIX + "amr_codec_attribute_payload_format_int";
6772 
6773         /**
6774          * Restricts the active mode set to a subset of all modes in the codec.
6775          *
6776          * <p>This attribute is optional. If value is set, then session mode
6777          * set is restricted to the modes specified in this list. If this value
6778          * is not specified, then all available modes in the codec are allowed.
6779          * This attribute is applicable for AMR-WB, AMR-NB,
6780          * and EVS codec (operating in AMR-WB IO Mode).
6781          *
6782          * <p>Possible values are subset of,
6783          * [0,1,2,3,4,5,6,7,8] - AMRWB with the modes representing nine speech codec modes
6784          * with bit rates of 6.6, 8.85, 12.65, 14.25,  15.85, 18.25, 19.85, 23.05, 23.85 kbps.
6785          * [0,1,2,3,4,5,6,7] - AMRNB with the modes representing eight speech codec modes
6786          * with bit rates of 4.75, 5.15, 5.90, 6.70, 7.40, 7.95, 10.2, 12.2 kbps.
6787          *
6788          * <p>If value is not specified, then it means device supports all
6789          * modes in the codec but not included in SDP.
6790          *
6791          * <p>Reference: RFC 4867 Section 8.1, 3GPP 26.445 A.3.1
6792          */
6793         public static final String KEY_AMR_CODEC_ATTRIBUTE_MODESET_INT_ARRAY =
6794                 KEY_PREFIX + "amr_codec_attribute_modeset_int_array";
6795 
6796         /**
6797          * Specifies the codec attributes of different payload types in
6798          * the AMR NarrowBand (AMR-NB) codec.
6799          *
6800          * <p> The keys in this bundle are payload types specified
6801          * in {@link #KEY_AMRNB_PAYLOAD_TYPE_INT_ARRAY}.
6802          *
6803          * <p>Codec attributes allowed as part of AMR-NB codec bundle are,
6804          * <UL>
6805          *     <LI>{@link #KEY_AMR_CODEC_ATTRIBUTE_PAYLOAD_FORMAT_INT}</LI>
6806          *     <LI>{@link #KEY_AMR_CODEC_ATTRIBUTE_MODESET_INT_ARRAY}</LI>
6807          * </UL>
6808          *
6809          * <p> If this bundle is not configured and AMRNB payload type is added
6810          * in {@link #KEY_AMRNB_PAYLOAD_TYPE_INT_ARRAY}, then default
6811          * values as in the individual codec attribute to be used
6812          * for that payload type.
6813          */
6814         public static final String KEY_AMRNB_PAYLOAD_DESCRIPTION_BUNDLE =
6815                 KEY_PREFIX + "amrnb_payload_description_bundle";
6816 
6817         /**
6818          * Specifies the codec attributes of different payload types in
6819          * the AMR WideBand (AMR-WB) codec.
6820          *
6821          * <p> The keys in this bundle are payload types specified
6822          * in {@link #KEY_AMRWB_PAYLOAD_TYPE_INT_ARRAY}.
6823          *
6824          * <p>Codec attributes allowed as part of AMR-NB codec bundle are,
6825          * <UL>
6826          *     <LI>{@link #KEY_AMR_CODEC_ATTRIBUTE_PAYLOAD_FORMAT_INT}</LI>
6827          *     <LI>{@link #KEY_AMR_CODEC_ATTRIBUTE_MODESET_INT_ARRAY}</LI>
6828          * </UL>
6829          *
6830          * <p> If this bundle is not configured and AMRWB payload type is added
6831          * in {@link #KEY_AMRWB_PAYLOAD_TYPE_INT_ARRAY}, then default
6832          * values as in the individual codec attribute to be used
6833          * for that payload type.
6834          */
6835         public static final String KEY_AMRWB_PAYLOAD_DESCRIPTION_BUNDLE =
6836                 KEY_PREFIX + "amrwb_payload_description_bundle";
6837 
6838         /** @hide */
6839         @IntDef({
6840             EVS_OPERATIONAL_MODE_PRIMARY,
6841             EVS_OPERATIONAL_MODE_AMRWB_IO
6842         })
6843         public @interface EvsOperationalMode {}
6844 
6845         /**  Indicates the EVS primary mode. 3GPP 26.445 Section 3.1 */
6846         public static final int EVS_OPERATIONAL_MODE_PRIMARY = 0;
6847 
6848         /** Indicates the EVS AMR-WB IO mode. 3GPP 26.445 Section 3.1 */
6849         public static final int EVS_OPERATIONAL_MODE_AMRWB_IO = 1;
6850 
6851         /**
6852          * Specifies if the EVS mode used is EVS primary mode
6853          * or EVS AMR-WB IO mode.
6854          *
6855          * <p>Possible values are,
6856          * {@link #EVS_OPERATIONAL_MODE_PRIMARY},
6857          * {@link #EVS_OPERATIONAL_MODE_AMRWB_IO}
6858          *
6859          * <p>If this is not present, then {@link #EVS_OPERATIONAL_MODE_PRIMARY} is used.
6860          * <p>Reference: 3GPP 26.445 Section 3.1.
6861          */
6862         public static final String KEY_EVS_CODEC_ATTRIBUTE_MODE_SWITCH_INT =
6863                 KEY_PREFIX + "evs_codec_attribute_mode_switch_int";
6864 
6865         /** @hide */
6866         @IntDef({
6867             EVS_ENCODED_BW_TYPE_NB,
6868             EVS_ENCODED_BW_TYPE_WB,
6869             EVS_ENCODED_BW_TYPE_SWB,
6870             EVS_ENCODED_BW_TYPE_FB,
6871             EVS_ENCODED_BW_TYPE_NB_WB,
6872             EVS_ENCODED_BW_TYPE_NB_WB_SWB,
6873             EVS_ENCODED_BW_TYPE_NB_WB_SWB_FB,
6874             EVS_ENCODED_BW_TYPE_WB_SWB,
6875             EVS_ENCODED_BW_TYPE_WB_SWB_FB
6876         })
6877         public @interface EvsEncodedBwType {}
6878 
6879         /**
6880          * EVS encoded Bandwidth is Narrow Band (NB).
6881          * Reference: 3GPP 26.441 Table 1.
6882          */
6883         public static final int EVS_ENCODED_BW_TYPE_NB = 0;
6884 
6885         /**
6886          * EVS encoded Bandwidth is Wide Band (WB).
6887          * Reference: 3GPP 26.441 Table 1.
6888          */
6889         public static final int EVS_ENCODED_BW_TYPE_WB = 1;
6890 
6891         /**
6892          * EVS encoded Bandwidth is Super WideBand (SWB).
6893          * Reference: 3GPP 26.441 Table 1.
6894          */
6895         public static final int EVS_ENCODED_BW_TYPE_SWB = 2;
6896 
6897         /**
6898          * EVS encoded Bandwidth is Full Band (FB).
6899          * Reference: 3GPP 26.441 Table 1.
6900          */
6901         public static final int EVS_ENCODED_BW_TYPE_FB = 3;
6902 
6903         /**
6904          * EVS encoded Bandwidth is in the range NB,WB.
6905          * Reference: 3GPP 26.441 Table 1.
6906          */
6907         public static final int EVS_ENCODED_BW_TYPE_NB_WB = 4;
6908 
6909         /**
6910          * EVS encoded Bandwidth is in the range NB,WB,SWB.
6911          * Reference: 3GPP 26.441 Table 1.
6912          */
6913         public static final int EVS_ENCODED_BW_TYPE_NB_WB_SWB = 5;
6914 
6915         /**
6916          * EVS encoded Bandwidth is in the range NB,WB,SWB,FB.
6917          * Reference: 3GPP 26.441 Table 1.
6918          */
6919         public static final int EVS_ENCODED_BW_TYPE_NB_WB_SWB_FB = 6;
6920 
6921         /**
6922          * EVS encoded Bandwidth is in the range WB,SWB.
6923          * Reference: 3GPP 26.441 Table 1.
6924          */
6925         public static final int EVS_ENCODED_BW_TYPE_WB_SWB = 7;
6926 
6927         /**
6928          * EVS encoded Bandwidth is in the range WB,SWB,FB.
6929          * Reference: 3GPP 26.441 Table 1.
6930          */
6931         public static final int EVS_ENCODED_BW_TYPE_WB_SWB_FB = 8;
6932 
6933         /**
6934          * Specifies the EVS codec encoding bandwidth options.
6935          *
6936          * Possible values are,
6937          * {@link #EVS_ENCODED_BW_TYPE_NB},
6938          * {@link #EVS_ENCODED_BW_TYPE_WB},
6939          * {@link #EVS_ENCODED_BW_TYPE_SWB},
6940          * {@link #EVS_ENCODED_BW_TYPE_FB},
6941          * {@link #EVS_ENCODED_BW_TYPE_NB_WB},
6942          * {@link #EVS_ENCODED_BW_TYPE_NB_WB_SWB},
6943          * {@link #EVS_ENCODED_BW_TYPE_NB_WB_SWB_FB},
6944          * {@link #EVS_ENCODED_BW_TYPE_WB_SWB},
6945          * {@link #EVS_ENCODED_BW_TYPE_WB_SWB_FB}
6946          *
6947          * If this key is not specified, then the behavior is same as
6948          * value {@link #EVS_ENCODED_BW_TYPE_NB_WB_SWB}
6949          *
6950          * <p>Reference: 3GPP 26.441 Table 1.
6951          */
6952         public static final String KEY_EVS_CODEC_ATTRIBUTE_BANDWIDTH_INT =
6953                 KEY_PREFIX + "evs_codec_attribute_bandwidth_int";
6954 
6955         /** @hide */
6956         @IntDef({
6957             EVS_PRIMARY_MODE_BITRATE_5_9_KBPS,
6958             EVS_PRIMARY_MODE_BITRATE_7_2_KBPS,
6959             EVS_PRIMARY_MODE_BITRATE_8_0_KBPS,
6960             EVS_PRIMARY_MODE_BITRATE_9_6_KBPS,
6961             EVS_PRIMARY_MODE_BITRATE_13_2_KBPS,
6962             EVS_PRIMARY_MODE_BITRATE_16_4_KBPS,
6963             EVS_PRIMARY_MODE_BITRATE_24_4_KBPS,
6964             EVS_PRIMARY_MODE_BITRATE_32_0_KBPS,
6965             EVS_PRIMARY_MODE_BITRATE_48_0_KBPS,
6966             EVS_PRIMARY_MODE_BITRATE_64_0_KBPS,
6967             EVS_PRIMARY_MODE_BITRATE_96_0_KBPS,
6968             EVS_PRIMARY_MODE_BITRATE_128_0_KBPS
6969         })
6970         public @interface EvsPrimaryModeBitRate {}
6971 
6972         /** EVS primary mode with bitrate 5.9 kbps */
6973         public static final int EVS_PRIMARY_MODE_BITRATE_5_9_KBPS = 0;
6974 
6975         /** EVS primary mode with bitrate 7.2 kbps */
6976         public static final int EVS_PRIMARY_MODE_BITRATE_7_2_KBPS = 1;
6977 
6978         /** EVS primary mode with bitrate 8.0 kbps */
6979         public static final int EVS_PRIMARY_MODE_BITRATE_8_0_KBPS = 2;
6980 
6981         /** EVS primary mode with bitrate 9.6 kbps */
6982         public static final int EVS_PRIMARY_MODE_BITRATE_9_6_KBPS = 3;
6983 
6984         /** EVS primary mode with bitrate 13.2 kbps */
6985         public static final int EVS_PRIMARY_MODE_BITRATE_13_2_KBPS = 4;
6986 
6987         /** EVS primary mode with bitrate 16.4 kbps */
6988         public static final int EVS_PRIMARY_MODE_BITRATE_16_4_KBPS = 5;
6989 
6990         /** EVS primary mode with bitrate 24.4 kbps */
6991         public static final int EVS_PRIMARY_MODE_BITRATE_24_4_KBPS = 6;
6992 
6993         /** EVS primary mode with bitrate 32.0 kbps */
6994         public static final int EVS_PRIMARY_MODE_BITRATE_32_0_KBPS = 7;
6995 
6996         /** EVS primary mode with bitrate 48.0 kbps */
6997         public static final int EVS_PRIMARY_MODE_BITRATE_48_0_KBPS = 8;
6998 
6999         /** EVS primary mode with bitrate 64.0 kbps */
7000         public static final int EVS_PRIMARY_MODE_BITRATE_64_0_KBPS = 9;
7001 
7002         /** EVS primary mode with bitrate 96.0 kbps */
7003         public static final int EVS_PRIMARY_MODE_BITRATE_96_0_KBPS = 10;
7004 
7005         /** EVS primary mode with bitrate 128.0 kbps */
7006         public static final int EVS_PRIMARY_MODE_BITRATE_128_0_KBPS = 11;
7007 
7008         /**
7009          * Specifies the range of source codec bit-rate for EVS Primary mode
7010          * in the session. This is expressed in kilobits per second and
7011          * applicable for both the send and the receive directions.
7012          *
7013          * <p>The range is specified as integer aray of size 2,
7014          * represented as [low, high], where low <= high
7015          *
7016          * <p>Possible values for low and high are,
7017          * {@link #EVS_PRIMARY_MODE_BITRATE_5_9_KBPS},
7018          * {@link #EVS_PRIMARY_MODE_BITRATE_7_2_KBPS},
7019          * {@link #EVS_PRIMARY_MODE_BITRATE_8_0_KBPS},
7020          * {@link #EVS_PRIMARY_MODE_BITRATE_9_6_KBPS},
7021          * {@link #EVS_PRIMARY_MODE_BITRATE_13_2_KBPS},
7022          * {@link #EVS_PRIMARY_MODE_BITRATE_16_4_KBPS},
7023          * {@link #EVS_PRIMARY_MODE_BITRATE_24_4_KBPS},
7024          * {@link #EVS_PRIMARY_MODE_BITRATE_32_0_KBPS},
7025          * {@link #EVS_PRIMARY_MODE_BITRATE_48_0_KBPS},
7026          * {@link #EVS_PRIMARY_MODE_BITRATE_64_0_KBPS},
7027          * {@link #EVS_PRIMARY_MODE_BITRATE_96_0_KBPS},
7028          * {@link #EVS_PRIMARY_MODE_BITRATE_128_0_KBPS}
7029          *
7030          * If this key is not specified, then the behavior is same as
7031          * value {@link #EVS_PRIMARY_MODE_BITRATE_24_4_KBPS}
7032          *
7033          * <p>Reference: 3GPP 26.445 Section A.3.1
7034          */
7035         public static final String KEY_EVS_CODEC_ATTRIBUTE_BITRATE_INT_ARRAY =
7036                 KEY_PREFIX + "evs_codec_attribute_bitrate_int_array";
7037 
7038         /**
7039          * Specifies the Channel aware mode (ch-aw-recv) for the receive direction.
7040          * This is applicable for EVS codec.
7041          *
7042          * <p> Permissible values are -1, 0, 2, 3, 5, and 7.
7043          * If this key is not specified, then the behavior is same as value 0
7044          * (channel aware mode disabled).
7045          * <p> If this key is configured, then device is expected to send
7046          * this parameter in the SDP offer.
7047          *
7048          * <p>Reference: 3GPP TS 26.445 section 4.4.5, 3GPP 26.445 Section A.3.1
7049          */
7050         public static final String KEY_EVS_CODEC_ATTRIBUTE_CH_AW_RECV_INT =
7051                 KEY_PREFIX + "evs_codec_attribute_ch_aw_recv_int";
7052 
7053         /**
7054          * Specifies whether to limit the session to header-full format.
7055          * This applies to both directions in the session. This attribute
7056          * is applicable for EVS codec.
7057          *
7058          * <p>Permissible values are 0, 1
7059          * If hf-only is 1, only Header-Full format is used and hf-only is
7060          * included in the SDP.
7061          * <p>If hf-only is 0, both Compact and Header-Full formats are used
7062          * and hf-only is included in the SDP.
7063          * <p>If this key is not present, then both Compact
7064          * and Header-Full formats are used and hf-only is not included in
7065          * the SDP.
7066          * <p> If this key is configured, then device is expected to send
7067          * this parameter in the SDP offer if operator required it.
7068          *
7069          * <p>Reference: 3GPP 26.445 Section A.3.1.
7070          */
7071         public static final String KEY_EVS_CODEC_ATTRIBUTE_HF_ONLY_INT =
7072                 KEY_PREFIX + "evs_codec_attribute_hf_only_int";
7073 
7074         /**
7075          * Specifies whether DTX (Discontinuous transmission) is enabled
7076          * or not. This applies to both directions in the session.
7077          * This attribute is applicable for EVS codec and can be used
7078          * in both EVS Primary mode and EVS AMR-WB IO mode.
7079          *
7080          * <p>If {@code true}: Indicates DTX is enabled.
7081          * If {@code false}: Indicates DTX is disabled.
7082          *
7083          * <p>If this is not present, then default value of {@code true}
7084          * will apply.
7085          * <p>Reference: 3GPP TS 26.445 Section A.3.1.
7086          */
7087         public static final String KEY_EVS_CODEC_ATTRIBUTE_DTX_BOOL =
7088                 KEY_PREFIX + "evs_codec_attribute_dtx_bool";
7089 
7090         /**
7091          * This is used if further restriction is required on DTX in the
7092          * receive direction. This attribute is applicable for EVS codec
7093          * and can be used in both EVS Primary mode and EVS AMR-WB IO mode.
7094          *
7095          * <p> If this value is true or not present, then DTX setting is
7096          * dependent on {@link #KEY_EVS_CODEC_ATTRIBUTE_DTX_BOOL}.
7097          *
7098          * <p> If this is not present, then default value of {@code true}
7099          * will apply.
7100          *
7101          * <p>Reference: 3GPP TS 26.445 Section A.3.1.
7102          */
7103         public static final String KEY_EVS_CODEC_ATTRIBUTE_DTX_RECV_BOOL =
7104                 KEY_PREFIX + "evs_codec_attribute_dtx_recv_bool";
7105 
7106         /**
7107          * Specifies the number of audio channels.
7108          * If this is not present, then default value of 1 will apply.
7109          *
7110          * <p>Reference: RFC 3551
7111          */
7112         public static final String KEY_EVS_CODEC_ATTRIBUTE_CHANNELS_INT =
7113                 KEY_PREFIX + "evs_codec_attribute_channels_int";
7114 
7115         /**
7116          * Indicates whether the Codec Mode Request (CMR) is supported
7117          * for the session.
7118          * This attribute is applicable for EVS codec in Primary Mode only.
7119          *
7120          * <p>Possible values are -1, 0, 1. If this key is not present,
7121          * then behavior as per value 0 is applicable.
7122          *
7123          * <p>Reference: 3GPP 26.445 Section A.3.1, 3GPP 26.114 Table 6.2a
7124          */
7125         public static final String KEY_EVS_CODEC_ATTRIBUTE_CMR_INT =
7126                 KEY_PREFIX + "codec_attribute_cmr_int";
7127 
7128         /**
7129          * Specifies the number of frame-blocks. This indicates the frame-block period
7130          * at which codec mode changes are allowed for the sender. This attribute is
7131          * applicable for EVS codec in AMR-WB IO mode and AMR-WB.
7132          *
7133          * <p>Possible values are 1, 2.
7134          * If the key is not present, behavior as per value 1 is applicable and this
7135          * parameter is not included in SDP.
7136          *
7137          * <p>Reference: RFC 4867 Section 8.1.
7138          */
7139         public static final String KEY_CODEC_ATTRIBUTE_MODE_CHANGE_PERIOD_INT =
7140                 KEY_PREFIX + "codec_attribute_mode_change_period_int";
7141 
7142         /**
7143          * Specifies if the client is capable to transmit with a restricted mode
7144          * change period. This attribute is applicable for EVS codec in
7145          * AMR-WB IO mode and AMR-WB.
7146          *
7147          * <p>Possible values are 1, 2. If this key is not present,
7148          * then behavior as per value 1 is applicable and this
7149          * parameter is not included in SDP.
7150          *
7151          * <p>Reference: RFC 4867 Section 8.1.
7152          */
7153         public static final String KEY_CODEC_ATTRIBUTE_MODE_CHANGE_CAPABILITY_INT =
7154                 KEY_PREFIX + "codec_attribute_mode_change_capability_int";
7155 
7156         /**
7157          * Specifies the allowed mode changes for the sender in the active mode set.
7158          * This attribute is applicable for EVS codec in AMR-WB IO mode
7159          * and AMR-WB.
7160          *
7161          * <p>Possible values are 0, 1. If value is 1, then the sender should only
7162          * perform mode changes to the neighboring modes in the active codec mode set.
7163          * If value is 0, then mode changes between any two modes
7164          * in the active codec mode set is allowed.
7165          * If the key is not present, behavior as per value 0 is applicable and this
7166          * parameter is not included in SDP.
7167          *
7168          * <p>Reference: RFC 4867 Section 8.1.
7169          */
7170         public static final String KEY_CODEC_ATTRIBUTE_MODE_CHANGE_NEIGHBOR_INT =
7171                 KEY_PREFIX + "codec_attribute_mode_change_neighbor_int";
7172 
7173         /**
7174          * Specifies the codec attributes of different payload types in
7175          * the EVS codec.
7176          *
7177          * <p> The keys in this bundle are payload types specified
7178          * in {@link #KEY_EVS_PAYLOAD_TYPE_INT_ARRAY}.
7179          *
7180          * <p>Codec attributes allowed as part of EVS codec are,
7181          * <UL>
7182          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_BANDWIDTH_INT}</LI>
7183          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_BITRATE_INT_ARRAY}</LI>
7184          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_CH_AW_RECV_INT}</LI>
7185          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_HF_ONLY_INT}</LI>
7186          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_DTX_BOOL}</LI>
7187          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_DTX_RECV_BOOL}</LI>
7188          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_MODE_SWITCH_INT}</LI>
7189          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_CMR_INT}</LI>
7190          *     <LI>{@link #KEY_EVS_CODEC_ATTRIBUTE_CHANNELS_INT}</LI>
7191          *     <LI>{@link #KEY_CODEC_ATTRIBUTE_MODE_CHANGE_PERIOD_INT}</LI>
7192          *     <LI>{@link #KEY_CODEC_ATTRIBUTE_MODE_CHANGE_CAPABILITY_INT}</LI>
7193          *     <LI>{@link #KEY_CODEC_ATTRIBUTE_MODE_CHANGE_NEIGHBOR_INT}</LI>
7194          * </UL>
7195          */
7196         public static final String KEY_EVS_PAYLOAD_DESCRIPTION_BUNDLE =
7197                 KEY_PREFIX + "evs_payload_description_bundle";
7198 
getDefaults()7199         private static PersistableBundle getDefaults() {
7200             PersistableBundle defaults = new PersistableBundle();
7201             defaults.putBoolean(KEY_CARRIER_VOLTE_ROAMING_AVAILABLE_BOOL, true);
7202             defaults.putBoolean(KEY_INCLUDE_CALLER_ID_SERVICE_CODES_IN_SIP_INVITE_BOOL, false);
7203             defaults.putBoolean(KEY_MULTIENDPOINT_SUPPORTED_BOOL, false);
7204             defaults.putBoolean(KEY_SESSION_TIMER_SUPPORTED_BOOL, true);
7205             defaults.putBoolean(KEY_OIP_SOURCE_FROM_HEADER_BOOL, false);
7206             defaults.putBoolean(KEY_PRACK_SUPPORTED_FOR_18X_BOOL, false);
7207             defaults.putBoolean(KEY_VOICE_QOS_PRECONDITION_SUPPORTED_BOOL, true);
7208             defaults.putBoolean(KEY_VOICE_ON_DEFAULT_BEARER_SUPPORTED_BOOL, false);
7209 
7210             defaults.putInt(KEY_SESSION_REFRESHER_TYPE_INT, SESSION_REFRESHER_TYPE_UAC);
7211             defaults.putInt(KEY_SESSION_PRIVACY_TYPE_INT, SESSION_PRIVACY_TYPE_HEADER);
7212             defaults.putInt(KEY_SESSION_REFRESH_METHOD_INT,
7213                             SESSION_REFRESH_METHOD_UPDATE_PREFERRED);
7214             defaults.putInt(KEY_CONFERENCE_SUBSCRIBE_TYPE_INT,
7215                             CONFERENCE_SUBSCRIBE_TYPE_OUT_OF_DIALOG);
7216             defaults.putInt(KEY_AUDIO_RTP_INACTIVITY_TIMER_MILLIS_INT, 20000);
7217             defaults.putInt(KEY_AUDIO_RTCP_INACTIVITY_TIMER_MILLIS_INT, 20000);
7218             defaults.putInt(KEY_DEDICATED_BEARER_WAIT_TIMER_MILLIS_INT, 8000);
7219             defaults.putInt(KEY_RINGING_TIMER_MILLIS_INT, 90000);
7220             defaults.putInt(KEY_RINGBACK_TIMER_MILLIS_INT, 90000);
7221             defaults.putInt(KEY_MO_CALL_REQUEST_TIMEOUT_MILLIS_INT, 5000);
7222             defaults.putInt(KEY_SESSION_EXPIRES_TIMER_SEC_INT, 1800);
7223             defaults.putInt(KEY_MINIMUM_SESSION_EXPIRES_TIMER_SEC_INT, 90);
7224             defaults.putInt(KEY_AUDIO_AS_BANDWIDTH_KBPS_INT, 41);
7225             defaults.putInt(KEY_AUDIO_RS_BANDWIDTH_BPS_INT, 600);
7226             defaults.putInt(KEY_AUDIO_RR_BANDWIDTH_BPS_INT, 2000);
7227             defaults.putInt(KEY_VOICE_RTP_PACKET_LOSS_RATE_THRESHOLD_INT, 40);
7228             defaults.putInt(KEY_VOICE_RTP_JITTER_THRESHOLD_MILLIS_INT, 120);
7229             defaults.putLong(KEY_VOICE_RTP_INACTIVITY_TIME_THRESHOLD_MILLIS_LONG, 5000);
7230 
7231             defaults.putIntArray(
7232                     KEY_AUDIO_INACTIVITY_CALL_END_REASONS_INT_ARRAY,
7233                     new int[] {
7234                         Ims.RTCP_INACTIVITY_ON_CONNECTED,
7235                         Ims.RTP_INACTIVITY_ON_CONNECTED,
7236                         Ims.E911_RTCP_INACTIVITY_ON_CONNECTED,
7237                         Ims.RTCP_INACTIVITY_ON_HOLD
7238                     });
7239 
7240             defaults.putIntArray(
7241                     KEY_SRVCC_TYPE_INT_ARRAY,
7242                     new int[] {
7243                         BASIC_SRVCC_SUPPORT,
7244                         ALERTING_SRVCC_SUPPORT,
7245                         PREALERTING_SRVCC_SUPPORT,
7246                         MIDCALL_SRVCC_SUPPORT
7247                     });
7248 
7249             defaults.putString(KEY_CONFERENCE_FACTORY_URI_STRING, "");
7250 
7251             PersistableBundle audio_codec_capability_payload_types = new PersistableBundle();
7252 
7253             audio_codec_capability_payload_types.putIntArray(
7254                     KEY_AMRWB_PAYLOAD_TYPE_INT_ARRAY,
7255                     new int[] { 97, 98 });
7256 
7257             audio_codec_capability_payload_types.putIntArray(
7258                     KEY_AMRNB_PAYLOAD_TYPE_INT_ARRAY,
7259                     new int[] { 99, 100 });
7260 
7261             audio_codec_capability_payload_types.putIntArray(
7262                     KEY_DTMFWB_PAYLOAD_TYPE_INT_ARRAY,
7263                     new int[] { 101 });
7264 
7265             audio_codec_capability_payload_types.putIntArray(
7266                     KEY_DTMFNB_PAYLOAD_TYPE_INT_ARRAY,
7267                     new int[] { 102 });
7268 
7269             defaults.putPersistableBundle(
7270                     KEY_AUDIO_CODEC_CAPABILITY_PAYLOAD_TYPES_BUNDLE,
7271                     audio_codec_capability_payload_types);
7272 
7273             /* Setting defaults for AMRWB */
7274             PersistableBundle all_amrwb_payload_bundles = new PersistableBundle();
7275             PersistableBundle amrwb_bundle_instance1 = new PersistableBundle();
7276 
7277             all_amrwb_payload_bundles.putPersistableBundle(
7278                     "97", /* Same value of payload type as in KEY_AMRWB_PAYLOAD_TYPE_INT_ARRAY */
7279                     amrwb_bundle_instance1);
7280 
7281             PersistableBundle amrwb_bundle_instance2 = new PersistableBundle();
7282 
7283             amrwb_bundle_instance2.putInt(KEY_AMR_CODEC_ATTRIBUTE_PAYLOAD_FORMAT_INT,
7284                                           OCTET_ALIGNED);
7285 
7286             all_amrwb_payload_bundles.putPersistableBundle(
7287                     "98", /* Same value of payload type as in KEY_AMRWB_PAYLOAD_TYPE_INT_ARRAY */
7288                     amrwb_bundle_instance2);
7289 
7290             defaults.putPersistableBundle(
7291                     KEY_AMRWB_PAYLOAD_DESCRIPTION_BUNDLE,
7292                     all_amrwb_payload_bundles);
7293 
7294             /* Setting defaults for AMRNB */
7295             PersistableBundle all_amrnb_payload_bundles = new PersistableBundle();
7296             PersistableBundle amrnb_bundle_instance1 = new PersistableBundle();
7297 
7298             all_amrnb_payload_bundles.putPersistableBundle(
7299                     "99", /* Same value of payload type as in KEY_AMRNB_PAYLOAD_TYPE_INT_ARRAY */
7300                     amrnb_bundle_instance1);
7301 
7302             PersistableBundle amrnb_bundle_instance2 = new PersistableBundle();
7303 
7304             amrnb_bundle_instance2.putInt(KEY_AMR_CODEC_ATTRIBUTE_PAYLOAD_FORMAT_INT,
7305                                           OCTET_ALIGNED);
7306 
7307             all_amrnb_payload_bundles.putPersistableBundle(
7308                     "100", /* Same value of payload type as in KEY_AMRNB_PAYLOAD_TYPE_INT_ARRAY */
7309                     amrnb_bundle_instance2);
7310 
7311             defaults.putPersistableBundle(
7312                     KEY_AMRNB_PAYLOAD_DESCRIPTION_BUNDLE,
7313                     all_amrnb_payload_bundles);
7314 
7315             return defaults;
7316         }
7317     }
7318 
7319     /**
7320      * IMS SMS configs. This groups the configs specific for SMS over IMS
7321      */
7322     public static final class ImsSms {
ImsSms()7323         private ImsSms() {}
7324 
7325         /** Prefix of all imssms.KEY_* constants. */
7326         public static final String KEY_PREFIX = "imssms.";
7327 
7328         /**
7329          * Flag specifying if SMS over IMS support is available or not.
7330          *
7331          * <p>If {@code true}: SMS over IMS support available.
7332          * {@code false}: otherwise.
7333          */
7334         public static final String KEY_SMS_OVER_IMS_SUPPORTED_BOOL =
7335                 KEY_PREFIX + "sms_over_ims_supported_bool";
7336 
7337         /**
7338          * Flag specifying whether to allow SMS CSFB in case of
7339          * SMS over PS failure.
7340          *
7341          * <p>If {@code true}: allow SMS CSFB in case of SMS over PS failure.
7342          * {@code false} otherwise.
7343          */
7344         public static final String KEY_SMS_CSFB_RETRY_ON_FAILURE_BOOL =
7345                 KEY_PREFIX + "sms_csfb_retry_on_failure_bool";
7346 
7347         /** @hide */
7348         @IntDef({
7349             SMS_FORMAT_3GPP,
7350             SMS_FORMAT_3GPP2
7351         })
7352         public @interface SmsFormat {}
7353 
7354         /** SMS format is 3GPP. */
7355         public static final int SMS_FORMAT_3GPP = 0;
7356 
7357         /** SMS format is 3GPP2. */
7358         public static final int SMS_FORMAT_3GPP2 = 1;
7359 
7360         /**
7361          * Specifies the SMS over IMS format.
7362          *
7363          * <p>Possible values are,
7364          * {@link #SMS_FORMAT_3GPP},
7365          * {@link #SMS_FORMAT_3GPP2}
7366          */
7367         public static final String KEY_SMS_OVER_IMS_FORMAT_INT =
7368                 KEY_PREFIX + "sms_over_ims_format_int";
7369 
7370         /**
7371          * List of different RAT technologies on which SMS over IMS
7372          * is supported.
7373          *
7374          * <p>Possible values are,
7375          * {@link AccessNetworkConstants.AccessNetworkType#NGRAN}
7376          * {@link AccessNetworkConstants.AccessNetworkType#EUTRAN}
7377          * {@link AccessNetworkConstants.AccessNetworkType#IWLAN}
7378          * {@link AccessNetworkConstants.AccessNetworkType#UTRAN}
7379          * {@link AccessNetworkConstants.AccessNetworkType#GERAN}
7380          */
7381         public static final String KEY_SMS_OVER_IMS_SUPPORTED_RATS_INT_ARRAY =
7382                 KEY_PREFIX + "sms_over_ims_supported_rats_int_array";
7383 
7384         /**
7385          * Maximum Retry Count for Failure, If the Retry Count exceeds this value,
7386          * it must display to User Interface as sending failed
7387          */
7388         public static final String KEY_SMS_MAX_RETRY_COUNT_INT =
7389                 KEY_PREFIX + "sms_max_retry_count_int";
7390 
7391         /**
7392          * Maximum Retry Count for SMS over IMS on Failure, If the Retry Count exceeds this value,
7393          * and if the retry count is less than {@link #KEY_SMS_MAX_RETRY_COUNT_INT}
7394          * sending SMS should fallback to CS
7395          */
7396         public static final String KEY_SMS_MAX_RETRY_OVER_IMS_COUNT_INT =
7397                 KEY_PREFIX + "sms_max_retry_over_ims_count_int";
7398 
7399         /**
7400          * Delay Timer Value in milliseconds
7401          * Retry SMS over IMS after this Timer expires
7402          */
7403         public static final String KEY_SMS_OVER_IMS_SEND_RETRY_DELAY_MILLIS_INT =
7404                 KEY_PREFIX + "sms_over_ims_send_retry_delay_millis_int";
7405 
7406         /**
7407          * TR1 Timer Value in milliseconds,
7408          * Waits for RP-Ack from network for MO SMS.
7409          */
7410         public static final String KEY_SMS_TR1_TIMER_MILLIS_INT =
7411                 KEY_PREFIX + "sms_tr1_timer_millis_int";
7412 
7413         /**
7414          * TR2 Timer Value in milliseconds,
7415          * Waits for RP-Ack from Transfer Layer for MT SMS.
7416          */
7417         public static final String KEY_SMS_TR2_TIMER_MILLIS_INT =
7418                 KEY_PREFIX + "sms_tr2_timer_millis_int";
7419 
7420         /**
7421          * SMS RP-Cause Values for which SMS should be retried over IMS
7422          *
7423          * <p>Possible values are,
7424          * {@link SmsManager#SMS_RP_CAUSE_UNALLOCATED_NUMBER}
7425          * {@link SmsManager#SMS_RP_CAUSE_OPERATOR_DETERMINED_BARRING}
7426          * {@link SmsManager#SMS_RP_CAUSE_CALL_BARRING}
7427          * {@link SmsManager#SMS_RP_CAUSE_RESERVED}
7428          * {@link SmsManager#SMS_RP_CAUSE_SHORT_MESSAGE_TRANSFER_REJECTED}
7429          * {@link SmsManager#SMS_RP_CAUSE_DESTINATION_OUT_OF_ORDER}
7430          * {@link SmsManager#SMS_RP_CAUSE_UNIDENTIFIED_SUBSCRIBER}
7431          * {@link SmsManager#SMS_RP_CAUSE_FACILITY_REJECTED}
7432          * {@link SmsManager#SMS_RP_CAUSE_UNKNOWN_SUBSCRIBER}
7433          * {@link SmsManager#SMS_RP_CAUSE_NETWORK_OUT_OF_ORDER}
7434          * {@link SmsManager#SMS_RP_CAUSE_TEMPORARY_FAILURE}
7435          * {@link SmsManager#SMS_RP_CAUSE_CONGESTION}
7436          * {@link SmsManager#SMS_RP_CAUSE_RESOURCES_UNAVAILABLE}
7437          * {@link SmsManager#SMS_RP_CAUSE_FACILITY_NOT_SUBSCRIBED}
7438          * {@link SmsManager#SMS_RP_CAUSE_FACILITY_NOT_IMPLEMENTED}
7439          * {@link SmsManager#SMS_RP_CAUSE_INVALID_MESSAGE_REFERENCE_VALUE}
7440          * {@link SmsManager#SMS_RP_CAUSE_SEMANTICALLY_INCORRECT_MESSAGE}
7441          * {@link SmsManager#SMS_RP_CAUSE_INVALID_MANDATORY_INFORMATION}
7442          * {@link SmsManager#SMS_RP_CAUSE_MESSAGE_TYPE_NON_EXISTENT}
7443          * {@link SmsManager#SMS_RP_CAUSE_MESSAGE_INCOMPATIBLE_WITH_PROTOCOL_STATE}
7444          * {@link SmsManager#SMS_RP_CAUSE_INFORMATION_ELEMENT_NON_EXISTENT}
7445          * {@link SmsManager#SMS_RP_CAUSE_PROTOCOL_ERROR}
7446          * {@link SmsManager#SMS_RP_CAUSE_INTERWORKING_UNSPECIFIED
7447          */
7448         public static final String KEY_SMS_RP_CAUSE_VALUES_TO_RETRY_OVER_IMS_INT_ARRAY =
7449                 KEY_PREFIX + "sms_rp_cause_values_to_retry_over_ims_int_array";
7450 
7451         /**
7452          * SMS RP-Cause Values for which Sending SMS should fallback
7453          */
7454         public static final String KEY_SMS_RP_CAUSE_VALUES_TO_FALLBACK_INT_ARRAY =
7455                 KEY_PREFIX + "sms_rp_cause_values_to_fallback_int_array";
7456 
getDefaults()7457         private static PersistableBundle getDefaults() {
7458             PersistableBundle defaults = new PersistableBundle();
7459             defaults.putBoolean(KEY_SMS_OVER_IMS_SUPPORTED_BOOL, true);
7460             defaults.putBoolean(KEY_SMS_CSFB_RETRY_ON_FAILURE_BOOL, true);
7461 
7462             defaults.putInt(KEY_SMS_OVER_IMS_FORMAT_INT, SMS_FORMAT_3GPP);
7463 
7464             defaults.putInt(KEY_SMS_MAX_RETRY_COUNT_INT, 3);
7465             defaults.putInt(KEY_SMS_MAX_RETRY_OVER_IMS_COUNT_INT, 3);
7466             defaults.putInt(KEY_SMS_OVER_IMS_SEND_RETRY_DELAY_MILLIS_INT,
7467                     2000);
7468             defaults.putInt(KEY_SMS_TR1_TIMER_MILLIS_INT, 130000);
7469             defaults.putInt(KEY_SMS_TR2_TIMER_MILLIS_INT, 15000);
7470 
7471             defaults.putIntArray(
7472                     KEY_SMS_RP_CAUSE_VALUES_TO_RETRY_OVER_IMS_INT_ARRAY,
7473                     new int[] {
7474                         SmsManager.SMS_RP_CAUSE_TEMPORARY_FAILURE
7475                     });
7476             defaults.putIntArray(
7477                     KEY_SMS_RP_CAUSE_VALUES_TO_FALLBACK_INT_ARRAY,
7478                     new int[] {
7479                         SmsManager.SMS_RP_CAUSE_UNALLOCATED_NUMBER,
7480                         SmsManager.SMS_RP_CAUSE_OPERATOR_DETERMINED_BARRING,
7481                         SmsManager.SMS_RP_CAUSE_CALL_BARRING,
7482                         SmsManager.SMS_RP_CAUSE_RESERVED,
7483                         SmsManager.SMS_RP_CAUSE_SHORT_MESSAGE_TRANSFER_REJECTED,
7484                         SmsManager.SMS_RP_CAUSE_DESTINATION_OUT_OF_ORDER,
7485                         SmsManager.SMS_RP_CAUSE_UNIDENTIFIED_SUBSCRIBER,
7486                         SmsManager.SMS_RP_CAUSE_FACILITY_REJECTED,
7487                         SmsManager.SMS_RP_CAUSE_UNKNOWN_SUBSCRIBER,
7488                         SmsManager.SMS_RP_CAUSE_NETWORK_OUT_OF_ORDER,
7489                         SmsManager.SMS_RP_CAUSE_CONGESTION,
7490                         SmsManager.SMS_RP_CAUSE_RESOURCES_UNAVAILABLE,
7491                         SmsManager.SMS_RP_CAUSE_FACILITY_NOT_SUBSCRIBED,
7492                         SmsManager.SMS_RP_CAUSE_FACILITY_NOT_IMPLEMENTED,
7493                         SmsManager.SMS_RP_CAUSE_INVALID_MESSAGE_REFERENCE_VALUE,
7494                         SmsManager.SMS_RP_CAUSE_SEMANTICALLY_INCORRECT_MESSAGE,
7495                         SmsManager.SMS_RP_CAUSE_INVALID_MANDATORY_INFORMATION,
7496                         SmsManager.SMS_RP_CAUSE_MESSAGE_TYPE_NON_EXISTENT,
7497                         SmsManager.SMS_RP_CAUSE_MESSAGE_INCOMPATIBLE_WITH_PROTOCOL_STATE,
7498                         SmsManager.SMS_RP_CAUSE_INFORMATION_ELEMENT_NON_EXISTENT,
7499                         SmsManager.SMS_RP_CAUSE_PROTOCOL_ERROR,
7500                         SmsManager.SMS_RP_CAUSE_INTERWORKING_UNSPECIFIED
7501                     });
7502 
7503             defaults.putIntArray(
7504                     KEY_SMS_OVER_IMS_SUPPORTED_RATS_INT_ARRAY,
7505                     new int[] {
7506                         AccessNetworkType.EUTRAN,
7507                         AccessNetworkType.IWLAN
7508                     });
7509 
7510             return defaults;
7511         }
7512     }
7513 
7514     /**
7515      * IMS RTT configs. This groups the configs specific for text media,
7516      * RTT (Real Time Text).
7517      */
7518     public static final class ImsRtt {
ImsRtt()7519         private ImsRtt() {}
7520 
7521         /** Prefix of all imsrtt.KEY_* constants. */
7522         public static final String KEY_PREFIX = "imsrtt.";
7523 
7524         /**
7525          * Flag specifying whether text media is allowed on default bearer.
7526          *
7527          * <p>If {@code true}: text media can be sent on default bearer.
7528          * {@code false} otherwise.
7529          */
7530         public static final String KEY_TEXT_ON_DEFAULT_BEARER_SUPPORTED_BOOL =
7531                 KEY_PREFIX + "text_on_default_bearer_supported_bool";
7532 
7533         /**
7534          * Flag specifying whether QoS preconditions are supported for text.
7535          *
7536          * <p>If {@code true}: QoS Preconditions are supported.
7537          * {@code false} otherwise.
7538          * <p>Reference: 3GPP TS 24.229
7539          */
7540         public static final String KEY_TEXT_QOS_PRECONDITION_SUPPORTED_BOOL =
7541                 KEY_PREFIX + "text_qos_precondition_supported_bool";
7542 
7543         /**
7544          * Specifies the AS (Application Specific) SDP modifier for text media.
7545          *
7546          * <p>Expressed in kilobits per second as per RFC 3556 Section 2.
7547          */
7548         public static final String KEY_TEXT_AS_BANDWIDTH_KBPS_INT =
7549                 KEY_PREFIX + "text_as_bandwidth_kbps_int";
7550 
7551         /**
7552          * Specifies the RS (RTCP bandwidth-Sender) SDP modifier for text media.
7553          *
7554          * <p>This indicates the RTCP bandwidth allocated to active data senders
7555          * for text media.
7556          *
7557          * <p>Expressed in bits per second as per RFC 3556 Section 2.
7558          */
7559         public static final String KEY_TEXT_RS_BANDWIDTH_BPS_INT =
7560                 KEY_PREFIX + "text_rs_bandwidth_bps_int";
7561 
7562         /**
7563          * Specifies the RR (RTCP bandwidth-Receiver) SDP modifier for
7564          * text media.
7565          *
7566          * <p>This indicates the RTCP bandwidth allocated to receivers
7567          * for text media.
7568          *
7569          * <p>Expressed in bits per second as per RFC 3556 Section 2.
7570          */
7571         public static final String KEY_TEXT_RR_BANDWIDTH_BPS_INT =
7572                 KEY_PREFIX + "text_rr_bandwidth_bps_int";
7573 
7574         /**
7575          * Specifies the Text Codec capability.
7576          *
7577          * <p>Possible keys in this bundle are,
7578          * <UL>
7579          *     <LI>{@link #KEY_T140_PAYLOAD_TYPE_INT}</LI>
7580          *     <LI>{@link #KEY_RED_PAYLOAD_TYPE_INT}</LI>
7581          * </UL>
7582          */
7583         public static final String KEY_TEXT_CODEC_CAPABILITY_PAYLOAD_TYPES_BUNDLE =
7584                 KEY_PREFIX + "text_codec_capability_payload_types_bundle";
7585 
7586         /** Integer representing payload type for T140 codec.
7587          * <p>Payload type is an integer in dynamic payload type range 96-127
7588          * as per RFC RFC 3551 Section 6.
7589          */
7590         public static final String KEY_T140_PAYLOAD_TYPE_INT =
7591                 KEY_PREFIX + "t140_payload_type_int";
7592 
7593         /** Integer representing payload type for RED/redundancy codec.
7594          * <p>Payload type is an integer in dynamic payload type range 96-127
7595          * as per RFC RFC 3551 Section 6.
7596          */
7597         public static final String KEY_RED_PAYLOAD_TYPE_INT =
7598                 KEY_PREFIX + "red_payload_type_int";
7599 
getDefaults()7600         private static PersistableBundle getDefaults() {
7601             PersistableBundle defaults = new PersistableBundle();
7602             defaults.putBoolean(KEY_TEXT_ON_DEFAULT_BEARER_SUPPORTED_BOOL, false);
7603             defaults.putBoolean(KEY_TEXT_QOS_PRECONDITION_SUPPORTED_BOOL, true);
7604 
7605             defaults.putInt(KEY_TEXT_AS_BANDWIDTH_KBPS_INT, 4);
7606             defaults.putInt(KEY_TEXT_RS_BANDWIDTH_BPS_INT, 100);
7607             defaults.putInt(KEY_TEXT_RR_BANDWIDTH_BPS_INT, 300);
7608 
7609             PersistableBundle text_codec_capability_payload_types = new PersistableBundle();
7610 
7611             text_codec_capability_payload_types.putInt(
7612                     KEY_RED_PAYLOAD_TYPE_INT,
7613                     112);
7614 
7615             text_codec_capability_payload_types.putInt(
7616                     KEY_T140_PAYLOAD_TYPE_INT,
7617                     111);
7618 
7619             defaults.putPersistableBundle(
7620                     KEY_TEXT_CODEC_CAPABILITY_PAYLOAD_TYPES_BUNDLE,
7621                     text_codec_capability_payload_types);
7622 
7623             return defaults;
7624         }
7625     }
7626 
7627     /**
7628      * Emergency Call/E911. This groups the configs specific for emergency call
7629      * over IMS.
7630      *
7631      * <p> Reference: 3GPP 24.229, 3GPP 23.167 Annex H, 3GPP 24.301.
7632      */
7633     public static final class ImsEmergency {
ImsEmergency()7634         private ImsEmergency() {}
7635 
7636         /** Prefix of all imsemergency.KEY_* constants. */
7637         public static final String KEY_PREFIX = "imsemergency.";
7638 
7639         /**
7640          * Flag specifying whether UE would retry E911 call on
7641          * IMS PDN if emergency PDN setup failed.
7642          *
7643          * <p>If {@code true}: Allow UE to retry emergency call on
7644          * IMS PDN if emergency PDN setup failed.{@code false} otherwise.
7645          */
7646         public static final String KEY_RETRY_EMERGENCY_ON_IMS_PDN_BOOL =
7647                 KEY_PREFIX + "retry_emergency_on_ims_pdn_bool";
7648 
7649         /**
7650          * Flag specifying whether UE should enter Emergency CallBack Mode(ECBM)
7651          * after E911 call is ended.
7652          *
7653          * <p>If {@code true}: Enter ECBM mode after E911 call is ended.
7654          * {@code false} otherwise.
7655          */
7656         public static final String KEY_EMERGENCY_CALLBACK_MODE_SUPPORTED_BOOL =
7657                 KEY_PREFIX + "emergency_callback_mode_supported_bool";
7658 
7659         /**
7660          * Flag specifying whether QoS preconditions are supported for emergency
7661          * call setup.
7662          *
7663          * <p>If {@code true}: QoS Preconditions are supported.
7664          * {@code false} otherwise.
7665          *
7666          * <p>Reference: 3GPP TS 24.229
7667          */
7668         public static final String KEY_EMERGENCY_QOS_PRECONDITION_SUPPORTED_BOOL =
7669                 KEY_PREFIX + "emergency_qos_precondition_supported_bool";
7670 
7671         /**
7672          * List of different RAT technologies on which emergency call using IMS
7673          * is supported.
7674          *
7675          * <p>Possible values are,
7676          * {@link AccessNetworkConstants.AccessNetworkType#NGRAN}
7677          * {@link AccessNetworkConstants.AccessNetworkType#EUTRAN}
7678          * {@link AccessNetworkConstants.AccessNetworkType#IWLAN}
7679          */
7680         public static final String KEY_EMERGENCY_OVER_IMS_SUPPORTED_RATS_INT_ARRAY =
7681                 KEY_PREFIX + "emergency_over_ims_supported_rats_int_array";
7682 
7683         /**
7684          * Specifies the maximum time from deciding that an emergency service is to
7685          * be established until completion of the emergency registration procedure.
7686          * Upon timer expiry, the UE considers the emergency REGISTER request or
7687          * the emergency call attempt as failed.
7688          */
7689         public static final String KEY_EMERGENCY_REGISTRATION_TIMER_MILLIS_INT =
7690                 KEY_PREFIX + "emergency_registration_timer_millis_int";
7691 
7692         /**
7693          * This setting will be specify the wait time for refreshing
7694          * geolocation information before dialing emergency call.
7695          */
7696         public static final String KEY_REFRESH_GEOLOCATION_TIMEOUT_MILLIS_INT =
7697                 KEY_PREFIX + "refresh_geolocation_timeout_millis_int";
7698 
7699         /**
7700          * List of 3GPP access network technologies where e911 over IMS is supported
7701          * in the home network and domestic 3rd-party networks. The order in the list represents
7702          * the preference. The domain selection service shall scan the network type in the order
7703          * of the preference.
7704          *
7705          * <p>Possible values are,
7706          * {@link AccessNetworkConstants.AccessNetworkType#NGRAN}
7707          * {@link AccessNetworkConstants.AccessNetworkType#EUTRAN}
7708          *
7709          * The default value for this key is
7710          * {{@link AccessNetworkConstants.AccessNetworkType#EUTRAN},
7711          */
7712         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7713         public static final String
7714                 KEY_EMERGENCY_OVER_IMS_SUPPORTED_3GPP_NETWORK_TYPES_INT_ARRAY = KEY_PREFIX
7715                         + "emergency_over_ims_supported_3gpp_network_types_int_array";
7716 
7717         /**
7718          * List of 3GPP access network technologies where e911 over IMS is supported
7719          * in the roaming network and non-domestic 3rd-party networks. The order in the list
7720          * represents the preference. The domain selection service shall scan the network type
7721          * in the order of the preference.
7722          *
7723          * <p>Possible values are,
7724          * {@link AccessNetworkConstants.AccessNetworkType#NGRAN}
7725          * {@link AccessNetworkConstants.AccessNetworkType#EUTRAN}
7726          *
7727          * The default value for this key is
7728          * {{@link AccessNetworkConstants.AccessNetworkType#EUTRAN},
7729          */
7730         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7731         public static final String
7732                 KEY_EMERGENCY_OVER_IMS_ROAMING_SUPPORTED_3GPP_NETWORK_TYPES_INT_ARRAY = KEY_PREFIX
7733                         + "emergency_over_ims_roaming_supported_3gpp_network_types_int_array";
7734 
7735         /**
7736          * List of CS access network technologies where circuit-switched emergency calls are
7737          * supported in the home network and domestic 3rd-party networks. The order in the list
7738          * represents the preference. The domain selection service shall scan the network type
7739          * in the order of the preference.
7740          *
7741          * <p>Possible values are,
7742          * {@link AccessNetworkConstants.AccessNetworkType#GERAN}
7743          * {@link AccessNetworkConstants.AccessNetworkType#UTRAN}
7744          * {@link AccessNetworkConstants.AccessNetworkType#CDMA2000}
7745          *
7746          * The default value for this key is
7747          * {{@link AccessNetworkConstants.AccessNetworkType#UTRAN},
7748          * {@link AccessNetworkConstants.AccessNetworkType#GERAN}}.
7749          */
7750         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7751         public static final String KEY_EMERGENCY_OVER_CS_SUPPORTED_ACCESS_NETWORK_TYPES_INT_ARRAY =
7752                 KEY_PREFIX + "emergency_over_cs_supported_access_network_types_int_array";
7753 
7754         /**
7755          * List of CS access network technologies where circuit-switched emergency calls are
7756          * supported in the roaming network and non-domestic 3rd-party networks. The order
7757          * in the list represents the preference. The domain selection service shall scan
7758          * the network type in the order of the preference.
7759          *
7760          * <p>Possible values are,
7761          * {@link AccessNetworkConstants.AccessNetworkType#GERAN}
7762          * {@link AccessNetworkConstants.AccessNetworkType#UTRAN}
7763          * {@link AccessNetworkConstants.AccessNetworkType#CDMA2000}
7764          *
7765          * The default value for this key is
7766          * {{@link AccessNetworkConstants.AccessNetworkType#UTRAN},
7767          * {@link AccessNetworkConstants.AccessNetworkType#GERAN}}.
7768          */
7769         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7770         public static final String
7771                 KEY_EMERGENCY_OVER_CS_ROAMING_SUPPORTED_ACCESS_NETWORK_TYPES_INT_ARRAY = KEY_PREFIX
7772                         + "emergency_over_cs_roaming_supported_access_network_types_int_array";
7773 
7774         /** @hide */
7775         @IntDef({
7776             DOMAIN_CS,
7777             DOMAIN_PS_3GPP,
7778             DOMAIN_PS_NON_3GPP
7779         })
7780         public @interface EmergencyDomain {}
7781 
7782         /**
7783          * Circuit switched domain.
7784          */
7785         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7786         public static final int DOMAIN_CS = 1;
7787 
7788         /**
7789          * Packet switched domain over 3GPP networks.
7790          */
7791         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7792         public static final int DOMAIN_PS_3GPP = 2;
7793 
7794         /**
7795          * Packet switched domain over non-3GPP networks such as Wi-Fi.
7796          */
7797         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7798         public static final int DOMAIN_PS_NON_3GPP = 3;
7799 
7800         /**
7801          * Specifies the emergency call domain preference for the home network.
7802          * The domain selection service shall choose the domain in the order
7803          * for attempting the emergency call
7804          *
7805          * <p>Possible values are,
7806          * {@link #DOMAIN_CS}
7807          * {@link #DOMAIN_PS_3GPP}
7808          * {@link #DOMAIN_PS_NON_3GPP}.
7809          *
7810          * The default value for this key is
7811          * {{@link #DOMAIN_PS_3GPP},
7812          * {@link #DOMAIN_CS},
7813          * {@link #DOMAIN_PS_NON_3GPP}}.
7814          */
7815         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7816         public static final String KEY_EMERGENCY_DOMAIN_PREFERENCE_INT_ARRAY =
7817                 KEY_PREFIX + "emergency_domain_preference_int_array";
7818 
7819         /**
7820          * Specifies the emergency call domain preference for the roaming network.
7821          * The domain selection service shall choose the domain in the order
7822          * for attempting the emergency call.
7823          *
7824          * <p>Possible values are,
7825          * {@link #DOMAIN_CS}
7826          * {@link #DOMAIN_PS_3GPP}
7827          * {@link #DOMAIN_PS_NON_3GPP}.
7828          *
7829          * The default value for this key is
7830          * {{@link #DOMAIN_PS_3GPP},
7831          * {@link #DOMAIN_CS},
7832          * {@link #DOMAIN_PS_NON_3GPP}}.
7833          */
7834         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7835         public static final String KEY_EMERGENCY_DOMAIN_PREFERENCE_ROAMING_INT_ARRAY =
7836                 KEY_PREFIX + "emergency_domain_preference_roaming_int_array";
7837 
7838         /**
7839          * Specifies whether the emergency call shall be preferred over IMS or not
7840          * irrespective of IMS registration status.
7841          * If the value of the config is {@code true} then emergency calls shall prefer IMS
7842          * when device is combined-attached in LTE network and IMS is not registered.
7843          * If the value of the config is {@code false} then emergency calls use CS domain
7844          * in the same scenario.
7845          *
7846          * The default value for this key is {@code false}.
7847          */
7848         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7849         public static final String KEY_PREFER_IMS_EMERGENCY_WHEN_VOICE_CALLS_ON_CS_BOOL =
7850                 KEY_PREFIX + "prefer_ims_emergency_when_voice_calls_on_cs_bool";
7851 
7852         /** @hide */
7853         @IntDef({
7854             VOWIFI_REQUIRES_NONE,
7855             VOWIFI_REQUIRES_SETTING_ENABLED,
7856             VOWIFI_REQUIRES_VALID_EID,
7857         })
7858         public @interface VoWiFiRequires {}
7859 
7860         /**
7861          * Default value.
7862          * If {@link ImsWfc#KEY_EMERGENCY_CALL_OVER_EMERGENCY_PDN_BOOL} is {@code true},
7863          * VoWi-Fi emergency call shall be attempted if Wi-Fi network is connected.
7864          * Otherwise, it shall be attempted if IMS is registered over Wi-Fi.
7865          */
7866         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7867         public static final int VOWIFI_REQUIRES_NONE = 0;
7868 
7869         /**
7870          * VoWi-Fi emergency call shall be attempted on IMS over Wi-Fi if Wi-Fi network is connected
7871          * and Wi-Fi calling setting is enabled. This value is applicable if the value of
7872          * {@link ImsWfc#KEY_EMERGENCY_CALL_OVER_EMERGENCY_PDN_BOOL} is {@code true}.
7873          */
7874         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7875         public static final int VOWIFI_REQUIRES_SETTING_ENABLED = 1;
7876 
7877         /**
7878          * VoWi-Fi emergency call shall be attempted on IMS over Wi-Fi if Wi-Fi network is connected
7879          * and Wi-Fi calling is activated successfully. The device shall have the valid
7880          * Entitlement ID if the user activates VoWi-Fi emergency calling successfully.
7881          * This value is applicable if the value of
7882          * {@link ImsWfc#KEY_EMERGENCY_CALL_OVER_EMERGENCY_PDN_BOOL} is {@code true}.
7883          */
7884         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7885         public static final int VOWIFI_REQUIRES_VALID_EID = 2;
7886 
7887         /**
7888          * Specifies the condition when emergency call shall be attempted on IMS over Wi-Fi.
7889          *
7890          * <p>Possible values are,
7891          * {@link #VOWIFI_REQUIRES_NONE}
7892          * {@link #VOWIFI_REQUIRES_SETTING_ENABLED}
7893          * {@link #VOWIFI_REQUIRES_VALID_EID}
7894          *
7895          * The default value for this key is {@link #VOWIFI_REQUIRES_NONE}.
7896          */
7897         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7898         public static final String KEY_EMERGENCY_VOWIFI_REQUIRES_CONDITION_INT =
7899                 KEY_PREFIX + "emergency_vowifi_requires_condition_int";
7900 
7901         /**
7902          * Specifies maximum number of emergency call retries over Wi-Fi.
7903          * This is valid only when {@link #DOMAIN_PS_NON_3GPP} is included in
7904          * {@link #KEY_EMERGENCY_DOMAIN_PREFERENCE_INT_ARRAY} or
7905          * {@link #KEY_EMERGENCY_DOMAIN_PREFERENCE_ROAMING_INT_ARRAY}.
7906          *
7907          * The default value for this key is 1.
7908          */
7909         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7910         public static final String KEY_MAXIMUM_NUMBER_OF_EMERGENCY_TRIES_OVER_VOWIFI_INT =
7911                 KEY_PREFIX + "maximum_number_of_emergency_tries_over_vowifi_int";
7912 
7913         /**
7914          * Emergency scan timer to wait for scan results from radio before attempting the call
7915          * over Wi-Fi. On timer expiry, if emergency call on Wi-Fi is allowed and possible,
7916          * telephony shall cancel the scan and place the call on Wi-Fi. If emergency call on Wi-Fi
7917          * is not possible, then domain selection continues to wait for the scan result from the
7918          * radio. If an emergency scan result is received before the timer expires, the timer shall
7919          * be stopped and no dialing over Wi-Fi will be tried. If this value is set to 0, then
7920          * the timer is never started and domain selection waits for the scan result from the radio.
7921          *
7922          * The default value for the timer is 10 seconds.
7923          */
7924         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7925         public static final String KEY_EMERGENCY_SCAN_TIMER_SEC_INT =
7926                 KEY_PREFIX + "emergency_scan_timer_sec_int";
7927 
7928         /**
7929          * The timer to wait for the call completion on the cellular network before attempting the
7930          * call over Wi-Fi. On timer expiry, if emergency call on Wi-Fi is allowed and possible,
7931          * telephony shall cancel the scan on the cellular network and place the call on Wi-Fi.
7932          * If dialing over cellular network is ongoing when timer expires, dialing over Wi-Fi
7933          * will be requested only when the ongoing dialing fails. If emergency call on Wi-Fi is not
7934          * possible, then domain selection continues to try dialing from the radio and the timer
7935          * remains expired. Later when calling over Wi-Fi is possible and dialing over cellular
7936          * networks fails, calling over Wi-Fi will be requested. The timer shall be restarted from
7937          * initial state if calling over Wi-Fi fails.
7938          * If this value is set to {@link #REDIAL_TIMER_DISABLED}, then the timer will never be
7939          * started.
7940          *
7941          * The default value for the timer is {@link #REDIAL_TIMER_DISABLED}.
7942          */
7943         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7944         public static final String KEY_MAXIMUM_CELLULAR_SEARCH_TIMER_SEC_INT =
7945                 KEY_PREFIX + "maximum_cellular_search_timer_sec_int";
7946 
7947         /** @hide */
7948         @IntDef(prefix = "SCAN_TYPE_",
7949             value = {
7950                 SCAN_TYPE_NO_PREFERENCE,
7951                 SCAN_TYPE_FULL_SERVICE,
7952                 SCAN_TYPE_FULL_SERVICE_FOLLOWED_BY_LIMITED_SERVICE})
7953         public @interface EmergencyScanType {}
7954 
7955         /**
7956          * No specific preference given to the modem. Modem can return an emergency
7957          * capable network either with limited service or full service.
7958          */
7959         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7960         public static final int SCAN_TYPE_NO_PREFERENCE = 0;
7961 
7962         /**
7963          * Modem will attempt to camp on a network with full service only.
7964          */
7965         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7966         public static final int SCAN_TYPE_FULL_SERVICE = 1;
7967 
7968         /**
7969          * Telephony shall attempt full service scan first.
7970          * If a full service network is not found, telephony shall attempt a limited service scan.
7971          */
7972         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7973         public static final int SCAN_TYPE_FULL_SERVICE_FOLLOWED_BY_LIMITED_SERVICE = 2;
7974 
7975         /**
7976          * Specifies the preferred emergency network scanning type.
7977          *
7978          * <p>Possible values are,
7979          * {@link #SCAN_TYPE_NO_PREFERENCE}
7980          * {@link #SCAN_TYPE_FULL_SERVICE}
7981          * {@link #SCAN_TYPE_FULL_SERVICE_FOLLOWED_BY_LIMITED_SERVICE}
7982          *
7983          * The default value for this key is {@link #SCAN_TYPE_NO_PREFERENCE}.
7984          */
7985         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7986         public static final String KEY_EMERGENCY_NETWORK_SCAN_TYPE_INT =
7987                 KEY_PREFIX + "emergency_network_scan_type_int";
7988 
7989         /**
7990          * Specifies the time by which a call should be set up on the current network
7991          * once the call is routed on the network. If the call cannot be set up by timer expiry,
7992          * call shall be re-dialed on the next available network.
7993          * If this value is set to 0, the timer shall be disabled.
7994          *
7995          * The default value for this key is 0.
7996          */
7997         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
7998         public static final String KEY_EMERGENCY_CALL_SETUP_TIMER_ON_CURRENT_NETWORK_SEC_INT =
7999                 KEY_PREFIX + "emergency_call_setup_timer_on_current_network_sec_int";
8000 
8001         /**
8002          * Specifies if emergency call shall be attempted on IMS only when IMS is registered.
8003          * This is applicable only for the case PS is in service.
8004          *
8005          * The default value for this key is {@code false}.
8006          */
8007         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8008         public static final String KEY_EMERGENCY_REQUIRES_IMS_REGISTRATION_BOOL =
8009                 KEY_PREFIX + "emergency_requires_ims_registration_bool";
8010 
8011         /**
8012          * Specifies if LTE is preferred when re-scanning networks after the failure of dialing
8013          * over NR. If not, CS will be preferred.
8014          *
8015          * The default value for this key is {@code false}.
8016          */
8017         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8018         public static final String KEY_EMERGENCY_LTE_PREFERRED_AFTER_NR_FAILED_BOOL =
8019                 KEY_PREFIX + "emergency_lte_preferred_after_nr_failed_bool";
8020 
8021         /**
8022          * Specifies the numbers to be dialed over CDMA network in case of dialing over CS network.
8023          *
8024          * The default value for this key is an empty string array.
8025          */
8026         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8027         public static final String KEY_EMERGENCY_CDMA_PREFERRED_NUMBERS_STRING_ARRAY =
8028                 KEY_PREFIX + "emergency_cdma_preferred_numbers_string_array";
8029 
8030         /**
8031          * Specifies if emergency call shall be attempted on IMS over cellular network
8032          * only when VoLTE is enabled.
8033          *
8034          * The default value for this key is {@code false}.
8035          */
8036         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8037         public static final String KEY_EMERGENCY_REQUIRES_VOLTE_ENABLED_BOOL =
8038                 KEY_PREFIX + "emergency_requires_volte_enabled_bool";
8039 
8040         /**
8041          * This values indicates that the cross SIM redialing timer and maximum celluar search
8042          * timer shall be disabled.
8043          *
8044          * @see #KEY_CROSS_STACK_REDIAL_TIMER_SEC_INT
8045          * @see #KEY_QUICK_CROSS_STACK_REDIAL_TIMER_SEC_INT
8046          * @see #KEY_MAXIMUM_CELLULAR_SEARCH_TIMER_SEC_INT
8047          */
8048         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8049         public static final int REDIAL_TIMER_DISABLED = 0;
8050 
8051         /**
8052          * A timer to guard the max attempting time on current SIM slot so that modem will not
8053          * stuck in current SIM slot for long time. On timer expiry, if emergency call on the
8054          * other SIM slot is preferable, telephony shall cancel the emergency call and place the
8055          * call on the other SIM slot. If this value is set to {@link #REDIAL_TIMER_DISABLED}, then
8056          * the timer will never be started and domain selection continues on the current SIM slot.
8057          * This value should be greater than the value of {@link #KEY_EMERGENCY_SCAN_TIMER_SEC_INT}.
8058          *
8059          * The default value for the timer is 120 seconds.
8060          */
8061         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8062         public static final String KEY_CROSS_STACK_REDIAL_TIMER_SEC_INT =
8063                 KEY_PREFIX + "cross_stack_redial_timer_sec_int";
8064 
8065         /**
8066          * If emergency calls are only allowed with normal-registered service and UE should get
8067          * normal service in a short time with acquired band information, telephony
8068          * expects dialing emergency call will be completed in a short time.
8069          * If dialing is not completed with in a certain timeout, telephony shall place on
8070          * another SIM slot. If this value is set to {@link #REDIAL_TIMER_DISABLED}, then the timer
8071          * will never be started and domain selection continues on the current SIM slot.
8072          * The timer shall be started for the first trial of each subscription and shall be ignored
8073          * in the roaming networks and non-domestic networks.
8074          *
8075          * The default value for the timer is {@link #REDIAL_TIMER_DISABLED}.
8076          */
8077         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8078         public static final String KEY_QUICK_CROSS_STACK_REDIAL_TIMER_SEC_INT =
8079                 KEY_PREFIX + "quick_cross_stack_redial_timer_sec_int";
8080 
8081         /**
8082          * Indicates whether the quick cross stack redial timer will be triggered only when
8083          * the device is registered to the network.
8084          *
8085          * The default value is {@code true}.
8086          */
8087         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8088         public static final String KEY_START_QUICK_CROSS_STACK_REDIAL_TIMER_WHEN_REGISTERED_BOOL =
8089                 KEY_PREFIX + "start_quick_cross_stack_redial_timer_when_registered_bool";
8090 
8091         /**
8092          * Indicates whether limited service only scanning will be requested after VoLTE fails.
8093          * This value is applicable if the value of
8094          * {@link #KEY_EMERGENCY_NETWORK_SCAN_TYPE_INT} is any of {@link #SCAN_TYPE_NO_PREFERENCE}
8095          * or {@link #SCAN_TYPE_FULL_SERVICE_FOLLOWED_BY_LIMITED_SERVICE}.
8096          *
8097          * The default value is {@code false}.
8098          */
8099         @FlaggedApi(Flags.FLAG_USE_OEM_DOMAIN_SELECTION_SERVICE)
8100         public static final String
8101                 KEY_SCAN_LIMITED_SERVICE_AFTER_VOLTE_FAILURE_BOOL =
8102                     KEY_PREFIX + "scan_limited_service_after_volte_failure_bool";
8103 
8104         /**
8105          * This config defines {@link ImsReasonInfo} code with which the emergency call
8106          * shall be retried.
8107          *
8108          * <p>
8109          * If the reason code is one of the following, the emergency call shall be retried
8110          * regardless of this configuration.
8111          * <ul>
8112          * <li>{@link ImsReasonInfo#CODE_LOCAL_CALL_CS_RETRY_REQUIRED}</li>
8113          * <li>{@link ImsReasonInfo#CODE_LOCAL_NOT_REGISTERED}</li>
8114          * <li>{@link ImsReasonInfo#CODE_SIP_ALTERNATE_EMERGENCY_CALL}</li>
8115          * </ul>
8116          * <p>
8117          *
8118          * This config is empty by default.
8119          *
8120          * @hide
8121          */
8122         public static final String KEY_IMS_REASONINFO_CODE_TO_RETRY_EMERGENCY_INT_ARRAY =
8123                 KEY_PREFIX + "ims_reasoninfo_code_to_retry_emergency_int_array";
8124 
getDefaults()8125         private static PersistableBundle getDefaults() {
8126             PersistableBundle defaults = new PersistableBundle();
8127             defaults.putBoolean(KEY_RETRY_EMERGENCY_ON_IMS_PDN_BOOL, false);
8128             defaults.putBoolean(KEY_EMERGENCY_CALLBACK_MODE_SUPPORTED_BOOL, false);
8129             defaults.putBoolean(KEY_EMERGENCY_QOS_PRECONDITION_SUPPORTED_BOOL, true);
8130 
8131             defaults.putIntArray(
8132                     KEY_EMERGENCY_OVER_IMS_SUPPORTED_RATS_INT_ARRAY,
8133                     new int[] {
8134                         AccessNetworkType.EUTRAN,
8135                         AccessNetworkType.IWLAN
8136                     });
8137 
8138             defaults.putInt(KEY_EMERGENCY_REGISTRATION_TIMER_MILLIS_INT, 10000);
8139             defaults.putInt(KEY_REFRESH_GEOLOCATION_TIMEOUT_MILLIS_INT, 5000);
8140 
8141             defaults.putIntArray(
8142                     KEY_EMERGENCY_OVER_IMS_SUPPORTED_3GPP_NETWORK_TYPES_INT_ARRAY,
8143                     new int[] {
8144                         AccessNetworkType.EUTRAN,
8145                     });
8146 
8147             defaults.putIntArray(
8148                     KEY_EMERGENCY_OVER_IMS_ROAMING_SUPPORTED_3GPP_NETWORK_TYPES_INT_ARRAY,
8149                     new int[] {
8150                         AccessNetworkType.EUTRAN,
8151                     });
8152 
8153             defaults.putIntArray(
8154                     KEY_EMERGENCY_OVER_CS_SUPPORTED_ACCESS_NETWORK_TYPES_INT_ARRAY,
8155                     new int[] {
8156                         AccessNetworkType.UTRAN,
8157                         AccessNetworkType.GERAN,
8158                     });
8159 
8160             defaults.putIntArray(
8161                     KEY_EMERGENCY_OVER_CS_ROAMING_SUPPORTED_ACCESS_NETWORK_TYPES_INT_ARRAY,
8162                     new int[] {
8163                         AccessNetworkType.UTRAN,
8164                         AccessNetworkType.GERAN,
8165                     });
8166 
8167             defaults.putIntArray(KEY_EMERGENCY_DOMAIN_PREFERENCE_INT_ARRAY,
8168                     new int[] {
8169                         DOMAIN_PS_3GPP,
8170                         DOMAIN_CS,
8171                         DOMAIN_PS_NON_3GPP
8172                     });
8173             defaults.putIntArray(KEY_EMERGENCY_DOMAIN_PREFERENCE_ROAMING_INT_ARRAY,
8174                     new int[] {
8175                         DOMAIN_PS_3GPP,
8176                         DOMAIN_CS,
8177                         DOMAIN_PS_NON_3GPP
8178                     });
8179 
8180             defaults.putBoolean(KEY_PREFER_IMS_EMERGENCY_WHEN_VOICE_CALLS_ON_CS_BOOL, false);
8181             defaults.putInt(KEY_EMERGENCY_VOWIFI_REQUIRES_CONDITION_INT, VOWIFI_REQUIRES_NONE);
8182             defaults.putInt(KEY_MAXIMUM_NUMBER_OF_EMERGENCY_TRIES_OVER_VOWIFI_INT, 1);
8183             defaults.putInt(KEY_EMERGENCY_SCAN_TIMER_SEC_INT, 10);
8184             defaults.putInt(KEY_MAXIMUM_CELLULAR_SEARCH_TIMER_SEC_INT, REDIAL_TIMER_DISABLED);
8185             defaults.putInt(KEY_EMERGENCY_NETWORK_SCAN_TYPE_INT, SCAN_TYPE_NO_PREFERENCE);
8186             defaults.putInt(KEY_EMERGENCY_CALL_SETUP_TIMER_ON_CURRENT_NETWORK_SEC_INT, 0);
8187             defaults.putBoolean(KEY_EMERGENCY_REQUIRES_IMS_REGISTRATION_BOOL, false);
8188             defaults.putBoolean(KEY_EMERGENCY_LTE_PREFERRED_AFTER_NR_FAILED_BOOL, false);
8189             defaults.putBoolean(KEY_EMERGENCY_REQUIRES_VOLTE_ENABLED_BOOL, false);
8190             defaults.putStringArray(KEY_EMERGENCY_CDMA_PREFERRED_NUMBERS_STRING_ARRAY,
8191                     new String[0]);
8192             defaults.putInt(KEY_CROSS_STACK_REDIAL_TIMER_SEC_INT, 120);
8193             defaults.putInt(KEY_QUICK_CROSS_STACK_REDIAL_TIMER_SEC_INT, REDIAL_TIMER_DISABLED);
8194             defaults.putBoolean(KEY_START_QUICK_CROSS_STACK_REDIAL_TIMER_WHEN_REGISTERED_BOOL,
8195                     true);
8196             defaults.putBoolean(KEY_SCAN_LIMITED_SERVICE_AFTER_VOLTE_FAILURE_BOOL, false);
8197             defaults.putIntArray(KEY_IMS_REASONINFO_CODE_TO_RETRY_EMERGENCY_INT_ARRAY,
8198                     new int[0]);
8199 
8200             return defaults;
8201         }
8202     }
8203 
8204     /**
8205      * IMS Video Telephony configs. This groups the configs that are specific for video call.
8206      */
8207     public static final class ImsVt {
ImsVt()8208         private ImsVt() {}
8209 
8210         /** Prefix of all imsvt.KEY_* constants. */
8211         public static final String KEY_PREFIX = "imsvt.";
8212 
8213         /**
8214          * Flag specifying whether video media is allowed on default bearer.
8215          *
8216          * <p>If {@code true}: video media can be sent on default bearer.
8217          * {@code false} otherwise.
8218          */
8219         public static final String KEY_VIDEO_ON_DEFAULT_BEARER_SUPPORTED_BOOL =
8220                 KEY_PREFIX + "video_on_default_bearer_supported_bool";
8221 
8222         /**
8223          * Specifies the timeout value for no video RTP packets received.
8224          * <p>On timer expiry, VT call can downgrade to voice call or end
8225          * or continue depending on the operator requirement.
8226          */
8227         public static final String KEY_VIDEO_RTP_INACTIVITY_TIMER_MILLIS_INT =
8228                 KEY_PREFIX + "video_rtp_inactivity_timer_millis_int";
8229 
8230         /**
8231          * Specifies the timeout value for no video RTCP packets received.
8232          * <p>On timer expiry, VT call can downgrade to voice call or end
8233          * or continue depending on the operator requirement.
8234          */
8235         public static final String KEY_VIDEO_RTCP_INACTIVITY_TIMER_MILLIS_INT =
8236                 KEY_PREFIX + "video_rtcp_inactivity_timer_millis_int";
8237 
8238         /**
8239          * Specifies the AS (Application Specific) SDP modifier for video media.
8240          *
8241          * <p>Expressed in kilobits per second as per RFC 3556 Section 2.
8242          */
8243         public static final String KEY_VIDEO_AS_BANDWIDTH_KBPS_INT =
8244                 KEY_PREFIX + "video_as_bandwidth_kbps_int";
8245 
8246         /**
8247          * Specifies the RS (RTCP bandwidth-Sender) SDP modifier for video media.
8248          *
8249          * <p>This indicates the RTCP bandwidth allocated to active data senders
8250          * for video media.
8251          *
8252          * <p>Expressed in bits per second as per RFC 3556 Section 2.
8253          */
8254         public static final String KEY_VIDEO_RS_BANDWIDTH_BPS_INT =
8255                 KEY_PREFIX + "video_rs_bandwidth_bps_int";
8256 
8257         /**
8258          * Specifies the RR (RTCP bandwidth-Receiver) SDP modifier
8259          * for video media.
8260          *
8261          * <p>This indicates the RTCP bandwidth allocated to receivers
8262          * for video media.
8263          *
8264          * <p>Expressed in bits per second as per RFC 3556 Section 2.
8265          */
8266         public static final String KEY_VIDEO_RR_BANDWIDTH_BPS_INT =
8267                 KEY_PREFIX + "video_rr_bandwidth_bps_int";
8268 
8269         /**
8270          * Specifies the differentiated services code point (DSCP) value
8271          * for Video RTP.
8272          *
8273          * <p>Reference: RFC 4594 Section 1.4.4
8274          */
8275         public static final String KEY_VIDEO_RTP_DSCP_INT =
8276                 KEY_PREFIX + "video_rtp_dscp_int";
8277 
8278         /**
8279          * Flag specifying whether QoS preconditions are supported for Video.
8280          *
8281          * <p>If {@code true}: QoS Preconditions are supported.
8282          * {@code false} otherwise.
8283          * <p>Reference: 3GPP TS 24.229
8284          */
8285         public static final String KEY_VIDEO_QOS_PRECONDITION_SUPPORTED_BOOL =
8286                 KEY_PREFIX + "video_qos_precondition_supported_bool";
8287 
8288         /**
8289          * Specifies the Video Codec capability. This contains a list of
8290          * payload types representing different Video codec instances.
8291 
8292          * <p>Possible key(s) in this bundle are,
8293          * <UL>
8294          *     <LI>{@link #KEY_H264_PAYLOAD_TYPE_INT_ARRAY}</LI>
8295          * </UL>
8296          * <p>To specify payload descriptions for each of the payload types, see
8297          * <UL>
8298          *     <LI>{@link #KEY_H264_PAYLOAD_DESCRIPTION_BUNDLE}</LI>
8299          * </UL>
8300          */
8301         public static final String KEY_VIDEO_CODEC_CAPABILITY_PAYLOAD_TYPES_BUNDLE =
8302                 KEY_PREFIX + "video_codec_capability_payload_types_bundle";
8303 
8304         /**
8305          * A list of integers representing the different payload types
8306          * in H264 video codec in priority order from highest to lowest.
8307          * <p>Payload type is an integer in dynamic payload type range 96-127
8308          * as per RFC RFC 3551 Section 6.
8309          */
8310         public static final String KEY_H264_PAYLOAD_TYPE_INT_ARRAY =
8311                 KEY_PREFIX + "h264_payload_type_int_array";
8312 
8313         /**
8314          * Specifies the codec attributes of different payload types
8315          * representing H264 video codec instances.
8316          *
8317          * <p> The allowed payload types of the video codecs are specified in,
8318          * {@link #KEY_H264_PAYLOAD_TYPE_INT_ARRAY}.
8319          *
8320          * <p>Codec attributes allowed as part of H264 codec bundle are,
8321          * <UL>
8322          *     <LI>{@link #KEY_H264_VIDEO_CODEC_ATTRIBUTE_PROFILE_LEVEL_ID_STRING}</LI>
8323          *     <LI>{@link #KEY_VIDEO_CODEC_ATTRIBUTE_PACKETIZATION_MODE_INT}</LI>
8324          *     <LI>{@link #KEY_VIDEO_CODEC_ATTRIBUTE_FRAME_RATE_INT}</LI>
8325          *     <LI>{@link #KEY_VIDEO_CODEC_ATTRIBUTE_RESOLUTION_INT_ARRAY}</LI>
8326          * </UL>
8327          *
8328          * <p>If this bundle is not configured and
8329          * {@link #KEY_H264_PAYLOAD_TYPE_INT_ARRAY} is not empty,
8330          * then default values as in the individual codec attributes to
8331          * be used for that payload type.
8332          * <p>If the codec attributes in a particular codec instance bundle
8333          * is not valid together, then that codec instance should not be used.
8334          */
8335         public static final String KEY_H264_PAYLOAD_DESCRIPTION_BUNDLE =
8336                 KEY_PREFIX + "h264_payload_description_bundle";
8337 
8338         /**
8339          * Specifies the packetization mode of the video codec.
8340          *
8341          * <p>Permissible values are 0 (Single NAL unit mode),
8342          * 1(Non-interleaved mode).
8343          *
8344          * <p>If this key is not specified or invalid, then the following
8345          * default value to be used.
8346          * <UL>
8347          *   <LI>For H264: 1(Non-interleaved mode)</LI>
8348          * <UL>
8349          *
8350          * <p>Reference: RFC 6184 Section 5.4
8351          */
8352         public static final String KEY_VIDEO_CODEC_ATTRIBUTE_PACKETIZATION_MODE_INT =
8353                 KEY_PREFIX + "video_codec_attribute_packetization_mode_int";
8354 
8355         /**
8356          * Specifies the maximum frame rate the offerer wishes to receive.
8357          * This gives the maximum video frame rate in frames/sec.
8358          *
8359          * <p>If this key is not specified or invalid, then the following
8360          * default value to be used.
8361          * <UL>
8362          *   <LI>For H264: 15 </LI>
8363          * <UL>
8364          * <p>Reference: RFC 4566 Section 6, 3GPP 26.114 Section 6.2.3.2
8365          */
8366         public static final String KEY_VIDEO_CODEC_ATTRIBUTE_FRAME_RATE_INT =
8367                 KEY_PREFIX + "video_codec_attribute_frame_rate_int";
8368 
8369         /**
8370          * Specifies the maximum resolution allowed for the video codec
8371          * instance.
8372          *
8373          * <p>This is specified as an array of two integers, with
8374          * index 0 : Width,
8375          * index 1 : Height
8376          *
8377          * <p>If this key is not specified or invalid as per the video codec,
8378          * then the following default value to be used.
8379          * <UL>
8380          *   <LI>For H264: 240 (WIDTH) x 320 (HEIGHT) </LI>
8381          * <UL>
8382          * <p>Reference: RFC 4566 Section 6, 3GPP 26.114 Section 6.2.3.2
8383          *
8384          */
8385         public static final String KEY_VIDEO_CODEC_ATTRIBUTE_RESOLUTION_INT_ARRAY =
8386                 KEY_PREFIX + "video_codec_attribute_resolution_int_array";
8387 
8388         /**
8389          * Specifies the profile level id of the H264 video codec.
8390          * This value is represented as "profile-level-id" in the SDP offer
8391          * as per RFC 6184 Section 8.1.
8392          *
8393          * <p>If this key is not specified or invalid as per the video codec,
8394          * then default value of 42C00C to be used.
8395          *
8396          * <p>Reference: RFC 6184 Section 8.1, ITU-T Recommendation H.264
8397          */
8398         public static final String KEY_H264_VIDEO_CODEC_ATTRIBUTE_PROFILE_LEVEL_ID_STRING =
8399                 KEY_PREFIX + "h264_video_codec_attribute_profile_level_id_string";
8400 
getDefaults()8401         private static PersistableBundle getDefaults() {
8402             PersistableBundle defaults = new PersistableBundle();
8403             defaults.putBoolean(KEY_VIDEO_ON_DEFAULT_BEARER_SUPPORTED_BOOL, false);
8404             defaults.putBoolean(KEY_VIDEO_QOS_PRECONDITION_SUPPORTED_BOOL, true);
8405 
8406             defaults.putInt(KEY_VIDEO_RTP_INACTIVITY_TIMER_MILLIS_INT, 0);
8407             defaults.putInt(KEY_VIDEO_RTCP_INACTIVITY_TIMER_MILLIS_INT, 0);
8408 
8409             defaults.putInt(KEY_VIDEO_AS_BANDWIDTH_KBPS_INT, 960);
8410             defaults.putInt(KEY_VIDEO_RS_BANDWIDTH_BPS_INT, 8000);
8411             defaults.putInt(KEY_VIDEO_RR_BANDWIDTH_BPS_INT, 6000);
8412             defaults.putInt(KEY_VIDEO_RTP_DSCP_INT, 40);
8413 
8414             PersistableBundle video_codec_capability_payload_types = new PersistableBundle();
8415 
8416             video_codec_capability_payload_types.putIntArray(
8417                     KEY_H264_PAYLOAD_TYPE_INT_ARRAY,
8418                     new int[] { 99, 100 });
8419 
8420             defaults.putPersistableBundle(
8421                     KEY_VIDEO_CODEC_CAPABILITY_PAYLOAD_TYPES_BUNDLE,
8422                     video_codec_capability_payload_types);
8423 
8424             PersistableBundle all_h264_payload_bundles = new PersistableBundle();
8425 
8426             /* Setting default codec attributes for individual H264 profiles*/
8427 
8428             /* For H264 profile-level-id: 42C00C, frame rate:15, Resolution: 240x320 */
8429             PersistableBundle h264_bundle_instance1 = new PersistableBundle();
8430             all_h264_payload_bundles.putPersistableBundle(
8431                     "99", /* Same value of payload type as in KEY_H264_PAYLOAD_TYPE_INT_ARRAY */
8432                     h264_bundle_instance1);
8433 
8434             /* For H264 profile-level-id: 42C00C, packetisation mode:0, frame rate:15,
8435              * Resolution: 240x320 */
8436             PersistableBundle h264_bundle_instance2 = new PersistableBundle();
8437             h264_bundle_instance2.putInt(
8438                     KEY_VIDEO_CODEC_ATTRIBUTE_PACKETIZATION_MODE_INT,
8439                     0);
8440 
8441             all_h264_payload_bundles.putPersistableBundle(
8442                     "100", /* Same value of payload type as in KEY_H264_PAYLOAD_TYPE_INT_ARRAY */
8443                     h264_bundle_instance2);
8444 
8445             defaults.putPersistableBundle(
8446                     KEY_H264_PAYLOAD_DESCRIPTION_BUNDLE,
8447                     all_h264_payload_bundles);
8448 
8449             return defaults;
8450         }
8451     }
8452 
8453     /**
8454      * WiFi Calling. This groups the configs specific for Voice over WiFi/WFC call.
8455      */
8456     public static final class ImsWfc {
ImsWfc()8457         private ImsWfc() {}
8458 
8459         /** Prefix of all imswfc.KEY_* constants. */
8460         public static final String KEY_PREFIX = "imswfc.";
8461 
8462         /**
8463          *  List of MDNs for which Geo-location PIDF XML with country info
8464          *  needs to included for normal calls involving short code.
8465          */
8466         public static final String KEY_PIDF_SHORT_CODE_STRING_ARRAY =
8467                 KEY_PREFIX + "pidf_short_code_string_array";
8468 
8469         /**
8470          * Flag specifying whether emergency call over VoWiFi is requested over
8471          * emergency PDN or IMS PDN.
8472          *
8473          * <p>If {@code false}: E911 call uses IMS PDN for E911 call over VoWiFi.
8474          * If {@code true}: E911 call uses Emergency PDN for E911 call over VoWiFi.
8475          */
8476         public static final String KEY_EMERGENCY_CALL_OVER_EMERGENCY_PDN_BOOL =
8477                 KEY_PREFIX + "emergency_call_over_emergency_pdn_bool";
8478 
getDefaults()8479         private static PersistableBundle getDefaults() {
8480             PersistableBundle defaults = new PersistableBundle();
8481 
8482             defaults.putBoolean(KEY_EMERGENCY_CALL_OVER_EMERGENCY_PDN_BOOL, false);
8483             defaults.putStringArray(KEY_PIDF_SHORT_CODE_STRING_ARRAY, new String[0]);
8484 
8485             return defaults;
8486         }
8487     }
8488 
8489     /**
8490      *   IMS supplementary services configs. This groups the configs required for
8491      *   supplementary services (SS) like XCAP over UT,
8492      *   Unstructured Supplementary Service Data(USSD).
8493      */
8494     public static final class ImsSs {
ImsSs()8495         private ImsSs() {}
8496 
8497         /** Prefix of all imsss.KEY_* constants. */
8498         public static final String KEY_PREFIX = "imsss.";
8499 
8500         /**
8501          * Flag that controls whether XCAP over UT status need to be
8502          * dependent on IMS registration.
8503          *
8504          * <p>If {@code true}: XCAP over UT status need to be
8505          * dependent on IMS registration.
8506          * {@code false} otherwise.
8507          */
8508         public static final String KEY_UT_REQUIRES_IMS_REGISTRATION_BOOL =
8509                 KEY_PREFIX + "ut_requires_ims_registration_bool";
8510 
8511         /**
8512          * Flag that controls whether XCAP over UT is supported
8513          * when on roaming network.
8514          *
8515          * <p>If {@code true}: XCAP over UT is supported when on
8516          * roaming network.
8517          * {@code false} otherwise.
8518          */
8519         public static final String KEY_UT_SUPPORTED_WHEN_ROAMING_BOOL =
8520                 KEY_PREFIX + "ut_supported_when_roaming_bool";
8521 
8522         /**
8523          * Flag that controls whether Circuit Switched Fallback (CSFB)
8524          * option is available when XCAP over UT fails.
8525          *
8526          * <p>If {@code false}:  XCAP over UT only with no CSFB option.
8527          * If XCAP over UT fails, return error.
8528          * if {@code true}, Use CSFB if XCAP over UT fails.
8529          */
8530         public static final String KEY_USE_CSFB_ON_XCAP_OVER_UT_FAILURE_BOOL =
8531                 KEY_PREFIX + "use_csfb_on_xcap_over_ut_failure_bool";
8532 
8533         /**
8534          * Flag that controls whether XCAP over UT is enabled or not
8535          * when PS data is turned off.
8536          *
8537          * <p>If {@code true}: XCAP over UT is enabled when PS data is off.
8538          * {@code false}: Otherwise.
8539          *
8540          * Reference: IR.92 Section 5.5.1
8541          */
8542         public static final String KEY_UT_SUPPORTED_WHEN_PS_DATA_OFF_BOOL =
8543                 KEY_PREFIX + "ut_supported_when_ps_data_off_bool";
8544 
8545         /**
8546          * Flag that controls whether network initiated USSD over IMS is
8547          * supported by the UE.
8548          *
8549          * <p>If {@code true}:  Support Available.{@code false}: Otherwise.
8550          * Reference: 3GPP 24.390.
8551          */
8552         public static final String KEY_NETWORK_INITIATED_USSD_OVER_IMS_SUPPORTED_BOOL =
8553                 KEY_PREFIX + "network_initiated_ussd_over_ims_supported_bool";
8554 
8555         /**
8556          * Specifies the 'XCAP over UT' IP Type when device is
8557          * on Home Network.
8558          *
8559          * <p>Possible values are,
8560          * {@link ApnSetting#PROTOCOL_IPV4V6},
8561          * {@link ApnSetting#PROTOCOL_IP},
8562          * {@link ApnSetting#PROTOCOL_IPV6}
8563          *
8564          * If key is invalid or not configured, the default value
8565          * {@link ApnSetting#PROTOCOL_IPV4V6} will apply.
8566          */
8567         public static final String KEY_UT_IPTYPE_HOME_INT =
8568                 KEY_PREFIX + "ut_iptype_home_int";
8569 
8570         /**
8571          * Specifies the 'XCAP over UT' IP Type when device is roaming.
8572          *
8573          * <p>Possible values are,
8574          * {@link ApnSetting#PROTOCOL_IPV4V6},
8575          * {@link ApnSetting#PROTOCOL_IP},
8576          * {@link ApnSetting#PROTOCOL_IPV6}
8577 
8578          * If key is invalid or not configured, the default value
8579          * {@link ApnSetting#PROTOCOL_IPV4V6} will apply.
8580          */
8581         public static final String KEY_UT_IPTYPE_ROAMING_INT =
8582                 KEY_PREFIX + "ut_iptype_roaming_int";
8583 
8584         /**
8585          * Specifies the XCAP Application Server fully qualified domain name (FQDN).
8586          * <p> Reference: 24.623 Section 5.2.3.
8587          */
8588         public static final String KEY_UT_AS_SERVER_FQDN_STRING =
8589                 KEY_PREFIX + "ut_as_server_fqdn_string";
8590 
8591         /**
8592          * Specifies the XCAP Application Server Remote port.
8593          * As XCAP is a usage of HTTP, the default value is same as HTTP, i.e. 80.
8594          */
8595         public static final String KEY_UT_AS_SERVER_PORT_INT =
8596                 KEY_PREFIX + "ut_as_server_port_int";
8597 
8598         /**
8599          * Specifies the preferred transport to be used for XCAP over UT.
8600          *
8601          * <p>Possible values are,
8602          * {@link Ims#PREFERRED_TRANSPORT_TCP},
8603          * {@link Ims#PREFERRED_TRANSPORT_TLS}
8604          *
8605          * <p>If key is invalid or not configured, the default value
8606          * {@link Ims#PREFERRED_TRANSPORT_TCP} will apply.
8607          */
8608         public static final String KEY_UT_TRANSPORT_TYPE_INT =
8609                 KEY_PREFIX + "ut_transport_type_int";
8610 
8611         /** @hide */
8612         @IntDef({
8613             SUPPLEMENTARY_SERVICE_CW,
8614             SUPPLEMENTARY_SERVICE_CF_ALL,
8615             SUPPLEMENTARY_SERVICE_CF_CFU,
8616             SUPPLEMENTARY_SERVICE_CF_ALL_CONDITONAL_FORWARDING,
8617             SUPPLEMENTARY_SERVICE_CF_CFB,
8618             SUPPLEMENTARY_SERVICE_CF_CFNRY,
8619             SUPPLEMENTARY_SERVICE_CF_CFNRC,
8620             SUPPLEMENTARY_SERVICE_CF_CFNL,
8621             SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIP,
8622             SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIP,
8623             SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIR,
8624             SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIR,
8625             SUPPLEMENTARY_SERVICE_CB_ALL,
8626             SUPPLEMENTARY_SERVICE_CB_OBS,
8627             SUPPLEMENTARY_SERVICE_CB_BAOC,
8628             SUPPLEMENTARY_SERVICE_CB_BOIC,
8629             SUPPLEMENTARY_SERVICE_CB_BOIC_EXHC,
8630             SUPPLEMENTARY_SERVICE_CB_IBS,
8631             SUPPLEMENTARY_SERVICE_CB_BAIC,
8632             SUPPLEMENTARY_SERVICE_CB_BIC_ROAM,
8633             SUPPLEMENTARY_SERVICE_CB_ACR,
8634             SUPPLEMENTARY_SERVICE_CB_BIL
8635         })
8636         public @interface SsType {}
8637 
8638         /** Communication Waiting (CW) support as per 3GPP 24.615. */
8639         public static final int SUPPLEMENTARY_SERVICE_CW = 0;
8640 
8641         /**
8642          * Call Diversion - All call forwarding support as per 3GPP 24.604.
8643          *
8644          * <p>This value is associated with MMI support service code 002
8645          * as indicated in TS 22.030 Table B.1
8646          */
8647         public static final int SUPPLEMENTARY_SERVICE_CF_ALL = 1;
8648 
8649         /**
8650          * Call Diversion - All Unconditional call forwarding support (CFU) as
8651          * per 3GPP 24.604.
8652          *
8653          * <p>This value is associated with MMI support service code 21
8654          * as indicated in TS 22.030 Table B.1
8655          */
8656         public static final int SUPPLEMENTARY_SERVICE_CF_CFU = 2;
8657 
8658         /**
8659          * Call Diversion - All conditional call forwarding support as
8660          * per 3GPP 24.604.
8661          *
8662          * <p>This value is associated with MMI support service code 004
8663          * as indicated in TS 22.030 Table B.1
8664          */
8665         public static final int SUPPLEMENTARY_SERVICE_CF_ALL_CONDITONAL_FORWARDING = 3;
8666 
8667         /**
8668          * Call Diversion - Call forwarding on mobile subscriber busy (CFB)
8669          * support as per 3GPP 24.604.
8670          *
8671          * <p>This value is associated with MMI support service code 67
8672          * as indicated in TS 22.030 Table B.1
8673          */
8674         public static final int SUPPLEMENTARY_SERVICE_CF_CFB = 4;
8675 
8676         /**
8677          * Call Diversion - Call forwarding on no reply (CFNRY)
8678          * support as per 3GPP 24.604.
8679          *
8680          * <p>This value is associated with MMI support service code 61
8681          * as indicated in TS 22.030 Table B.1
8682          */
8683         public static final int SUPPLEMENTARY_SERVICE_CF_CFNRY = 5;
8684 
8685         /**
8686          * Call Diversion - Call forwarding on mobile subscriber not reachable
8687          * (CFNRC) support as per 3GPP 24.604.
8688          *
8689          * <p>This value is associated with MMI support service code 62
8690          * as indicated in TS 22.030 Table B.1
8691          */
8692         public static final int SUPPLEMENTARY_SERVICE_CF_CFNRC = 6;
8693 
8694         /**
8695          * Communication Forwarding on Not Logged-in (CFNL).
8696          * support as per 3GPP 24.604 Section 4.2.1.7
8697          *
8698          */
8699         public static final int SUPPLEMENTARY_SERVICE_CF_CFNL = 7;
8700 
8701         /**
8702          * Originating Identification Presentation (OIP) support
8703          * as per 3GPP 24.607.
8704          *
8705          */
8706         public static final int SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIP = 8;
8707 
8708         /**
8709          * Terminating Identification Presentation (TIP) support
8710          * as per 3GPP 24.608.
8711          */
8712         public static final int SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIP = 9;
8713 
8714         /**
8715          * Originating Identification Restriction (OIR) support
8716          * as per 3GPP 24.607.
8717          */
8718         public static final int SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIR = 10;
8719 
8720         /**
8721          * Terminating Identification Restriction (TIR) support
8722          * as per 3GPP 24.608.
8723          */
8724         public static final int SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIR = 11;
8725 
8726         /**
8727          * Call Barring - All barring services,
8728          * This value is associated with MMI support service code 330
8729          * as indicated TS 22.030 Table B.1
8730          */
8731         public static final int SUPPLEMENTARY_SERVICE_CB_ALL = 12;
8732 
8733         /**
8734          * Call Barring - Outgoing barring services,
8735          * This value is associated with MMI support service code 333
8736          * as indicated TS 22.030 Table B.1
8737          */
8738         public static final int SUPPLEMENTARY_SERVICE_CB_OBS = 13;
8739 
8740         /**
8741          * Call Barring - Barring of all outgoing calls (BAOC)
8742          * support as per 3GPP TS 24.611.
8743          *
8744          * <p>This value is associated with MMI support service code 33
8745          * as indicated TS 22.030 Table B.1
8746          */
8747         public static final int SUPPLEMENTARY_SERVICE_CB_BAOC = 14;
8748 
8749         /**
8750          * Call Barring - Barring of outgoing international calls
8751          * (BOIC) support as per 3GPP TS 24.611.
8752          *
8753          * <p>This value is associated with MMI support service code 331
8754          * as indicated TS 22.030 Table B.1
8755          */
8756         public static final int SUPPLEMENTARY_SERVICE_CB_BOIC = 15;
8757 
8758         /**
8759          * Call Barring - Barring of outgoing international calls
8760          * except those directed to the home PLMN country (BOIC-EXHC) support
8761          * as per 3GPP TS 24.611.
8762          *
8763          * <p>This value is associated with MMI support service code 332
8764          * as indicated TS 22.030 Table B.1
8765          */
8766         public static final int SUPPLEMENTARY_SERVICE_CB_BOIC_EXHC = 16;
8767 
8768         /**
8769          * Call Barring - Incoming barring services,
8770          * This value is associated with MMI support service code 353
8771          * as indicated TS 22.030 Table B.1
8772          */
8773         public static final int SUPPLEMENTARY_SERVICE_CB_IBS = 17;
8774 
8775         /**
8776          * Call Barring - Barring of all incoming calls (BAIC)
8777          * support as per 3GPP TS 24.611.
8778          *
8779          * <p>This value is associated with MMI support service code 35
8780          * as indicated TS 22.030 Table B.1
8781          */
8782         public static final int SUPPLEMENTARY_SERVICE_CB_BAIC = 18;
8783 
8784         /**
8785          * Call Barring - Barring of incoming calls when roaming outside
8786          * the home PLMN country (BIC-ROAM) support as per 3GPP TS 24.611.
8787          *
8788          * <p>This value is associated with MMI support service code 351
8789          * as indicated TS 22.030 Table B.1
8790          */
8791         public static final int SUPPLEMENTARY_SERVICE_CB_BIC_ROAM = 19;
8792 
8793         /**
8794          * Call Barring - Anonymous Call Rejection/Barring of all anonymous
8795          * incoming number support as per 3GPP TS 24.611.
8796          */
8797         public static final int SUPPLEMENTARY_SERVICE_CB_ACR = 20;
8798 
8799         /**
8800          * Call Barring - Barring list of incoming numbers support.
8801          */
8802         public static final int SUPPLEMENTARY_SERVICE_CB_BIL = 21;
8803 
8804         /**
8805          * List of UT services that are Server based.
8806          *
8807          * <p>Possible values are,
8808          * <UL>
8809          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CW}</LI>
8810          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CF_ALL}</LI>
8811          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CF_CFU}</LI>
8812          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CF_ALL_CONDITONAL_FORWARDING}</LI>
8813          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CF_CFB}</LI>
8814          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CF_CFNRY}</LI>
8815          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CF_CFNRC}</LI>
8816          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CF_CFNL}</LI>
8817          *     <LI>{@link #SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIP}</LI>
8818          *     <LI>{@link #SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIP}</LI>
8819          *     <LI>{@link #SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIR}</LI>
8820          *     <LI>{@link #SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIR}</LI>
8821          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_ALL}</LI>
8822          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_OBS}</LI>
8823          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_IBS}</LI>
8824          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_BAOC}</LI>
8825          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_BOIC}</LI>
8826          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_BOIC_EXHC}</LI>
8827          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_BAIC}</LI>
8828          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_BIC_ROAM}</LI>
8829          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_ACR}</LI>
8830          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CB_BIL}</LI>
8831          * </UL>
8832          */
8833         public static final String KEY_UT_SERVER_BASED_SERVICES_INT_ARRAY =
8834                 KEY_PREFIX + "ut_server_based_services_int_array";
8835 
8836         /**
8837          * List of UT services that are terminal based.
8838          *
8839          * By default, all services are server based and defined in
8840          * {@link #KEY_UT_SERVER_BASED_SERVICES_INT_ARRAY}.
8841          * Adding here will override that service setting to terminal based.
8842          *
8843          * <p>Possible values are,
8844          * <UL>
8845          *     <LI>{@link #SUPPLEMENTARY_SERVICE_CW}</LI>
8846          *     <LI>{@link #SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIR}</LI>
8847          * </UL>
8848          */
8849         public static final String KEY_UT_TERMINAL_BASED_SERVICES_INT_ARRAY =
8850                 KEY_PREFIX + "ut_terminal_based_services_int_array";
8851 
8852         /**
8853          * List of different RAT technologies on which XCAP over UT
8854          * is supported.
8855          *
8856          * <p>Possible values are,
8857          * {@link AccessNetworkConstants.AccessNetworkType#NGRAN}
8858          * {@link AccessNetworkConstants.AccessNetworkType#EUTRAN}
8859          * {@link AccessNetworkConstants.AccessNetworkType#IWLAN}
8860          * {@link AccessNetworkConstants.AccessNetworkType#UTRAN}
8861          * {@link AccessNetworkConstants.AccessNetworkType#GERAN}
8862          */
8863         public static final String KEY_XCAP_OVER_UT_SUPPORTED_RATS_INT_ARRAY =
8864                 KEY_PREFIX + "xcap_over_ut_supported_rats_int_array";
8865 
8866         /** @hide */
8867         @IntDef({
8868             CALL_WAITING_SYNC_NONE,
8869             CALL_WAITING_SYNC_USER_CHANGE,
8870             CALL_WAITING_SYNC_FIRST_POWER_UP,
8871             CALL_WAITING_SYNC_FIRST_CHANGE,
8872             CALL_WAITING_SYNC_IMS_ONLY
8873         })
8874         public @interface CwSyncType {}
8875 
8876         /**
8877          * Do not synchronize the user's call waiting setting with the network. Call waiting is
8878          * always enabled on the carrier network and the user setting for call waiting is applied
8879          * on the terminal side. If the user disables call waiting, the call will be rejected on
8880          * the terminal.
8881          */
8882         public static final int CALL_WAITING_SYNC_NONE = 0;
8883 
8884         /**
8885          * The change of user’s setting is always passed to the carrier network
8886          * and then synchronized to the terminal based call waiting solution over IMS.
8887          * If changing the service over the carrier network is not successful,
8888          * the setting over IMS shall not be changed.
8889          */
8890         public static final int CALL_WAITING_SYNC_USER_CHANGE = 1;
8891 
8892         /**
8893          * Activate call waiting on the carrier network when the device boots or a subscription
8894          * using this carrier is loaded. Call waiting is always considered enabled on the carrier
8895          * network and the user setting for call waiting is applied on the terminal side only. If
8896          * the user disables call waiting, the call will be rejected on the terminal.
8897          * The mismatch between CS calls and IMS calls can happen when the network based call
8898          * waiting service is in disabled state in the legacy 3G/2G networks while it's enabled
8899          * in the terminal side.
8900          */
8901         public static final int CALL_WAITING_SYNC_FIRST_POWER_UP = 2;
8902 
8903         /**
8904          * Activate call waiting on the carrier network when the user enables call waiting the
8905          * first time. Call waiting is then always considered enabled on the carrier network. If
8906          * the user disables call waiting, the setting will only be applied to the terminal based
8907          * call waiting service and the call will be rejected on the terminal.
8908          * The mismatch between CS calls and IMS calls can happen when the network based call
8909          * waiting service is in disabled state in the legacy 3G/2G networks while it's enabled
8910          * in the terminal side. However, if the user retrieves the setting again when the device
8911          * is in the legacy 3G/2G networks, the correct state will be shown to the user.
8912          */
8913         public static final int CALL_WAITING_SYNC_FIRST_CHANGE = 3;
8914 
8915         /**
8916          * Do not synchronize the call waiting service state between the carrier network and
8917          * the terminal based IMS call waiting service. If the user changes the call waiting setting
8918          * when IMS is registered, the change will only be applied to the terminal based call
8919          * waiting service. If IMS is not registered when call waiting is changed, synchronize this
8920          * setting with the carrier network.
8921          */
8922         public static final int CALL_WAITING_SYNC_IMS_ONLY = 4;
8923 
8924         /** @hide */
8925         public static final int CALL_WAITING_SYNC_MAX = CALL_WAITING_SYNC_IMS_ONLY;
8926 
8927         /**
8928          * Flag indicating the way to synchronize the setting between CS and IMS.
8929          *
8930          * <p>Possible values are,
8931          * {@link #CALL_WAITING_SYNC_NONE},
8932          * {@link #CALL_WAITING_SYNC_USER_CHANGE},
8933          * {@link #CALL_WAITING_SYNC_FIRST_POWER_UP},
8934          * {@link #CALL_WAITING_SYNC_FIRST_CHANGE},
8935          * {@link #CALL_WAITING_SYNC_IMS_ONLY}.
8936          *
8937          * This configuration is valid only when
8938          * {@link #KEY_UT_TERMINAL_BASED_SERVICES_INT_ARRAY} includes
8939          * {@link #SUPPLEMENTARY_SERVICE_CW}.
8940          *
8941          * <p>If key is invalid or not configured, the default value
8942          * {@link #CALL_WAITING_SYNC_FIRST_CHANGE} will apply.
8943          */
8944         public static final String KEY_TERMINAL_BASED_CALL_WAITING_SYNC_TYPE_INT =
8945                 KEY_PREFIX + "terminal_based_call_waiting_sync_type_int";
8946 
8947         /**
8948          * Flag indicating whether the user setting for terminal-based call waiting
8949          * is enabled by default or not.
8950          * This configuration is valid only when
8951          * {@link #KEY_UT_TERMINAL_BASED_SERVICES_INT_ARRAY} includes
8952          * {@link #SUPPLEMENTARY_SERVICE_CW}.
8953          *
8954          * The default value for this key is {@code true}.
8955          */
8956         public static final String KEY_TERMINAL_BASED_CALL_WAITING_DEFAULT_ENABLED_BOOL =
8957                 KEY_PREFIX + "terminal_based_call_waiting_default_enabled_bool";
8958 
getDefaults()8959         private static PersistableBundle getDefaults() {
8960             PersistableBundle defaults = new PersistableBundle();
8961             defaults.putBoolean(KEY_UT_REQUIRES_IMS_REGISTRATION_BOOL, false);
8962             defaults.putBoolean(KEY_USE_CSFB_ON_XCAP_OVER_UT_FAILURE_BOOL, true);
8963             defaults.putBoolean(KEY_UT_SUPPORTED_WHEN_PS_DATA_OFF_BOOL, true);
8964             defaults.putBoolean(KEY_NETWORK_INITIATED_USSD_OVER_IMS_SUPPORTED_BOOL, true);
8965             defaults.putBoolean(KEY_UT_SUPPORTED_WHEN_ROAMING_BOOL, true);
8966 
8967             defaults.putInt(KEY_UT_IPTYPE_HOME_INT, ApnSetting.PROTOCOL_IPV4V6);
8968             defaults.putInt(KEY_UT_IPTYPE_ROAMING_INT, ApnSetting.PROTOCOL_IPV4V6);
8969             defaults.putInt(KEY_UT_AS_SERVER_PORT_INT, 80);
8970             defaults.putInt(KEY_UT_TRANSPORT_TYPE_INT, Ims.PREFERRED_TRANSPORT_TCP);
8971 
8972             defaults.putIntArray(
8973                     KEY_UT_SERVER_BASED_SERVICES_INT_ARRAY,
8974                     new int[] {
8975                         SUPPLEMENTARY_SERVICE_CW,
8976                         SUPPLEMENTARY_SERVICE_CF_ALL,
8977                         SUPPLEMENTARY_SERVICE_CF_CFU,
8978                         SUPPLEMENTARY_SERVICE_CF_CFNRC,
8979                         SUPPLEMENTARY_SERVICE_CF_ALL_CONDITONAL_FORWARDING,
8980                         SUPPLEMENTARY_SERVICE_CF_CFB,
8981                         SUPPLEMENTARY_SERVICE_CF_CFNRY,
8982                         SUPPLEMENTARY_SERVICE_CF_CFNL,
8983                         SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIP,
8984                         SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIP,
8985                         SUPPLEMENTARY_SERVICE_IDENTIFICATION_OIR,
8986                         SUPPLEMENTARY_SERVICE_IDENTIFICATION_TIR,
8987                         SUPPLEMENTARY_SERVICE_CB_ALL,
8988                         SUPPLEMENTARY_SERVICE_CB_OBS,
8989                         SUPPLEMENTARY_SERVICE_CB_IBS,
8990                         SUPPLEMENTARY_SERVICE_CB_BAOC,
8991                         SUPPLEMENTARY_SERVICE_CB_BOIC,
8992                         SUPPLEMENTARY_SERVICE_CB_BOIC_EXHC,
8993                         SUPPLEMENTARY_SERVICE_CB_BAIC,
8994                         SUPPLEMENTARY_SERVICE_CB_BIC_ROAM,
8995                         SUPPLEMENTARY_SERVICE_CB_ACR,
8996                         SUPPLEMENTARY_SERVICE_CB_BIL
8997                     });
8998             defaults.putIntArray(KEY_UT_TERMINAL_BASED_SERVICES_INT_ARRAY, new int[0]);
8999 
9000             defaults.putIntArray(
9001                     KEY_XCAP_OVER_UT_SUPPORTED_RATS_INT_ARRAY,
9002                     new int[] {
9003                         AccessNetworkType.EUTRAN,
9004                         AccessNetworkType.IWLAN,
9005                         AccessNetworkType.NGRAN
9006                     });
9007             defaults.putString(KEY_UT_AS_SERVER_FQDN_STRING, "");
9008             defaults.putBoolean(KEY_TERMINAL_BASED_CALL_WAITING_DEFAULT_ENABLED_BOOL, true);
9009             defaults.putInt(KEY_TERMINAL_BASED_CALL_WAITING_SYNC_TYPE_INT,
9010                     CALL_WAITING_SYNC_FIRST_CHANGE);
9011 
9012             return defaults;
9013         }
9014     }
9015 
9016     /**
9017      * This groups the BSF (BootStrapping Function) related configs.
9018      * Reference: 3GPP TS 24.109.
9019      */
9020     public static final class Bsf {
Bsf()9021         private Bsf() {}
9022 
9023         /** Prefix of all bsf.KEY_* constants. */
9024         public static final String KEY_PREFIX = "bsf.";
9025 
9026         /** Specifies the fully qualified domain name (FQDN) of BSF Server
9027          * as per 3GPP 24.109.
9028          */
9029         public static final String KEY_BSF_SERVER_FQDN_STRING =
9030                 KEY_PREFIX + "bsf_server_fqdn_string";
9031 
9032         /**
9033          * Specifies the port number of the BSF server as per 3GPP 24.109.
9034          * This is usually default port number of HTTP, i.e. 80.
9035          */
9036         public static final String KEY_BSF_SERVER_PORT_INT =
9037                 KEY_PREFIX + "bsf_server_port_int";
9038 
9039         /**
9040          * Specifies the transport type used in communication with
9041          * BSF server.
9042          *
9043          * <p>Possible values are,
9044          * {@link Ims#PREFERRED_TRANSPORT_TCP},
9045          * {@link Ims#PREFERRED_TRANSPORT_TLS}
9046          *
9047          * <p>If key is invalid or not configured, the default value
9048          * {@link Ims#PREFERRED_TRANSPORT_TCP} will apply.
9049          */
9050         public static final String KEY_BSF_TRANSPORT_TYPE_INT =
9051                 KEY_PREFIX + "bsf_transport_type_int";
9052 
getDefaults()9053         private static PersistableBundle getDefaults() {
9054             PersistableBundle defaults = new PersistableBundle();
9055 
9056             defaults.putInt(KEY_BSF_SERVER_PORT_INT, 80);
9057             defaults.putInt(KEY_BSF_TRANSPORT_TYPE_INT, Ims.PREFERRED_TRANSPORT_TCP);
9058             defaults.putString(KEY_BSF_SERVER_FQDN_STRING, "");
9059 
9060             return defaults;
9061         }
9062     }
9063 
9064     /**
9065      * Configs used for epdg tunnel bring up.
9066      *
9067      * @see <a href="https://tools.ietf.org/html/rfc7296">RFC 7296, Internet Key Exchange Protocol
9068      *     Version 2 (IKEv2)</a>
9069      */
9070     public static final class Iwlan {
9071         /** Prefix of all Epdg.KEY_* constants. */
9072         public static final String KEY_PREFIX = "iwlan.";
9073 
9074         /**
9075          * Time in seconds after which the child security association session is terminated if rekey
9076          * procedure is not successful. If not set or set to <= 0, the default value is 3600
9077          * seconds.
9078          */
9079         public static final String KEY_CHILD_SA_REKEY_HARD_TIMER_SEC_INT =
9080                 KEY_PREFIX + "child_sa_rekey_hard_timer_sec_int";
9081 
9082         /**
9083          * Time in seconds after which the child session rekey procedure is started. If not set or
9084          * set to <= 0, default value is 3000 seconds.
9085          */
9086         public static final String KEY_CHILD_SA_REKEY_SOFT_TIMER_SEC_INT =
9087                 KEY_PREFIX + "child_sa_rekey_soft_timer_sec_int";
9088 
9089         /**
9090          * Supported DH groups for IKE negotiation. Possible values are:
9091          * {@link android.net.ipsec.ike.SaProposal#DH_GROUP_NONE},
9092          * {@link android.net.ipsec.ike.SaProposal#DH_GROUP_1024_BIT_MODP},
9093          * {@link android.net.ipsec.ike.SaProposal#DH_GROUP_1536_BIT_MODP},
9094          * {@link android.net.ipsec.ike.SaProposal#DH_GROUP_2048_BIT_MODP},
9095          * {@link android.net.ipsec.ike.SaProposal#DH_GROUP_3072_BIT_MODP},
9096          * {@link android.net.ipsec.ike.SaProposal#DH_GROUP_4096_BIT_MODP}
9097          */
9098         public static final String KEY_DIFFIE_HELLMAN_GROUPS_INT_ARRAY =
9099                 KEY_PREFIX + "diffie_hellman_groups_int_array";
9100 
9101         /**
9102          * Time in seconds after which a dead peer detection (DPD) request is sent. If not set or
9103          * set to <= 0, default value is 120 seconds.
9104          */
9105         public static final String KEY_DPD_TIMER_SEC_INT = KEY_PREFIX + "dpd_timer_sec_int";
9106 
9107         /**
9108          * Method used to authenticate epdg server. Possible values are {@link
9109          * #AUTHENTICATION_METHOD_EAP_ONLY}, {@link #AUTHENTICATION_METHOD_CERT}
9110          */
9111         public static final String KEY_EPDG_AUTHENTICATION_METHOD_INT =
9112                 KEY_PREFIX + "epdg_authentication_method_int";
9113 
9114         /**
9115          * A priority list of ePDG addresses to be used. Possible values are {@link
9116          * #EPDG_ADDRESS_STATIC}, {@link #EPDG_ADDRESS_PLMN}, {@link #EPDG_ADDRESS_PCO}, {@link
9117          * #EPDG_ADDRESS_CELLULAR_LOC}, {@link #EPDG_ADDRESS_VISITED_COUNTRY}
9118          */
9119         public static final String KEY_EPDG_ADDRESS_PRIORITY_INT_ARRAY =
9120                 KEY_PREFIX + "epdg_address_priority_int_array";
9121 
9122         /**
9123          * A priority list of PLMN to be used in EPDG_ADDRESS_PLMN. Possible values are {@link
9124          * #EPDG_PLMN_RPLMN}, {@link #EPDG_PLMN_HPLMN}, {@link #EPDG_PLMN_EHPLMN_ALL}, {@link
9125          * #EPDG_PLMN_EHPLMN_FIRST}
9126          *
9127          * @hide
9128          */
9129         public static final String KEY_EPDG_PLMN_PRIORITY_INT_ARRAY =
9130                 KEY_PREFIX + "epdg_plmn_priority_int_array";
9131 
9132         /** Epdg static IP address or FQDN */
9133         public static final String KEY_EPDG_STATIC_ADDRESS_STRING =
9134                 KEY_PREFIX + "epdg_static_address_string";
9135 
9136         /** Epdg static IP address or FQDN for roaming */
9137         public static final String KEY_EPDG_STATIC_ADDRESS_ROAMING_STRING =
9138                 KEY_PREFIX + "epdg_static_address_roaming_string";
9139 
9140         /**
9141          * Enables the use of multiple IKE SA proposals, encompassing both carrier-preferred
9142          * ciphers and all supported ciphers from 3GPP TS 33.210 and RFC 8221,
9143          * as defined in RFC 7296.
9144          */
9145         @FlaggedApi(Flags.FLAG_ENABLE_MULTIPLE_SA_PROPOSALS)
9146         public static final String KEY_SUPPORTS_IKE_SESSION_MULTIPLE_SA_PROPOSALS_BOOL =
9147                 KEY_PREFIX + "supports_ike_session_multiple_sa_proposals_bool";
9148 
9149         /**
9150          * Enables the use of multiple Child SA proposals, encompassing both carrier-preferred
9151          * ciphers and all supported ciphers from 3GPP TS 33.210 and RFC 8221,
9152          * as defined in RFC 7296.
9153          */
9154         @FlaggedApi(Flags.FLAG_ENABLE_MULTIPLE_SA_PROPOSALS)
9155         public static final String KEY_SUPPORTS_CHILD_SESSION_MULTIPLE_SA_PROPOSALS_BOOL =
9156                 KEY_PREFIX + "supports_child_session_multiple_sa_proposals_bool";
9157 
9158         /**
9159          * List of supported key sizes for AES Cipher Block Chaining (CBC) encryption mode of child
9160          * session. Possible values are:
9161          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_UNUSED},
9162          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_128},
9163          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_192},
9164          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_256}
9165          */
9166         public static final String KEY_CHILD_SESSION_AES_CBC_KEY_SIZE_INT_ARRAY =
9167                 KEY_PREFIX + "child_session_aes_cbc_key_size_int_array";
9168 
9169         /**
9170          * List of supported key sizes for AES Counter (CTR) encryption mode of child session.
9171          * Possible values are:
9172          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_UNUSED},
9173          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_128},
9174          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_192},
9175          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_256}
9176          */
9177         public static final String KEY_CHILD_SESSION_AES_CTR_KEY_SIZE_INT_ARRAY =
9178                 KEY_PREFIX + "child_session_aes_ctr_key_size_int_array";
9179 
9180         /**
9181          * List of supported key sizes for AES Galois/Counter Mode (GCM) encryption mode
9182          * of child session.
9183          * Possible values are:
9184          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_UNUSED},
9185          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_128},
9186          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_192},
9187          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_256}
9188          */
9189         @FlaggedApi(Flags.FLAG_ENABLE_AEAD_ALGORITHMS)
9190         public static final String KEY_CHILD_SESSION_AES_GCM_KEY_SIZE_INT_ARRAY =
9191                 KEY_PREFIX + "child_session_aes_gcm_key_size_int_array";
9192 
9193         /**
9194          * List of supported encryption algorithms for child session. Possible values are
9195          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_CBC},
9196          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_CTR}
9197          */
9198         public static final String KEY_SUPPORTED_CHILD_SESSION_ENCRYPTION_ALGORITHMS_INT_ARRAY =
9199                 KEY_PREFIX + "supported_child_session_encryption_algorithms_int_array";
9200 
9201         /**
9202          * List of supported AEAD algorithms for child session. Possible values are
9203          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_GCM_8},
9204          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_GCM_12},
9205          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_GCM_16}
9206          */
9207         @FlaggedApi(Flags.FLAG_ENABLE_AEAD_ALGORITHMS)
9208         public static final String KEY_SUPPORTED_CHILD_SESSION_AEAD_ALGORITHMS_INT_ARRAY =
9209                 KEY_PREFIX + "supported_child_session_aead_algorithms_int_array";
9210 
9211         /**
9212          * Time in seconds after which the IKE session is terminated if rekey procedure is not
9213          * successful. If not set or set to <= 0, default value is 3600 seconds.
9214          */
9215         public static final String KEY_IKE_REKEY_HARD_TIMER_SEC_INT =
9216                 KEY_PREFIX + "ike_rekey_hard_timer_in_sec";
9217 
9218         /**
9219          * Time in seconds after which the IKE session rekey procedure is started. If not set or set
9220          * to <= 0, default value is 3000 seconds.
9221          */
9222         public static final String KEY_IKE_REKEY_SOFT_TIMER_SEC_INT =
9223                 KEY_PREFIX + "ike_rekey_soft_timer_sec_int";
9224 
9225         /**
9226          * List of supported key sizes for AES Cipher Block Chaining (CBC) encryption mode of IKE
9227          * session. Possible values:
9228          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_UNUSED},
9229          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_128},
9230          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_192},
9231          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_256}
9232          */
9233         public static final String KEY_IKE_SESSION_AES_CBC_KEY_SIZE_INT_ARRAY =
9234                 KEY_PREFIX + "ike_session_encryption_aes_cbc_key_size_int_array";
9235 
9236         /**
9237          * List of supported key sizes for AES Counter (CTR) encryption mode of IKE session.
9238          * Possible values -
9239          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_UNUSED},
9240          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_128},
9241          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_192},
9242          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_256}
9243          */
9244          public static final String KEY_IKE_SESSION_AES_CTR_KEY_SIZE_INT_ARRAY =
9245                  KEY_PREFIX + "ike_session_encryption_aes_ctr_key_size_int_array";
9246 
9247         /**
9248          * List of supported key sizes for AES Galois/Counter Mode (GCM) encryption mode
9249          * of IKE session.
9250          * Possible values -
9251          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_UNUSED},
9252          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_128},
9253          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_192},
9254          * {@link android.net.ipsec.ike.SaProposal#KEY_LEN_AES_256}
9255          */
9256         @FlaggedApi(Flags.FLAG_ENABLE_AEAD_ALGORITHMS)
9257         public static final String KEY_IKE_SESSION_AES_GCM_KEY_SIZE_INT_ARRAY =
9258                 KEY_PREFIX + "ike_session_encryption_aes_gcm_key_size_int_array";
9259 
9260         /**
9261          * List of supported encryption algorithms for IKE session. Possible values are
9262          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_CBC},
9263          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_CTR}
9264          */
9265         public static final String KEY_SUPPORTED_IKE_SESSION_ENCRYPTION_ALGORITHMS_INT_ARRAY =
9266                 KEY_PREFIX + "supported_ike_session_encryption_algorithms_int_array";
9267 
9268         /**
9269          * List of supported AEAD algorithms for IKE session. Possible values are
9270          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_GCM_8},
9271          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_GCM_12},
9272          * {@link android.net.ipsec.ike.SaProposal#ENCRYPTION_ALGORITHM_AES_GCM_16}
9273          */
9274         @FlaggedApi(Flags.FLAG_ENABLE_AEAD_ALGORITHMS)
9275         public static final String KEY_SUPPORTED_IKE_SESSION_AEAD_ALGORITHMS_INT_ARRAY =
9276                 KEY_PREFIX + "supported_ike_session_aead_algorithms_int_array";
9277 
9278         /**
9279          * List of supported integrity algorithms for IKE session. Possible values are
9280          * {@link android.net.ipsec.ike.SaProposal#INTEGRITY_ALGORITHM_NONE},
9281          * {@link android.net.ipsec.ike.SaProposal#INTEGRITY_ALGORITHM_HMAC_SHA1_96},
9282          * {@link android.net.ipsec.ike.SaProposal#INTEGRITY_ALGORITHM_AES_XCBC_96},
9283          * {@link android.net.ipsec.ike.SaProposal#INTEGRITY_ALGORITHM_HMAC_SHA2_256_128},
9284          * {@link android.net.ipsec.ike.SaProposal#INTEGRITY_ALGORITHM_HMAC_SHA2_384_192},
9285          * {@link android.net.ipsec.ike.SaProposal#INTEGRITY_ALGORITHM_HMAC_SHA2_512_256}
9286          */
9287         public static final String KEY_SUPPORTED_INTEGRITY_ALGORITHMS_INT_ARRAY =
9288                 KEY_PREFIX + "supported_integrity_algorithms_int_array";
9289 
9290         /** Maximum number of retries for tunnel establishment. */
9291         public static final String KEY_MAX_RETRIES_INT = KEY_PREFIX + "max_retries_int";
9292 
9293         /**
9294          * Time in seconds after which a NATT keep alive message is sent. If not set or set to <= 0,
9295          * default value is 20 seconds.
9296          */
9297         public static final String KEY_NATT_KEEP_ALIVE_TIMER_SEC_INT =
9298                 KEY_PREFIX + "natt_keep_alive_timer_sec_int";
9299 
9300         /** List of '-' separated MCC/MNCs used to create ePDG FQDN as per 3GPP TS 23.003 */
9301         public static final String KEY_MCC_MNCS_STRING_ARRAY = KEY_PREFIX + "mcc_mncs_string_array";
9302 
9303         /**
9304          * List of supported pseudo random function algorithms for IKE session. Possible values are
9305          * {@link android.net.ipsec.ike.SaProposal#PSEUDORANDOM_FUNCTION_HMAC_SHA1},
9306          * {@link android.net.ipsec.ike.SaProposal#PSEUDORANDOM_FUNCTION_AES128_XCBC},
9307          * {@link android.net.ipsec.ike.SaProposal#PSEUDORANDOM_FUNCTION_SHA2_256},
9308          * {@link android.net.ipsec.ike.SaProposal#PSEUDORANDOM_FUNCTION_SHA2_384},
9309          * {@link android.net.ipsec.ike.SaProposal#PSEUDORANDOM_FUNCTION_SHA2_512}
9310          */
9311         public static final String KEY_SUPPORTED_PRF_ALGORITHMS_INT_ARRAY =
9312                 KEY_PREFIX + "supported_prf_algorithms_int_array";
9313 
9314         /**
9315          * List of IKE message retransmission timeouts in milliseconds, where each timeout
9316          * is the waiting time before next retry, except the last timeout which is the waiting time
9317          * before terminating the IKE Session. Min list length = 1, Max
9318          * list length = 10 Min timeout = 500 ms, Max timeout = 1800000 ms
9319          */
9320         public static final String KEY_RETRANSMIT_TIMER_MSEC_INT_ARRAY =
9321                 KEY_PREFIX + "retransmit_timer_sec_int_array";
9322 
9323         /**
9324          * Specifies the local identity type for IKE negotiations. Possible values are {@link
9325          * #ID_TYPE_FQDN}, {@link #ID_TYPE_RFC822_ADDR}, {@link #ID_TYPE_KEY_ID}
9326          */
9327         public static final String KEY_IKE_LOCAL_ID_TYPE_INT = KEY_PREFIX + "ike_local_id_type_int";
9328 
9329         /**
9330          * Specifies the remote identity type for IKE negotiations. Possible values are {@link
9331          * #ID_TYPE_FQDN}, {@link #ID_TYPE_RFC822_ADDR}, {@link #ID_TYPE_KEY_ID}
9332          */
9333         public static final String KEY_IKE_REMOTE_ID_TYPE_INT =
9334                 KEY_PREFIX + "ike_remote_id_type_int";
9335 
9336         /** Controls if KE payload should be added during child session local rekey procedure. */
9337         public static final String KEY_ADD_KE_TO_CHILD_SESSION_REKEY_BOOL =
9338                 KEY_PREFIX + "add_ke_to_child_session_rekey_bool";
9339 
9340         /** Specifies the PCO id for IPv6 Epdg server address */
9341         public static final String KEY_EPDG_PCO_ID_IPV6_INT = KEY_PREFIX + "epdg_pco_id_ipv6_int";
9342 
9343         /** Specifies the PCO id for IPv4 Epdg server address */
9344         public static final String KEY_EPDG_PCO_ID_IPV4_INT = KEY_PREFIX + "epdg_pco_id_ipv4_int";
9345 
9346         /** Controls if the IKE tunnel setup supports EAP-AKA fast reauth */
9347         public static final String KEY_SUPPORTS_EAP_AKA_FAST_REAUTH_BOOL =
9348                 KEY_PREFIX + "supports_eap_aka_fast_reauth_bool";
9349 
9350         /**
9351          * Type of IP preference used to prioritize ePDG servers. Possible values are
9352          * {@link #EPDG_ADDRESS_IPV4_PREFERRED}, {@link #EPDG_ADDRESS_IPV6_PREFERRED},
9353          * {@link #EPDG_ADDRESS_IPV4_ONLY}
9354          */
9355         public static final String KEY_EPDG_ADDRESS_IP_TYPE_PREFERENCE_INT =
9356                 KEY_PREFIX + "epdg_address_ip_type_preference_int";
9357 
9358         /** @hide */
9359         @IntDef({AUTHENTICATION_METHOD_EAP_ONLY, AUTHENTICATION_METHOD_CERT})
9360         public @interface AuthenticationMethodType {}
9361 
9362         /**
9363          * Certificate sent from the server is ignored. Only Extensible Authentication Protocol
9364          * (EAP) is used to authenticate the server. EAP_ONLY_AUTH payload is added to IKE_AUTH
9365          * request if supported.
9366          *
9367          * @see <a href="https://tools.ietf.org/html/rfc5998">RFC 5998</a>
9368          */
9369         public static final int AUTHENTICATION_METHOD_EAP_ONLY = 0;
9370         /** Server is authenticated using its certificate. */
9371         public static final int AUTHENTICATION_METHOD_CERT = 1;
9372 
9373         /** @hide */
9374         @IntDef({
9375             EPDG_ADDRESS_STATIC,
9376             EPDG_ADDRESS_PLMN,
9377             EPDG_ADDRESS_PCO,
9378             EPDG_ADDRESS_CELLULAR_LOC,
9379             EPDG_ADDRESS_VISITED_COUNTRY
9380         })
9381         public @interface EpdgAddressType {}
9382 
9383         /** Use static epdg address. */
9384         public static final int EPDG_ADDRESS_STATIC = 0;
9385         /** Construct the epdg address using plmn. */
9386         public static final int EPDG_ADDRESS_PLMN = 1;
9387         /**
9388          * Use the epdg address received in protocol configuration options (PCO) from the network.
9389          */
9390         public static final int EPDG_ADDRESS_PCO = 2;
9391         /** Use cellular location to chose epdg server */
9392         public static final int EPDG_ADDRESS_CELLULAR_LOC = 3;
9393         /** Use Visited Country FQDN rule*/
9394         public static final int EPDG_ADDRESS_VISITED_COUNTRY = 4;
9395 
9396         /** @hide */
9397         @IntDef({
9398                 EPDG_PLMN_RPLMN,
9399                 EPDG_PLMN_HPLMN,
9400                 EPDG_PLMN_EHPLMN_ALL,
9401                 EPDG_PLMN_EHPLMN_FIRST
9402         })
9403         public @interface EpdgAddressPlmnType {}
9404 
9405         /**
9406          * Use the Registered PLMN
9407          * @hide
9408          */
9409         public static final int EPDG_PLMN_RPLMN = 0;
9410         /**
9411          * Use the PLMN derived from IMSI
9412          * @hide
9413          */
9414         public static final int EPDG_PLMN_HPLMN = 1;
9415         /**
9416          * Use all EHPLMN from SIM EF files
9417          * @hide
9418          */
9419         public static final int EPDG_PLMN_EHPLMN_ALL = 2;
9420         /**
9421          * Use the first EHPLMN from SIM EF files
9422          * @hide
9423          */
9424         public static final int EPDG_PLMN_EHPLMN_FIRST = 3;
9425 
9426         /** @hide */
9427         @IntDef({ID_TYPE_FQDN, ID_TYPE_RFC822_ADDR, ID_TYPE_KEY_ID})
9428         public @interface IkeIdType {}
9429 
9430         /**
9431          * Ike Identification Fully Qualified Domain Name
9432          *
9433          * @see <a href="https://tools.ietf.org/html/rfc7296#section-3.5">RFC 7296, Internet Key
9434          *     Exchange Protocol Version 2 (IKEv2)</a>
9435          */
9436         public static final int ID_TYPE_FQDN = 2;
9437         /**
9438          * Ike Identification Fully Qualified RFC 822 email address.
9439          *
9440          * @see <a href="https://tools.ietf.org/html/rfc7296#section-3.5">RFC 7296, Internet Key
9441          *     Exchange Protocol Version 2 (IKEv2)</a>
9442          */
9443         public static final int ID_TYPE_RFC822_ADDR = 3;
9444         /**
9445          * Ike Identification opaque octet stream for vendor specific information
9446          *
9447          * @see <a href="https://tools.ietf.org/html/rfc7296#section-3.5">RFC 7296, Internet Key
9448          *     Exchange Protocol Version 2 (IKEv2)</a>
9449          */
9450         public static final int ID_TYPE_KEY_ID = 11;
9451 
9452         /** @hide */
9453         @IntDef({
9454                 EPDG_ADDRESS_IPV4_PREFERRED,
9455                 EPDG_ADDRESS_IPV6_PREFERRED,
9456                 EPDG_ADDRESS_IPV4_ONLY,
9457                 EPDG_ADDRESS_IPV6_ONLY,
9458                 EPDG_ADDRESS_SYSTEM_PREFERRED
9459         })
9460         public @interface EpdgAddressIpPreference {}
9461 
9462         /** Prioritize IPv4 ePDG addresses. */
9463         public static final int EPDG_ADDRESS_IPV4_PREFERRED = 0;
9464 
9465         /** Prioritize IPv6 ePDG addresses */
9466         public static final int EPDG_ADDRESS_IPV6_PREFERRED = 1;
9467 
9468         /** Use IPv4 ePDG addresses only. */
9469         public static final int EPDG_ADDRESS_IPV4_ONLY = 2;
9470 
9471         /** Use IPv6 ePDG addresses only.
9472          * @hide
9473          */
9474         public static final int EPDG_ADDRESS_IPV6_ONLY = 3;
9475 
9476         /** Follow the priority from DNS resolution results, which are sorted by using RFC6724
9477          * algorithm.
9478          *
9479          * @see <a href="https://tools.ietf.org/html/rfc6724#section-6">RFC 6724, Default Address
9480          *     Selection for Internet Protocol Version 6 (IPv6)</a>
9481          * @hide
9482          */
9483         public static final int EPDG_ADDRESS_SYSTEM_PREFERRED = 4;
9484 
Iwlan()9485         private Iwlan() {}
9486 
getDefaults()9487         private static PersistableBundle getDefaults() {
9488             PersistableBundle defaults = new PersistableBundle();
9489             defaults.putInt(KEY_IKE_REKEY_SOFT_TIMER_SEC_INT, 7200);
9490             defaults.putInt(KEY_IKE_REKEY_HARD_TIMER_SEC_INT, 14400);
9491             defaults.putInt(KEY_CHILD_SA_REKEY_SOFT_TIMER_SEC_INT, 3600);
9492             defaults.putInt(KEY_CHILD_SA_REKEY_HARD_TIMER_SEC_INT, 7200);
9493             defaults.putBoolean(KEY_SUPPORTS_IKE_SESSION_MULTIPLE_SA_PROPOSALS_BOOL, false);
9494             defaults.putBoolean(KEY_SUPPORTS_CHILD_SESSION_MULTIPLE_SA_PROPOSALS_BOOL, false);
9495             defaults.putIntArray(
9496                     KEY_RETRANSMIT_TIMER_MSEC_INT_ARRAY, new int[] {500, 1000, 2000, 4000, 8000});
9497             defaults.putInt(KEY_DPD_TIMER_SEC_INT, 120);
9498             defaults.putInt(KEY_MAX_RETRIES_INT, 3);
9499             defaults.putIntArray(
9500                     KEY_DIFFIE_HELLMAN_GROUPS_INT_ARRAY,
9501                     new int[] {
9502                         SaProposal.DH_GROUP_1024_BIT_MODP,
9503                         SaProposal.DH_GROUP_1536_BIT_MODP,
9504                         SaProposal.DH_GROUP_2048_BIT_MODP
9505                     });
9506             defaults.putIntArray(
9507                     KEY_SUPPORTED_IKE_SESSION_ENCRYPTION_ALGORITHMS_INT_ARRAY,
9508                     new int[] {SaProposal.ENCRYPTION_ALGORITHM_AES_CBC});
9509             defaults.putIntArray(
9510                     KEY_SUPPORTED_IKE_SESSION_AEAD_ALGORITHMS_INT_ARRAY, new int[] {});
9511             defaults.putIntArray(
9512                     KEY_SUPPORTED_CHILD_SESSION_ENCRYPTION_ALGORITHMS_INT_ARRAY,
9513                     new int[] {SaProposal.ENCRYPTION_ALGORITHM_AES_CBC});
9514             defaults.putIntArray(
9515                     KEY_SUPPORTED_CHILD_SESSION_AEAD_ALGORITHMS_INT_ARRAY, new int[] {});
9516             defaults.putIntArray(
9517                     KEY_SUPPORTED_INTEGRITY_ALGORITHMS_INT_ARRAY,
9518                     new int[] {
9519                         SaProposal.INTEGRITY_ALGORITHM_AES_XCBC_96,
9520                         SaProposal.INTEGRITY_ALGORITHM_HMAC_SHA1_96,
9521                         SaProposal.INTEGRITY_ALGORITHM_HMAC_SHA2_256_128,
9522                         SaProposal.INTEGRITY_ALGORITHM_HMAC_SHA2_384_192,
9523                         SaProposal.INTEGRITY_ALGORITHM_HMAC_SHA2_512_256,
9524                     });
9525             defaults.putIntArray(
9526                     KEY_SUPPORTED_PRF_ALGORITHMS_INT_ARRAY,
9527                     new int[] {
9528                         SaProposal.PSEUDORANDOM_FUNCTION_HMAC_SHA1,
9529                         SaProposal.PSEUDORANDOM_FUNCTION_AES128_XCBC,
9530                         SaProposal.PSEUDORANDOM_FUNCTION_SHA2_256,
9531                         SaProposal.PSEUDORANDOM_FUNCTION_SHA2_384,
9532                         SaProposal.PSEUDORANDOM_FUNCTION_SHA2_512
9533                     });
9534 
9535             defaults.putInt(KEY_EPDG_AUTHENTICATION_METHOD_INT, AUTHENTICATION_METHOD_EAP_ONLY);
9536             defaults.putString(KEY_EPDG_STATIC_ADDRESS_STRING, "");
9537             defaults.putString(KEY_EPDG_STATIC_ADDRESS_ROAMING_STRING, "");
9538             // will be used after b/158036773 is fixed
9539             defaults.putInt(KEY_NATT_KEEP_ALIVE_TIMER_SEC_INT, 20);
9540             defaults.putIntArray(
9541                     KEY_IKE_SESSION_AES_CBC_KEY_SIZE_INT_ARRAY,
9542                     new int[] {
9543                       SaProposal.KEY_LEN_AES_128,
9544                       SaProposal.KEY_LEN_AES_192,
9545                       SaProposal.KEY_LEN_AES_256});
9546             defaults.putIntArray(
9547                     KEY_CHILD_SESSION_AES_CBC_KEY_SIZE_INT_ARRAY,
9548                     new int[] {
9549                       SaProposal.KEY_LEN_AES_128,
9550                       SaProposal.KEY_LEN_AES_192,
9551                       SaProposal.KEY_LEN_AES_256});
9552             defaults.putIntArray(
9553                     KEY_IKE_SESSION_AES_CTR_KEY_SIZE_INT_ARRAY,
9554                     new int[] {
9555                       SaProposal.KEY_LEN_AES_128,
9556                       SaProposal.KEY_LEN_AES_192,
9557                       SaProposal.KEY_LEN_AES_256});
9558             defaults.putIntArray(
9559                     KEY_CHILD_SESSION_AES_CTR_KEY_SIZE_INT_ARRAY,
9560                     new int[] {
9561                       SaProposal.KEY_LEN_AES_128,
9562                       SaProposal.KEY_LEN_AES_192,
9563                       SaProposal.KEY_LEN_AES_256});
9564             defaults.putIntArray(
9565                     KEY_IKE_SESSION_AES_GCM_KEY_SIZE_INT_ARRAY, new int[] {});
9566             defaults.putIntArray(
9567                     KEY_CHILD_SESSION_AES_GCM_KEY_SIZE_INT_ARRAY, new int[] {});
9568             defaults.putIntArray(
9569                     KEY_EPDG_ADDRESS_PRIORITY_INT_ARRAY,
9570                     new int[] {EPDG_ADDRESS_PLMN, EPDG_ADDRESS_STATIC});
9571             defaults.putIntArray(
9572                     KEY_EPDG_PLMN_PRIORITY_INT_ARRAY,
9573                     new int[]{
9574                             EPDG_PLMN_RPLMN,
9575                             EPDG_PLMN_HPLMN,
9576                             EPDG_PLMN_EHPLMN_ALL});
9577             defaults.putStringArray(KEY_MCC_MNCS_STRING_ARRAY, new String[0]);
9578             defaults.putInt(KEY_IKE_LOCAL_ID_TYPE_INT, ID_TYPE_RFC822_ADDR);
9579             defaults.putInt(KEY_IKE_REMOTE_ID_TYPE_INT, ID_TYPE_FQDN);
9580             defaults.putBoolean(KEY_ADD_KE_TO_CHILD_SESSION_REKEY_BOOL, false);
9581             defaults.putInt(KEY_EPDG_PCO_ID_IPV6_INT, 0);
9582             defaults.putInt(KEY_EPDG_PCO_ID_IPV4_INT, 0);
9583             defaults.putBoolean(KEY_SUPPORTS_EAP_AKA_FAST_REAUTH_BOOL, false);
9584             defaults.putInt(KEY_EPDG_ADDRESS_IP_TYPE_PREFERENCE_INT, EPDG_ADDRESS_IPV4_PREFERRED);
9585             return defaults;
9586         }
9587     }
9588 
9589     /**
9590      * A list of 4 GSM RSSI thresholds above which a signal level is considered POOR,
9591      * MODERATE, GOOD, or EXCELLENT, to be used in SignalStrength reporting.
9592      *
9593      * Note that the min and max thresholds are fixed at -113 and -51, as set in 3GPP TS 27.007
9594      * section 8.5.
9595      * <p>
9596      * See CellSignalStrengthGsm#GSM_RSSI_MAX and CellSignalStrengthGsm#GSM_RSSI_MIN. Any signal
9597      * level outside these boundaries is considered invalid.
9598      * @hide
9599      */
9600     public static final String KEY_GSM_RSSI_THRESHOLDS_INT_ARRAY = "gsm_rssi_thresholds_int_array";
9601 
9602     /**
9603      * An interval in dB for {@link SignalThresholdInfo#SIGNAL_MEASUREMENT_TYPE_RSSI} measurement
9604      * type defining the required magnitude change between reports.
9605      *
9606      * <p>The default value is 2 and the minimum allowed value is 0. If no value or negative value
9607      * is set, the default value 2 is used.
9608      * @hide
9609      */
9610     public static final String KEY_GERAN_RSSI_HYSTERESIS_DB_INT = "geran_rssi_hysteresis_db_int";
9611 
9612     /**
9613      * Determines whether Wireless Priority Service call is supported over IMS.
9614      *
9615      * See Wireless Priority Service from https://www.fcc.gov/general/wireless-priority-service-wps
9616      * @hide
9617      */
9618     public static final String KEY_SUPPORT_WPS_OVER_IMS_BOOL = "support_wps_over_ims_bool";
9619 
9620     /**
9621      * The two digital number pattern of MMI code which is defined by carrier.
9622      * If the dial number matches this pattern, it will be dialed out normally not USSD.
9623      *
9624      * @hide
9625      */
9626     public static final String KEY_MMI_TWO_DIGIT_NUMBER_PATTERN_STRING_ARRAY =
9627             "mmi_two_digit_number_pattern_string_array";
9628 
9629     /**
9630      * Holds the list of carrier certificate hashes, followed by optional package names.
9631      * Format: "sha1/256" or "sha1/256:package1,package2,package3..."
9632      * Note that each carrier has its own hashes.
9633      */
9634     public static final String KEY_CARRIER_CERTIFICATE_STRING_ARRAY =
9635             "carrier_certificate_string_array";
9636 
9637     /**
9638      * Flag specifying whether the incoming call number and the conference participant number
9639      * should be formatted to national number for Japan.
9640      * @return {@code true} convert to the national format, {@code false} otherwise.
9641      * e.g. "+819012345678" -> "09012345678"
9642      * @hide
9643      */
9644     public static final String KEY_FORMAT_INCOMING_NUMBER_TO_NATIONAL_FOR_JP_BOOL =
9645             "format_incoming_number_to_national_for_jp_bool";
9646 
9647     /**
9648      * DisconnectCause array to play busy tone. Value should be array of
9649      * {@link android.telephony.DisconnectCause}.
9650      */
9651     public static final String KEY_DISCONNECT_CAUSE_PLAY_BUSYTONE_INT_ARRAY =
9652             "disconnect_cause_play_busytone_int_array";
9653 
9654     /**
9655      * Flag specifying whether to prevent sending CLIR activation("*31#") and deactivation("#31#")
9656      * code only without dialing number.
9657      * When {@code true}, these are prevented, {@code false} otherwise.
9658      */
9659     public static final String KEY_PREVENT_CLIR_ACTIVATION_AND_DEACTIVATION_CODE_BOOL =
9660             "prevent_clir_activation_and_deactivation_code_bool";
9661 
9662     /**
9663      * Flag specifying whether to show forwarded number on call-in-progress screen.
9664      * When true, forwarded number is shown.
9665      * When false, forwarded number is not shown.
9666      */
9667     public static final String KEY_SHOW_FORWARDED_NUMBER_BOOL = "show_forwarded_number_bool";
9668 
9669     /**
9670      * The list of originating address of missed incoming call SMS. If the SMS has originator
9671      * matched, the SMS will be treated as special SMS for notifying missed incoming call to the
9672      * user.
9673      *
9674      * @hide
9675      */
9676     public static final String KEY_MISSED_INCOMING_CALL_SMS_ORIGINATOR_STRING_ARRAY =
9677             "missed_incoming_call_sms_originator_string_array";
9678 
9679     /**
9680      * Network capability priority for determine the satisfy order in telephony. The priority is
9681      * from the lowest 0 to the highest 100. The long-lived network shall have the lowest priority.
9682      * This allows other short-lived requests like MMS requests to be established. Emergency request
9683      * always has the highest priority.
9684      *
9685      * @hide
9686      */
9687     public static final String KEY_TELEPHONY_NETWORK_CAPABILITY_PRIORITIES_STRING_ARRAY =
9688             "telephony_network_capability_priorities_string_array";
9689 
9690     /**
9691      * Defines the rules for data setup retry.
9692      *
9693      * The syntax of the retry rule:
9694      * 1. Retry based on {@link NetworkCapabilities}. If the capabilities are not specified, then
9695      * the retry rule only applies to the current failed APN used in setup data call request.
9696      * "capabilities=[netCaps1|netCaps2|...], [retry_interval=n1|n2|n3|n4...], [maximum_retries=n]"
9697      *
9698      * 2. Retry based on {@link DataFailCause}
9699      * "fail_causes=[cause1|cause2|cause3|..], [retry_interval=n1|n2|n3|n4...], [maximum_retries=n]"
9700      *
9701      * 3. Retry based on {@link NetworkCapabilities} and {@link DataFailCause}. Note that only
9702      *    APN-type network capabilities are supported.
9703      * "capabilities=[netCaps1|netCaps2|...], fail_causes=[cause1|cause2|cause3|...],
9704      *     [retry_interval=n1|n2|n3|n4...], [maximum_retries=n]"
9705      *
9706      * 4. Permanent fail causes (no timer-based retry) on the current failed APN. Retry interval
9707      *    is specified for retrying the next available APN.
9708      * "permanent_fail_causes=8|27|28|29|30|32|33|35|50|51|111|-5|-6|65537|65538|-3|65543|65547|
9709      *     2252|2253|2254, retry_interval=2500"
9710      *
9711      * For example,
9712      * "capabilities=eims, retry_interval=1000, maximum_retries=20" means if the attached
9713      * network request is emergency, then retry data network setup every 1 second for up to 20
9714      * times.
9715      *
9716      * "capabilities=internet|enterprise|dun|ims|fota, retry_interval=2500|3000|"
9717      * "5000|10000|15000|20000|40000|60000|120000|240000|600000|1200000|1800000"
9718      * "1800000, maximum_retries=20" means for those capabilities, retry happens in 2.5s, 3s, 5s,
9719      * 10s, 15s, 20s, 40s, 1m, 2m, 4m, 10m, 20m, 30m, 30m, 30m, until reaching 20 retries.
9720      *
9721      * @hide
9722      */
9723     public static final String KEY_TELEPHONY_DATA_SETUP_RETRY_RULES_STRING_ARRAY =
9724             "telephony_data_setup_retry_rules_string_array";
9725 
9726     /**
9727      * Defines the rules for data handover retry.
9728      *
9729      * The syntax of the retry rule:
9730      * 1. Retry when handover fails.
9731      * "retry_interval=[n1|n2|n3|...], [maximum_retries=n]"
9732      *
9733      * For example,
9734      * "retry_interval=1000|3000|5000, maximum_retries=10" means handover retry will happen in 1s,
9735      * 3s, 5s, 5s, 5s....up to 10 times.
9736      *
9737      * 2. Retry when handover fails with certain fail causes.
9738      * "retry_interval=[n1|n2|n3|...], fail_causes=[cause1|cause2|cause3|...], [maximum_retries=n]
9739      *
9740      * For example,
9741      * "retry_interval=1000, maximum_retries=3, fail_causes=5" means handover retry every 1 second
9742      * for up to 3 times when handover fails with the cause 5.
9743      *
9744      * "maximum_retries=0, fail_causes=6|10|67" means handover retry should not happen for those
9745      * causes.
9746      *
9747      * @hide
9748      */
9749     public static final String KEY_TELEPHONY_DATA_HANDOVER_RETRY_RULES_STRING_ARRAY =
9750             "telephony_data_handover_retry_rules_string_array";
9751 
9752     /**
9753      * Indicates whether delay tearing down IMS data network until voice call ends.
9754      * @hide
9755      */
9756     public static final String KEY_DELAY_IMS_TEAR_DOWN_UNTIL_CALL_END_BOOL =
9757             "delay_ims_tear_down_until_call_end_bool";
9758 
9759     /**
9760      * The patterns of missed incoming call sms. This is the regular expression used for
9761      * matching the missed incoming call's date, time, and caller id. The pattern should match
9762      * fields for at least month, day, hour, and minute. Year is optional although it is encouraged.
9763      *
9764      * An usable pattern should look like this:
9765      * ^(?<month>0[1-9]|1[012])\/(?<day>0[1-9]|1[0-9]|2[0-9]|3[0-1]) (?<hour>[0-1][0-9]|2[0-3]):
9766      * (?<minute>[0-5][0-9])\s*(?<callerId>[0-9]+)\s*$
9767      *
9768      * @hide
9769      */
9770     public static final String KEY_MISSED_INCOMING_CALL_SMS_PATTERN_STRING_ARRAY =
9771             "missed_incoming_call_sms_pattern_string_array";
9772 
9773     /**
9774      * A PersistableBundle that contains a list of key-value pairs, where the values are integer
9775      * arrays.
9776      * <p>
9777      * Keys are the PLMNs of satellite providers as strings and values are integer arrays of
9778      * supported services with the following value:
9779      * <ul>
9780      * <li>1 = {@link android.telephony.NetworkRegistrationInfo#SERVICE_TYPE_VOICE}</li>
9781      * <li>2 = {@link android.telephony.NetworkRegistrationInfo#SERVICE_TYPE_DATA}</li>
9782      * <li>3 = {@link android.telephony.NetworkRegistrationInfo#SERVICE_TYPE_SMS}</li>
9783      * <li>4 = {@link android.telephony.NetworkRegistrationInfo#SERVICE_TYPE_VIDEO}</li>
9784      * <li>5 = {@link android.telephony.NetworkRegistrationInfo#SERVICE_TYPE_EMERGENCY}</li>
9785      * <li>6 = {@link android.telephony.NetworkRegistrationInfo#SERVICE_TYPE_MMS}</li>
9786      * </ul>
9787      * <p>
9788      * An example config for two PLMNs "123411" and "123412":
9789      * <pre>{@code
9790      * <carrier_config>
9791      *   <pbundle_as_map name="carrier_supported_satellite_services_per_provider_bundle">
9792      *     <int-array name = "123411" num = "2">
9793      *       <item value = "3"/>
9794      *       <item value = "5"/>
9795      *     </int-array>
9796      *     <int-array name = "123412" num = "1">
9797      *       <item value = "3"/>
9798      *     </int-array>
9799      *   </pbundle_as_map>
9800      * </carrier_config>
9801      * }</pre>
9802      * <p>
9803      * This config is empty by default.
9804      */
9805     public static final String KEY_CARRIER_SUPPORTED_SATELLITE_SERVICES_PER_PROVIDER_BUNDLE =
9806             "carrier_supported_satellite_services_per_provider_bundle";
9807 
9808     /**
9809      * A PersistableBundle that contains a list of key-value pairs, where the values are integer
9810      * arrays.
9811      * <p>
9812      * Keys are the IDs of regional satellite configs as strings and values are
9813      * integer arrays of earfcns in the corresponding regions.
9814      *
9815      * An example config for two regions "1" and "2":
9816      * <pre>{@code
9817      * <carrier_config>
9818      *   <pbundle_as_map name="regional_satellite_earfcn_bundle">
9819      *     <int-array name = "1" num = "2">
9820      *       <item value = "100"/>
9821      *       <item value = "200"/>
9822      *     </int-array>
9823      *     <int-array name = "2" num = "1">
9824      *       <item value = "200"/>
9825      *     </int-array>
9826      *   </pbundle_as_map>
9827      * </carrier_config>
9828      * }</pre>
9829      * <p>
9830      * This config is empty by default.
9831      */
9832     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
9833     public static final String KEY_REGIONAL_SATELLITE_EARFCN_BUNDLE =
9834             "regional_satellite_earfcn_bundle";
9835 
9836     /**
9837      * This config enables modem to scan satellite PLMNs specified as per
9838      * {@link #KEY_CARRIER_SUPPORTED_SATELLITE_SERVICES_PER_PROVIDER_BUNDLE} and attach to same
9839      * in case cellular networks are not enabled. This will need specific agreement between
9840      * satellite provider and the carrier before enabling this flag.
9841      *
9842      * The default value is false.
9843      */
9844     public static final String KEY_SATELLITE_ATTACH_SUPPORTED_BOOL =
9845             "satellite_attach_supported_bool";
9846 
9847     /**
9848      * The carrier-enabled satellite connection hysteresis time in seconds for which the device
9849      * continues in satellite mode after it loses the connection with the satellite network.
9850      * <p>
9851      * If the device is in satellite mode, the following actions will be taken by the device:
9852      * <ul>
9853      * <li>System UI will continue showing the satellite icon.</li>
9854      * <li>When there is an ongoing emergency call, and the IMS is not registered, and cellular
9855      * service is not available, and the device is in satellite mode, a timer with a duration
9856      * defined by the overlay config
9857      * {@code config_emergency_call_wait_for_connection_timeout_millis} will be started. When the
9858      * timer expires, Telephony will send the event
9859      * {@link TelephonyManager#EVENT_DISPLAY_EMERGENCY_MESSAGE} to Dialer, which will then prompt
9860      * users to switch to using satellite emergency messaging.</li>
9861      * </ul>
9862      * <p>
9863      * The default value is 180 seconds.
9864      */
9865     public static final String KEY_SATELLITE_CONNECTION_HYSTERESIS_SEC_INT =
9866             "satellite_connection_hysteresis_sec_int";
9867 
9868     /**
9869      * This threshold is used when connected to a non-terrestrial LTE network.
9870      * A list of 4 NTN LTE RSRP thresholds above which a signal level is considered POOR,
9871      * MODERATE, GOOD, or EXCELLENT, to be used in SignalStrength reporting.
9872      *
9873      * Note that the min and max thresholds are fixed at -140 and -44, as explained in
9874      * TS 136.133 9.1.4 - RSRP Measurement Report Mapping.
9875      * <p>
9876      * See SignalStrength#MAX_LTE_RSRP and SignalStrength#MIN_LTE_RSRP. Any signal level outside
9877      * these boundaries is considered invalid.
9878      */
9879     public static final String KEY_NTN_LTE_RSRP_THRESHOLDS_INT_ARRAY =
9880             "ntn_lte_rsrp_thresholds_int_array";
9881 
9882     /**
9883      * This threshold is used when connected to a non-terrestrial LTE network.
9884      * A list of 4 customized NTN LTE Reference Signal Received Quality (RSRQ) thresholds.
9885      *
9886      * Reference: TS 136.133 v12.6.0 section 9.1.7 - RSRQ Measurement Report Mapping.
9887      *
9888      * 4 threshold integers must be within the boundaries [-34 dB, 3 dB], and the levels are:
9889      *     "NONE: [-34, threshold1)"
9890      *     "POOR: [threshold1, threshold2)"
9891      *     "MODERATE: [threshold2, threshold3)"
9892      *     "GOOD:  [threshold3, threshold4)"
9893      *     "EXCELLENT:  [threshold4, 3]"
9894      *
9895      * This key is considered invalid if the format is violated. If the key is invalid or
9896      * not configured, a default value set will apply.
9897      */
9898     public static final String KEY_NTN_LTE_RSRQ_THRESHOLDS_INT_ARRAY =
9899             "ntn_lte_rsrq_thresholds_int_array";
9900 
9901     /**
9902      * This threshold is used when connected to a non-terrestrial LTE network.
9903      * A list of 4 customized NTN LTE Reference Signal Signal to Noise Ratio (RSSNR) thresholds.
9904      *
9905      * 4 threshold integers must be within the boundaries [-20 dB, 30 dB], and the levels are:
9906      *     "NONE: [-20, threshold1)"
9907      *     "POOR: [threshold1, threshold2)"
9908      *     "MODERATE: [threshold2, threshold3)"
9909      *     "GOOD:  [threshold3, threshold4)"
9910      *     "EXCELLENT:  [threshold4, 30]"
9911      *
9912      * This key is considered invalid if the format is violated. If the key is invalid or
9913      * not configured, a default value set will apply.
9914      */
9915     public static final String KEY_NTN_LTE_RSSNR_THRESHOLDS_INT_ARRAY =
9916             "ntn_lte_rssnr_thresholds_int_array";
9917 
9918     /**
9919      * This threshold is used when connected to a non-terrestrial LTE network.
9920      * Bit-field integer to determine whether to use Reference Signal Received Power (RSRP),
9921      * Reference Signal Received Quality (RSRQ), or/and Reference Signal Signal to Noise Ratio
9922      * (RSSNR) for the number of NTN LTE signal bars and signal criteria reporting enabling.
9923      *
9924      * <p> If a measure is not set, signal criteria reporting from modem will not be triggered and
9925      * not be used for calculating signal level. If multiple measures are set bit, the parameter
9926      * whose value is smallest is used to indicate the signal level.
9927      * <UL>
9928      *  <LI>RSRP = 1 << 0</LI>
9929      *  <LI>RSRQ = 1 << 1</LI>
9930      *  <LI>RSSNR = 1 << 2</LI>
9931      * </UL>
9932      * <p> The value of this key must be bitwise OR of CellSignalStrengthLte#USE_RSRP,
9933      * CellSignalStrengthLte#USE_RSRQ, CellSignalStrengthLte#USE_RSSNR.
9934      *
9935      * <p> For example, if both RSRP and RSRQ are used, the value of key is 3 (1 << 0 | 1 << 1).
9936      * If the key is invalid or not configured, a default value (RSRP = 1 << 0) will apply.
9937      *
9938      */
9939     public static final String KEY_PARAMETERS_USED_FOR_NTN_LTE_SIGNAL_BAR_INT =
9940             "parameters_used_for_ntn_lte_signal_bar_int";
9941 
9942     /**
9943      * Indicating whether plmns associated with carrier satellite can be exposed to user when
9944      * manually scanning available cellular network.
9945      * If key is {@code true}, satellite plmn should not be exposed to user and should be
9946      * automatically set, {@code false} otherwise. Default value is {@code true}.
9947      */
9948     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
9949     public static final String KEY_REMOVE_SATELLITE_PLMN_IN_MANUAL_NETWORK_SCAN_BOOL =
9950             "remove_satellite_plmn_in_manual_network_scan_bool";
9951 
9952     /**
9953      * This value is used to set the max datagram size in bytes.
9954      * If the value is not available then the default value will be used.
9955      *
9956      * The default value is 255 bytes.
9957      */
9958     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
9959     public static final String KEY_SATELLITE_SOS_MAX_DATAGRAM_SIZE_BYTES_INT =
9960             "satellite_sos_max_datagram_size_bytes_int";
9961 
9962     /** @hide */
9963     @IntDef({
9964             SATELLITE_DATA_SUPPORT_ONLY_RESTRICTED,
9965             SATELLITE_DATA_SUPPORT_BANDWIDTH_CONSTRAINED,
9966             SATELLITE_DATA_SUPPORT_ALL,
9967     })
9968     public @interface SATELLITE_DATA_SUPPORT_MODE {}
9969 
9970     /**
9971      * Doesn't support unrestricted traffic on satellite network.
9972      */
9973     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
9974     public static final int SATELLITE_DATA_SUPPORT_ONLY_RESTRICTED = 0;
9975     /**
9976      * Support unrestricted but bandwidth_constrained traffic on satellite network.
9977      */
9978     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
9979     public static final int SATELLITE_DATA_SUPPORT_BANDWIDTH_CONSTRAINED = 1;
9980     /**
9981      * Support unrestricted satellite network that serves all traffic.
9982      */
9983     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
9984     public static final int SATELLITE_DATA_SUPPORT_ALL = 2;
9985     /**
9986      * Indicates what kind of traffic an {@link NetworkCapabilities#NET_CAPABILITY_NOT_RESTRICTED}
9987      * satellite network can possibly support. The network may subject to further
9988      * restrictions such as entitlement etc.
9989      * If no data is allowed on satellite network, exclude
9990      * {@link ApnSetting#INFRASTRUCTURE_SATELLITE} from APN infrastructure_bitmask, and this
9991      * configuration is ignored.
9992      * By default it only supports restricted data.
9993      */
9994     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
9995     public static final String KEY_SATELLITE_DATA_SUPPORT_MODE_INT =
9996             "satellite_data_support_mode_int";
9997 
9998     /**
9999      * Determines whether data roaming off setting should be ignored and satellite data should be
10000      * allowed even when data roaming is off.
10001      *
10002      * If the carrier would like to allow the device to use satellite connection when data roaming
10003      * is off, this key should be set to {@code true}.
10004      *
10005      * The default value is {@code false} i.e. disallow satellite data when data roaming is off.
10006      */
10007     @FlaggedApi(Flags.FLAG_SATELLITE_25Q4_APIS)
10008     public static final String KEY_SATELLITE_IGNORE_DATA_ROAMING_SETTING_BOOL =
10009         "satellite_ignore_data_roaming_setting_bool";
10010 
10011     /**
10012      * Determine whether to override roaming Wi-Fi Calling preference when device is connected to
10013      * non-terrestrial network.
10014      * {@code true}  - roaming preference cannot be changed by user independently.
10015      *                 Roaming preference is overridden to
10016      *                 {@link com.android.ims.ImsConfig.WfcModeFeatureValueConstants#WIFI_PREFERRED}
10017      * {@code false} - roaming preference can be changed by user independently and is not
10018      *                 overridden when device is connected to non-terrestrial network.
10019      */
10020     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10021     public static final String KEY_OVERRIDE_WFC_ROAMING_MODE_WHILE_USING_NTN_BOOL =
10022             "override_wfc_roaming_mode_while_using_ntn_bool";
10023 
10024     /**
10025      * An integer key holds the time interval for refreshing or re-querying the satellite
10026      * entitlement status from the entitlement server to ensure it is the latest.
10027      *
10028      * The default value is 7 days.
10029      */
10030     public static final String KEY_SATELLITE_ENTITLEMENT_STATUS_REFRESH_DAYS_INT =
10031             "satellite_entitlement_status_refresh_days_int";
10032 
10033     /**
10034      * This configuration enables device to query the entitlement server to get the satellite
10035      * configuration.
10036      * This will need agreement the carrier before enabling this flag.
10037      *
10038      * The default value is false.
10039      */
10040     public static final String KEY_SATELLITE_ENTITLEMENT_SUPPORTED_BOOL =
10041             "satellite_entitlement_supported_bool";
10042 
10043     /**
10044      * Indicates the appName that is used when querying the entitlement server for satellite.
10045      *
10046      * The default value is androidSatmode.
10047      *
10048      * Reference: GSMA TS.43-v11, 2.8.5 Fast Authentication and Token Management.
10049      * `app_name` is an optional attribute in the request and may vary depending on the carrier
10050      * requirement.
10051      */
10052     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10053     public static final String KEY_SATELLITE_ENTITLEMENT_APP_NAME_STRING =
10054             "satellite_entitlement_app_name_string";
10055 
10056     /**
10057      * URL to redirect user to get more information about the carrier support for satellite.
10058      *
10059      * The default value is empty string.
10060      */
10061     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10062     public static final String KEY_SATELLITE_INFORMATION_REDIRECT_URL_STRING =
10063             "satellite_information_redirect_url_string";
10064     /**
10065      * Indicate whether a carrier supports emergency messaging. When this config is {@code  false},
10066      * emergency call to satellite T911 handover will be disabled.
10067      *
10068      * This will need agreement with carriers before enabling this flag.
10069      *
10070      * The default value is false.
10071      */
10072     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10073     public static final String KEY_EMERGENCY_MESSAGING_SUPPORTED_BOOL =
10074             "emergency_messaging_supported_bool";
10075 
10076     /**
10077      * An integer key holds the timeout duration in milliseconds used to determine whether to hand
10078      * over an emergency call to satellite T911.
10079      *
10080      * The timer is started when there is an ongoing emergency call, and the IMS is not registered,
10081      * and cellular service is not available. When the timer expires,
10082      * {@link com.android.internal.telephony.satellite.SatelliteSOSMessageRecommender} will send the
10083      * event {@link TelephonyManager#EVENT_DISPLAY_EMERGENCY_MESSAGE} to Dialer, which will then
10084      * prompt user to switch to using satellite emergency messaging.
10085      *
10086      * The default value is 30 seconds.
10087      */
10088     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10089     public static final String KEY_EMERGENCY_CALL_TO_SATELLITE_T911_HANDOVER_TIMEOUT_MILLIS_INT =
10090             "emergency_call_to_satellite_t911_handover_timeout_millis_int";
10091 
10092     /**
10093      * An int array that contains default capabilities for carrier enabled satellite roaming.
10094      * If any PLMN is provided from the entitlement server, and it is not listed in
10095      * {@link #KEY_CARRIER_SUPPORTED_SATELLITE_SERVICES_PER_PROVIDER_BUNDLE}, default capabilities
10096      * will be used instead.
10097      * <p>
10098      * The default capabilities are
10099      * {@link NetworkRegistrationInfo#SERVICE_TYPE_SMS}, and
10100      * {@link NetworkRegistrationInfo#SERVICE_TYPE_MMS}
10101      */
10102     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10103     public static final String KEY_CARRIER_ROAMING_SATELLITE_DEFAULT_SERVICES_INT_ARRAY =
10104             "carrier_roaming_satellite_default_services_int_array";
10105 
10106     /**
10107      * Indicate whether carrier roaming to satellite is using ESOS (Emergency SOS) which connects
10108      * to an emergency provider instead of PSAP (Public Safety Answering Point) for emergency
10109      * messaging.
10110      *
10111      * This will need agreement with carriers before enabling this flag.
10112      *
10113      * The default value is false.
10114      */
10115     @FlaggedApi(Flags.FLAG_CARRIER_ROAMING_NB_IOT_NTN)
10116     public static final String KEY_SATELLITE_ESOS_SUPPORTED_BOOL = "satellite_esos_supported_bool";
10117 
10118     /**
10119      * Indicate whether carrier roaming to satellite is using P2P SMS.
10120      *
10121      * This will need agreement with carriers before enabling this flag.
10122      *
10123      * The default value is false.
10124      */
10125     @FlaggedApi(Flags.FLAG_CARRIER_ROAMING_NB_IOT_NTN)
10126     public static final String KEY_SATELLITE_ROAMING_P2P_SMS_SUPPORTED_BOOL =
10127             "satellite_roaming_p2p_sms_supported_bool";
10128 
10129     /**
10130      * Defines the NIDD (Non-IP Data Delivery) APN to be used for carrier roaming to satellite
10131      * attachment. For more on NIDD, see 3GPP TS 29.542.
10132      * Note this config is the only source of truth regarding the definition of the APN.
10133      */
10134     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10135     public static final String KEY_SATELLITE_NIDD_APN_NAME_STRING =
10136             "satellite_nidd_apn_name_string";
10137 
10138     /**
10139      * The display name that will be used for satellite functionality within the UI.
10140      * The default string value is empty string.
10141      */
10142     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10143     public static final String KEY_SATELLITE_DISPLAY_NAME_STRING = "satellite_display_name_string";
10144 
10145     /**
10146      * Default value {@code true}, meaning when an emergency call request comes in, if the device is
10147      * in emergency satellite mode but hasn't sent the first satellite datagram, then exits
10148      * satellite mode to allow the emergency call to go through.
10149      *
10150      * If {@code false}, the emergency call is always blocked if device is in emergency satellite
10151      * mode. Note if device is NOT in emergency satellite mode, emergency call is always allowed.
10152      */
10153     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10154     public static final String KEY_SATELLITE_ROAMING_TURN_OFF_SESSION_FOR_EMERGENCY_CALL_BOOL =
10155             "satellite_roaming_turn_off_session_for_emergency_call_bool";
10156 
10157     /** @hide */
10158     @IntDef({
10159             CARRIER_ROAMING_NTN_CONNECT_AUTOMATIC,
10160             CARRIER_ROAMING_NTN_CONNECT_MANUAL,
10161     })
10162     public @interface CARRIER_ROAMING_NTN_CONNECT_TYPE {}
10163 
10164     /**
10165      * Device can connect to carrier roaming non-terrestrial network automatically.
10166      */
10167     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10168     public static final int CARRIER_ROAMING_NTN_CONNECT_AUTOMATIC = 0;
10169     /**
10170      * Device can connect to carrier roaming non-terrestrial network only if user manually triggers
10171      * satellite connection.
10172      */
10173     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10174     public static final int CARRIER_ROAMING_NTN_CONNECT_MANUAL = 1;
10175     /**
10176      * Indicates carrier roaming non-terrestrial network connect type that the device can use to
10177      * perform satellite communication.
10178      * If this key is set to CARRIER_ROAMING_NTN_CONNECT_MANUAL then connect button will be
10179      * displayed to user when the device is eligible to use carrier roaming
10180      * non-terrestrial network.
10181      */
10182     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10183     public static final String KEY_CARRIER_ROAMING_NTN_CONNECT_TYPE_INT =
10184             "carrier_roaming_ntn_connect_type_int";
10185 
10186     /**
10187      * Indicates carrier roaming non-terrestrial network emergency call handover type that the
10188      * device will use to perform a handover between ESOS or T911.
10189      * If this key is set to {@link SatelliteManager#EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_SOS}
10190      * then the handover will be made to ESOS. If this key is set to
10191      * {@link SatelliteManager#EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_T911} then the handover
10192      * will be made to T911.
10193      *
10194      * The default value is {@link SatelliteManager#EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_T911}.
10195      */
10196     @FlaggedApi(Flags.FLAG_CARRIER_ROAMING_NB_IOT_NTN)
10197     public static final String
10198             KEY_CARRIER_ROAMING_NTN_EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_INT =
10199             "carrier_roaming_ntn_emergency_call_to_satellite_handover_type_int";
10200 
10201     /**
10202      * The carrier roaming non-terrestrial network hysteresis time in seconds.
10203      *
10204      * If the device supports P2P satellite messaging which is defined by
10205      * {@link CarrierConfigManager#KEY_CARRIER_SUPPORTED_SATELLITE_SERVICES_PER_PROVIDER_BUNDLE}
10206      * and the device is in {@link ServiceState#STATE_OUT_OF_SERVICE}, not connected to Wi-Fi,
10207      * then hysteresis timer defined by this key will start.
10208      * After the timer is expired, device is marked as eligible for satellite communication.
10209      *
10210      * The default value is 180 seconds.
10211      */
10212     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10213     public static final String KEY_CARRIER_SUPPORTED_SATELLITE_NOTIFICATION_HYSTERESIS_SEC_INT =
10214             "carrier_supported_satellite_notification_hysteresis_sec_int";
10215 
10216     /**
10217      * Satellite notification display restriction reset time in seconds.
10218      *
10219      * The device shows a notification when it connects to a satellite.  If the user interacts
10220      * with the notification, it won't be shown again immediately.  Instead, the notification
10221      * will only reappear after below key mentioned amount of time has passed.
10222      */
10223     @FlaggedApi(Flags.FLAG_SATELLITE_25Q4_APIS)
10224     public static final String KEY_SATELLITE_CONNECTED_NOTIFICATION_THROTTLE_MILLIS_INT =
10225             "satellite_connected_notification_throttle_millis_int";
10226 
10227     /**
10228      * An integer key holds the timeout duration in seconds used to determine whether to exit
10229      * carrier-roaming NB-IOT satellite mode.
10230      *
10231      * The timer is started when the device screen is turned off during a satellite session.
10232      * When the timer expires, the device exits Carrier Roaming NB IOT NTN.
10233      *
10234      * The default value is 30 seconds.
10235      */
10236     @FlaggedApi(Flags.FLAG_CARRIER_ROAMING_NB_IOT_NTN)
10237     public static final String KEY_SATELLITE_ROAMING_SCREEN_OFF_INACTIVITY_TIMEOUT_SEC_INT =
10238             "satellite_roaming_screen_off_inactivity_timeout_sec_int";
10239 
10240     /**
10241      * An integer key holds the timeout duration in seconds used to determine whether to exit P2P
10242      * SMS mode and start TN scanning.
10243      *
10244      * The timer is started when the device is not connected, user is not pointing to the
10245      * satellite and no data transfer is happening.
10246      * When the timer expires, the device will move to IDLE mode upon which TN scanning will start.
10247      *
10248      * The default value is 180 seconds.
10249      */
10250     @FlaggedApi(Flags.FLAG_CARRIER_ROAMING_NB_IOT_NTN)
10251     public static final String KEY_SATELLITE_ROAMING_P2P_SMS_INACTIVITY_TIMEOUT_SEC_INT =
10252             "satellite_roaming_p2p_sms_inactivity_timeout_sec_int";
10253 
10254     /**
10255      * An integer key holds the timeout duration in seconds used to determine whether to exit ESOS
10256      * mode and start TN scanning.
10257      *
10258      * The timer is started when the device is not connected, user is not pointing to the
10259      * satellite and no data transfer is happening.
10260      * When the timer expires, the device will move to IDLE mode upon which TN scanning will start.
10261      *
10262      * The default value is 600 seconds.
10263      */
10264     @FlaggedApi(Flags.FLAG_CARRIER_ROAMING_NB_IOT_NTN)
10265     public static final String KEY_SATELLITE_ROAMING_ESOS_INACTIVITY_TIMEOUT_SEC_INT =
10266             "satellite_roaming_esos_inactivity_timeout_sec_int";
10267 
10268     /**
10269      * A string array containing the list of messaging apps that support satellite.
10270      *
10271      * The default value contains only "com.google.android.apps.messaging"
10272      */
10273     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10274     public static final String KEY_SATELLITE_SUPPORTED_MSG_APPS_STRING_ARRAY =
10275             "satellite_supported_msg_apps_string_array";
10276 
10277     /**
10278      * Indicating whether DUN APN should be disabled when the device is roaming. In that case,
10279      * the default APN (i.e. internet) will be used for tethering.
10280      *
10281      * This config is only available when using Preset APN(not user edited) as Preferred APN.
10282      */
10283     @FlaggedApi(Flags.FLAG_SATELLITE_SYSTEM_APIS)
10284     public static final String KEY_DISABLE_DUN_APN_WHILE_ROAMING_WITH_PRESET_APN_BOOL =
10285             "disable_dun_apn_while_roaming_with_preset_apn_bool";
10286 
10287     /**
10288      * Where there is no preferred APN, specifies the carrier's default preferred APN.
10289      * Specifies the {@link android.provider.Telephony.Carriers.APN} of the default preferred apn.
10290      *
10291      * This config is only available with Preset APN(not user edited).
10292      *
10293      * @hide
10294      */
10295     public static final String KEY_DEFAULT_PREFERRED_APN_NAME_STRING =
10296             "default_preferred_apn_name_string";
10297 
10298     /**
10299      * Indicates if the carrier supports call composer.
10300      */
10301     public static final String KEY_SUPPORTS_CALL_COMPOSER_BOOL = "supports_call_composer_bool";
10302 
10303     /**
10304      * Indicates if the carrier supports a business call composer.
10305      */
10306     @FlaggedApi(com.android.server.telecom.flags.Flags.FLAG_BUSINESS_CALL_COMPOSER)
10307     public static final String KEY_SUPPORTS_BUSINESS_CALL_COMPOSER_BOOL =
10308             "supports_business_call_composer_bool";
10309 
10310     /**
10311      * Indicates the carrier server url that serves the call composer picture.
10312      */
10313     public static final String KEY_CALL_COMPOSER_PICTURE_SERVER_URL_STRING =
10314             "call_composer_picture_server_url_string";
10315 
10316     /**
10317      * Determines the default RTT mode.
10318      *
10319      * Upon first boot, when the user has not yet set a value for their preferred RTT mode,
10320      * the value of this config will be sent to the IMS stack. Valid values are the same as for
10321      * {@link Settings.Secure#RTT_CALLING_MODE}.
10322      *
10323      * @hide
10324      */
10325     public static final String KEY_DEFAULT_RTT_MODE_INT = "default_rtt_mode_int";
10326 
10327     /**
10328      * Indicates whether RTT is supported while roaming.
10329      */
10330     public static final String KEY_RTT_SUPPORTED_WHILE_ROAMING_BOOL =
10331             "rtt_supported_while_roaming_bool";
10332 
10333     /**
10334      * Indicates if auto-configuration server is used for the RCS config
10335      * Reference: GSMA RCC.14
10336      */
10337     public static final String KEY_USE_ACS_FOR_RCS_BOOL = "use_acs_for_rcs_bool";
10338 
10339     /**
10340      * Indicates temporarily unmetered mobile data is supported by the carrier.
10341      * @hide
10342      */
10343     public static final String KEY_NETWORK_TEMP_NOT_METERED_SUPPORTED_BOOL =
10344             "network_temp_not_metered_supported_bool";
10345 
10346     /**
10347      * Boolean indicating whether the SIM PIN can be stored and verified
10348      * seamlessly after an unattended reboot.
10349      *
10350      * The device configuration value {@code config_allow_pin_storage_for_unattended_reboot}
10351      * ultimately controls whether this carrier configuration option is used. Where
10352      * {@code config_allow_pin_storage_for_unattended_reboot} is false, the value of this
10353      * carrier configuration is ignored.
10354      *
10355      * @hide
10356      */
10357     public static final String KEY_STORE_SIM_PIN_FOR_UNATTENDED_REBOOT_BOOL =
10358             "store_sim_pin_for_unattended_reboot_bool";
10359 
10360     /**
10361      * Allow whether the user can use the "Allow 2G" toggle in Settings.
10362      *
10363      * If {@code true} then the toggle is disabled (i.e. grayed out).
10364      *
10365      * Used to trade privacy/security against potentially reduced carrier coverage for some
10366      * carriers.
10367      *
10368      * @removed This config option is no longer supported as it was hiding a security feature
10369      * from users. Setting this option will not change the behavior of the Settings menu starting
10370      * in Android V.
10371      */
10372     @Deprecated
10373     public static final String KEY_HIDE_ENABLE_2G = "hide_enable_2g_bool";
10374 
10375     /**
10376      * Indicates the allowed APN types that can be used for LTE initial attach. The order of APN
10377      * types in the configuration is the order of APN types that will be used for initial attach.
10378      * Empty list indicates that no APN types are allowed for initial attach.
10379      *
10380      * @hide
10381      */
10382     public static final String KEY_ALLOWED_INITIAL_ATTACH_APN_TYPES_STRING_ARRAY =
10383             "allowed_initial_attach_apn_types_string_array";
10384 
10385     /**
10386      * Indicates whether or not the carrier will provision merged carrier Wi-Fi offload networks.
10387      * Such networks are considered part of the core carrier network.
10388      *
10389      * This configuration will be use to gate whether such configurations are allowed to the carrier
10390      * and correspondingly enable UI elements which are required for such configurations.
10391      */
10392     public static final String KEY_CARRIER_PROVISIONS_WIFI_MERGED_NETWORKS_BOOL =
10393             "carrier_provisions_wifi_merged_networks_bool";
10394 
10395     /**
10396      * Determines whether or not to use (IP) data connectivity as a supplemental condition to
10397      * control the visibility of the no-calling indicator for this carrier in the System UI. Setting
10398      * the configuration to true may make sense for carriers that provide OTT calling.
10399      *
10400      * Config = true: show no-calling indication only if telephony does not have voice registration
10401      *                and if no (IP) data connectivity is available.
10402      * Config = false: show no-calling indication only if telephony does not have voice
10403      *                 registration.
10404      */
10405     public static final String KEY_USE_IP_FOR_CALLING_INDICATOR_BOOL =
10406             "use_ip_for_calling_indicator_bool";
10407 
10408     /**
10409      * Determine whether or not to display a call strength indicator for this carrier in the System
10410      * UI. Disabling the indication may be reasonable if the carrier's calling is not integrated
10411      * into the Android telephony stack (e.g. it is OTT).
10412      *
10413      * true: Use telephony APIs to detect the current networking medium of calling and display a
10414      *       UI indication based on the current strength (e.g. signal level) of that medium.
10415      * false: Do not display the call strength indicator.
10416      */
10417     public static final String KEY_DISPLAY_CALL_STRENGTH_INDICATOR_BOOL =
10418             "display_call_strength_indicator_bool";
10419 
10420     /**
10421      * Determine whether or not to display no data notification when data setup is permanently
10422      * failed.
10423      *
10424      * @hide
10425      */
10426     public static final String KEY_DISPLAY_NO_DATA_NOTIFICATION_ON_PERMANENT_FAILURE_BOOL =
10427             "display_no_data_notification_on_permanent_failure_bool";
10428 
10429     /**
10430      * Boolean indicating if the VoNR setting is visible in the Call Settings menu.
10431      * If this flag is set and VoNR is enabled for this carrier (see {@link #KEY_VONR_ENABLED_BOOL})
10432      * the VoNR setting menu will be visible. If {@link #KEY_VONR_ENABLED_BOOL} or
10433      * this setting is false, the menu will be gone.
10434      *
10435      * Enabled by default.
10436      *
10437      */
10438     public static final String KEY_VONR_SETTING_VISIBILITY_BOOL = "vonr_setting_visibility_bool";
10439 
10440     /**
10441      * Flag specifying whether VoNR should be enabled for carrier.
10442      * If true, VoNr will be enabled. If false, hard disabled.
10443      *
10444      * Disabled by default.
10445      *
10446      */
10447     public static final String KEY_VONR_ENABLED_BOOL = "vonr_enabled_bool";
10448 
10449     /**
10450      * Boolean indicating the default VoNR user preference setting.
10451      * If true, the VoNR setting will be enabled. If false, it will be disabled initially.
10452      *
10453      * Enabled by default.
10454      *
10455      */
10456     public static final String KEY_VONR_ON_BY_DEFAULT_BOOL = "vonr_on_by_default_bool";
10457 
10458     /**
10459      * Determine whether unthrottle data retry when tracking area code (TAC/LAC) from cell changes
10460      *
10461      * @hide
10462      */
10463     public static final String KEY_UNTHROTTLE_DATA_RETRY_WHEN_TAC_CHANGES_BOOL =
10464             "unthrottle_data_retry_when_tac_changes_bool";
10465 
10466     /**
10467      * A list of premium capabilities the carrier supports. Applications can prompt users to
10468      * purchase these premium capabilities from their carrier for a performance boost.
10469      * Valid values are any of {@link TelephonyManager}'s {@code PREMIUM_CAPABILITY_*} constants.
10470      *
10471      * This is empty by default, indicating that no premium capabilities are supported.
10472      *
10473      * @see TelephonyManager#isPremiumCapabilityAvailableForPurchase(int)
10474      * @see TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)
10475      */
10476     public static final String KEY_SUPPORTED_PREMIUM_CAPABILITIES_INT_ARRAY =
10477             "supported_premium_capabilities_int_array";
10478 
10479     /**
10480      * The amount of time in milliseconds the notification for a performance boost via
10481      * premium capabilities will be visible to the user after
10482      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}
10483      * requests user action to purchase the boost from the carrier. Once the timeout expires,
10484      * the performance boost notification will be automatically dismissed and the request will fail
10485      * with {@link TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_TIMEOUT}.
10486      *
10487      * The default value is 30 minutes.
10488      */
10489     public static final String KEY_PREMIUM_CAPABILITY_NOTIFICATION_DISPLAY_TIMEOUT_MILLIS_LONG =
10490             "premium_capability_notification_display_timeout_millis_long";
10491 
10492     /**
10493      * The amount of time in milliseconds that the notification for a performance boost via
10494      * premium capabilities should be blocked when
10495      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}
10496      * returns a failure due to user action or timeout.
10497      * The maximum number of performance boost notifications to show the user are defined in
10498      * {@link #KEY_PREMIUM_CAPABILITY_MAXIMUM_DAILY_NOTIFICATION_COUNT_INT} and
10499      * {@link #KEY_PREMIUM_CAPABILITY_MAXIMUM_MONTHLY_NOTIFICATION_COUNT_INT}.
10500      *
10501      * The default value is 30 minutes.
10502      *
10503      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_USER_CANCELED
10504      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_TIMEOUT
10505      */
10506     public static final String
10507             KEY_PREMIUM_CAPABILITY_NOTIFICATION_BACKOFF_HYSTERESIS_TIME_MILLIS_LONG =
10508             "premium_capability_notification_backoff_hysteresis_time_millis_long";
10509 
10510     /**
10511      * The maximum number of times in a day that we display the notification for a performance boost
10512      * via premium capabilities when
10513      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}
10514      * returns a failure due to user action or timeout.
10515      *
10516      * The default value is 2 times.
10517      *
10518      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_USER_CANCELED
10519      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_TIMEOUT
10520      */
10521     public static final String KEY_PREMIUM_CAPABILITY_MAXIMUM_DAILY_NOTIFICATION_COUNT_INT =
10522             "premium_capability_maximum_daily_notification_count_int";
10523 
10524     /**
10525      * The maximum number of times in a month that we display the notification for a performance
10526      * boost via premium capabilities when
10527      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}
10528      * returns a failure due to user action or timeout.
10529      *
10530      * The default value is 10 times.
10531      *
10532      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_USER_CANCELED
10533      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_TIMEOUT
10534      */
10535     public static final String KEY_PREMIUM_CAPABILITY_MAXIMUM_MONTHLY_NOTIFICATION_COUNT_INT =
10536             "premium_capability_maximum_monthly_notification_count_int";
10537 
10538     /**
10539      * The amount of time in milliseconds that the purchase request should be throttled when
10540      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}
10541      * returns a failure due to the carrier.
10542      *
10543      * The default value is 30 minutes.
10544      *
10545      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_CARRIER_ERROR
10546      * @see TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_ENTITLEMENT_CHECK_FAILED
10547      */
10548     public static final String
10549             KEY_PREMIUM_CAPABILITY_PURCHASE_CONDITION_BACKOFF_HYSTERESIS_TIME_MILLIS_LONG =
10550             "premium_capability_purchase_condition_backoff_hysteresis_time_millis_long";
10551 
10552     /**
10553      * The amount of time in milliseconds within which the network must set up a slicing
10554      * configuration for the premium capability after
10555      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}
10556      * returns {@link TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_SUCCESS}.
10557      * During the setup time, calls to
10558      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)} will return
10559      * {@link TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_PENDING_NETWORK_SETUP}.
10560      * If the network fails to set up a slicing configuration for the premium capability within the
10561      * setup time, subsequent purchase requests will be allowed to go through again.
10562      *
10563      * The default value is 5 minutes.
10564      */
10565     public static final String KEY_PREMIUM_CAPABILITY_NETWORK_SETUP_TIME_MILLIS_LONG =
10566             "premium_capability_network_setup_time_millis_long";
10567 
10568     /**
10569      * The URL to redirect to when the user clicks on the notification for a performance boost via
10570      * premium capabilities after applications call
10571      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}.
10572      * If the URL is empty or invalid, the purchase request will return
10573      * {@link TelephonyManager#PURCHASE_PREMIUM_CAPABILITY_RESULT_FEATURE_NOT_SUPPORTED}.
10574      *
10575      * This is empty by default.
10576      */
10577     public static final String KEY_PREMIUM_CAPABILITY_PURCHASE_URL_STRING =
10578             "premium_capability_purchase_url_string";
10579 
10580     /**
10581      * Whether to allow premium capabilities to be purchased when the device is connected to LTE.
10582      * If this is {@code true}, applications can call
10583      * {@link TelephonyManager#purchasePremiumCapability(int, Executor, Consumer)}
10584      * when connected to {@link TelephonyManager#NETWORK_TYPE_LTE} to purchase and use
10585      * premium capabilities.
10586      * If this is {@code false}, applications can only purchase and use premium capabilities when
10587      * connected to {@link TelephonyManager#NETWORK_TYPE_NR}.
10588      *
10589      * This is {@code false} by default.
10590      */
10591     public static final String KEY_PREMIUM_CAPABILITY_SUPPORTED_ON_LTE_BOOL =
10592             "premium_capability_supported_on_lte_bool";
10593 
10594     /**
10595      * IWLAN handover rules that determine whether handover is allowed or disallowed between
10596      * cellular and IWLAN.
10597      *
10598      * Rule syntax: "source=[GERAN|UTRAN|EUTRAN|NGRAN|IWLAN|UNKNOWN], target=[GERAN|UTRAN|EUTRAN
10599      * |NGRAN|IWLAN], type=[allowed|disallowed], roaming=[true|false], capabilities=[INTERNET|MMS
10600      * |FOTA|IMS|CBS|SUPL|EIMS|XCAP|DUN]"
10601      *
10602      * Note that UNKNOWN can be only specified in the source access network and can be only used
10603      * in the disallowed rule.
10604      *
10605      * The handover rules will be matched in the order. Here are some sample rules.
10606      * <string-array name="iwlan_handover_rules" num="5">
10607      *     <!-- Handover from IWLAN to 2G/3G is not allowed -->
10608      *     <item value="source=IWLAN, target=GERAN|UTRAN, type=disallowed"/>
10609      *     <!-- Handover from 2G/3G to IWLAN is not allowed -->
10610      *     <item value="source=GERAN|UTRAN, target:IWLAN, type=disallowed"/>
10611      *     <!-- Handover from IWLAN to 3G/4G/5G is not allowed if the device is roaming. -->
10612      *     <item value="source=IWLAN, target=UTRAN|EUTRAN|NGRAN, roaming=true, type=disallowed"/>
10613      *     <!-- Handover from 4G to IWLAN is not allowed if the device has capability in either IMS
10614      *     or EIMS-->
10615      *     <item value="source=EUTRAN, target=IWLAN, type=disallowed, capabilities=IMS|EIMS"/>
10616      *     <!-- Handover from IWLAN to 5G is not allowed if the device is incall. -->
10617      *     <item value="source=IWLAN, target=NGRAN, incall=true, type=disallowed"/>
10618      *     <!-- Handover is always allowed in any condition. -->
10619      *     <item value="source=GERAN|UTRAN|EUTRAN|NGRAN|IWLAN|UNKNOWN,
10620      *         target=GERAN|UTRAN|EUTRAN|NGRAN|IWLAN, type=allowed"/>
10621      * </string-array>
10622      *
10623      * When handover is not allowed, frameworks will tear down the data network on source transport,
10624      * and then setup a new one on the target transport when Qualified Network Service changes the
10625      * preferred access networks for particular APN types.
10626      *
10627      * @hide
10628      */
10629     public static final String KEY_IWLAN_HANDOVER_POLICY_STRING_ARRAY =
10630             "iwlan_handover_policy_string_array";
10631 
10632     /**
10633      * Score table for {@link TelephonyManager#MOBILE_DATA_POLICY_AUTO_DATA_SWITCH}. The score is
10634      * used in conjunction with a tolerance value defined in resource config
10635      * {@code auto_data_switch_score_tolerance}, greater than which device will switch to the sub
10636      * with higher score.
10637      * Possible keys are network type name string(also see {@link #KEY_BANDWIDTH_STRING_ARRAY}).
10638      * Value should be "score_level_0, score_level_1, score_level_2, score_level_3,score_level_4".
10639      * Each network type must have 5 scores correspond to {@link CellSignalStrength}, where score is
10640      * a non-negative integer. A score of 0 is treated the same as data out of service.
10641      *
10642      * For NR (5G), the following network names should be used:
10643      * - NR_NSA: NR NSA, sub-6 frequencies
10644      * - NR_NSA_MMWAVE: NR NSA, mmwave frequencies
10645      * - NR_SA: NR SA, sub-6 frequencies
10646      * - NR_SA_MMWAVE: NR SA, mmwave frequencies
10647      *
10648      * @hide
10649      */
10650     public static final String KEY_AUTO_DATA_SWITCH_RAT_SIGNAL_SCORE_BUNDLE =
10651             "auto_data_switch_rat_signal_score_string_bundle";
10652 
10653     // TODO(b/316183370): replace @code with @link in javadoc after feature is released
10654     /**
10655      * An array of cellular services supported by a subscription.
10656      *
10657      * <p>Permissible values include:
10658      * <ul>
10659      *   <li>{@code SubscriptionManager#SERVICE_CAPABILITY_VOICE} for voice services</li>
10660      *   <li>{@code SubscriptionManager#SERVICE_CAPABILITY_SMS} for SMS services</li>
10661      *   <li>{@code SubscriptionManager#SERVICE_CAPABILITY_DATA} for data services</li>
10662      * </ul>
10663      *
10664      * <p>Carrier-specific factors may influence how these services are supported. Therefore,
10665      * modifying this carrier configuration might not always enable the specified services. These
10666      * capability bitmasks should be considered as indicators of a carrier's preferred services
10667      * to enhance user experience, rather than as absolute platform guarantees.
10668      *
10669      * <p>Device-level service capabilities, defined by
10670      * {@code TelephonyManager#isDeviceVoiceCapable} and
10671      * {@code TelephonyManager#isDeviceSmsCapable}, take precedence over these subscription-level
10672      * settings. For instance, a device where {@code TelephonyManager#isDeviceVoiceCapable} returns
10673      * false may not be able to make voice calls, even if subscribed to a service marked as
10674      * voice-capable.
10675      *
10676      * <p>To determine a subscription's cellular service capabilities, use
10677      * {@code SubscriptionInfo#getServiceCapabilities()}. To track changes in services, register
10678      * a {@link SubscriptionManager.OnSubscriptionsChangedListener} and invoke the
10679      * same method in its callback.
10680      *
10681      * <p>Emergency service availability may not depend on the cellular service capabilities.
10682      * For example, emergency calls might be possible on a subscription even if it lacks
10683      * {@code SubscriptionManager#SERVICE_CAPABILITY_VOICE}.
10684      *
10685      * <p>If unset, the default value is “[1, 2, 3]” (supports all cellular services).
10686      *
10687      * @see TelephonyManager#isDeviceVoiceCapable
10688      * @see TelephonyManager#isDeviceSmsCapable
10689      * @see SubscriptionInfo#getServiceCapabilities()
10690      * @see SubscriptionManager.OnSubscriptionsChangedListener
10691      */
10692     public static final String KEY_CELLULAR_SERVICE_CAPABILITIES_INT_ARRAY =
10693             "cellular_service_capabilities_int_array";
10694    /**
10695      * Transition delay from BT to Cellular on Wear.
10696      * Specifies delay when transitioning away from BT.
10697      * This minimizes the duration of the netTransitionWakelock held by ConnectivityService
10698      * whenever the primary/default network disappears, while still allowing some amount of time
10699      * for BT to reconnect before we enable cell.
10700      *
10701      * If set as -1 then value from resources will be used
10702      *
10703      * @hide
10704      */
10705     public static final String KEY_WEAR_CONNECTIVITY_BT_TO_CELL_DELAY_MS_INT =
10706             "proxy_connectivity_delay_cell";
10707 
10708     /**
10709      * Transition delay from BT to Cellular on Wear.
10710      * If wifi connected it extends delay that has been started for BT to Cellular transition
10711      * to avoid Wifi thrashing turning Cell radio and causing higher battery drain.
10712      *
10713      * If set as -1 then value from resources will be used
10714      *
10715      * @hide
10716      */
10717     public static final String KEY_WEAR_CONNECTIVITY_EXTEND_BT_TO_CELL_DELAY_ON_WIFI_MS_INT =
10718             "wifi_connectivity_extend_cell_delay";
10719 
10720     /** The default value for every variable. */
10721     private static final PersistableBundle sDefaults;
10722 
10723     static {
10724         sDefaults = new PersistableBundle();
sDefaults.putString(KEY_CARRIER_CONFIG_VERSION_STRING, "")10725         sDefaults.putString(KEY_CARRIER_CONFIG_VERSION_STRING, "");
sDefaults.putBoolean(KEY_ALLOW_HOLD_IN_IMS_CALL_BOOL, true)10726         sDefaults.putBoolean(KEY_ALLOW_HOLD_IN_IMS_CALL_BOOL, true);
sDefaults.putBoolean(KEY_CARRIER_ALLOW_DEFLECT_IMS_CALL_BOOL, false)10727         sDefaults.putBoolean(KEY_CARRIER_ALLOW_DEFLECT_IMS_CALL_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_ALLOW_TRANSFER_IMS_CALL_BOOL, false)10728         sDefaults.putBoolean(KEY_CARRIER_ALLOW_TRANSFER_IMS_CALL_BOOL, false);
sDefaults.putBoolean(KEY_ALWAYS_PLAY_REMOTE_HOLD_TONE_BOOL, false)10729         sDefaults.putBoolean(KEY_ALWAYS_PLAY_REMOTE_HOLD_TONE_BOOL, false);
sDefaults.putBoolean(KEY_AUTO_RETRY_FAILED_WIFI_EMERGENCY_CALL, false)10730         sDefaults.putBoolean(KEY_AUTO_RETRY_FAILED_WIFI_EMERGENCY_CALL, false);
sDefaults.putBoolean(KEY_ADDITIONAL_CALL_SETTING_BOOL, true)10731         sDefaults.putBoolean(KEY_ADDITIONAL_CALL_SETTING_BOOL, true);
sDefaults.putBoolean(KEY_ALLOW_EMERGENCY_NUMBERS_IN_CALL_LOG_BOOL, false)10732         sDefaults.putBoolean(KEY_ALLOW_EMERGENCY_NUMBERS_IN_CALL_LOG_BOOL, false);
sDefaults.putStringArray(KEY_UNLOGGABLE_NUMBERS_STRING_ARRAY, null)10733         sDefaults.putStringArray(KEY_UNLOGGABLE_NUMBERS_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_ALLOW_LOCAL_DTMF_TONES_BOOL, true)10734         sDefaults.putBoolean(KEY_ALLOW_LOCAL_DTMF_TONES_BOOL, true);
sDefaults.putBoolean(KEY_PLAY_CALL_RECORDING_TONE_BOOL, false)10735         sDefaults.putBoolean(KEY_PLAY_CALL_RECORDING_TONE_BOOL, false);
sDefaults.putBoolean(KEY_APN_EXPAND_BOOL, true)10736         sDefaults.putBoolean(KEY_APN_EXPAND_BOOL, true);
sDefaults.putBoolean(KEY_AUTO_RETRY_ENABLED_BOOL, false)10737         sDefaults.putBoolean(KEY_AUTO_RETRY_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_SETTINGS_ENABLE_BOOL, false)10738         sDefaults.putBoolean(KEY_CARRIER_SETTINGS_ENABLE_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_VOLTE_AVAILABLE_BOOL, false)10739         sDefaults.putBoolean(KEY_CARRIER_VOLTE_AVAILABLE_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_VT_AVAILABLE_BOOL, false)10740         sDefaults.putBoolean(KEY_CARRIER_VT_AVAILABLE_BOOL, false);
sDefaults.putInt(KEY_CARRIER_USSD_METHOD_INT, USSD_OVER_CS_PREFERRED)10741         sDefaults.putInt(KEY_CARRIER_USSD_METHOD_INT, USSD_OVER_CS_PREFERRED);
sDefaults.putBoolean(KEY_VOLTE_5G_LIMITED_ALERT_DIALOG_BOOL, false)10742         sDefaults.putBoolean(KEY_VOLTE_5G_LIMITED_ALERT_DIALOG_BOOL, false);
sDefaults.putBoolean(KEY_NOTIFY_HANDOVER_VIDEO_FROM_WIFI_TO_LTE_BOOL, false)10743         sDefaults.putBoolean(KEY_NOTIFY_HANDOVER_VIDEO_FROM_WIFI_TO_LTE_BOOL, false);
sDefaults.putBoolean(KEY_ALLOW_MERGING_RTT_CALLS_BOOL, false)10744         sDefaults.putBoolean(KEY_ALLOW_MERGING_RTT_CALLS_BOOL, false);
sDefaults.putBoolean(KEY_NOTIFY_HANDOVER_VIDEO_FROM_LTE_TO_WIFI_BOOL, false)10745         sDefaults.putBoolean(KEY_NOTIFY_HANDOVER_VIDEO_FROM_LTE_TO_WIFI_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_DOWNGRADE_VT_TO_AUDIO_BOOL, true)10746         sDefaults.putBoolean(KEY_SUPPORT_DOWNGRADE_VT_TO_AUDIO_BOOL, true);
sDefaults.putString(KEY_DEFAULT_VM_NUMBER_STRING, "")10747         sDefaults.putString(KEY_DEFAULT_VM_NUMBER_STRING, "");
sDefaults.putString(KEY_DEFAULT_VM_NUMBER_ROAMING_STRING, "")10748         sDefaults.putString(KEY_DEFAULT_VM_NUMBER_ROAMING_STRING, "");
sDefaults.putString(KEY_DEFAULT_VM_NUMBER_ROAMING_AND_IMS_UNREGISTERED_STRING, "")10749         sDefaults.putString(KEY_DEFAULT_VM_NUMBER_ROAMING_AND_IMS_UNREGISTERED_STRING, "");
sDefaults.putBoolean(KEY_CONFIG_TELEPHONY_USE_OWN_NUMBER_FOR_VOICEMAIL_BOOL, false)10750         sDefaults.putBoolean(KEY_CONFIG_TELEPHONY_USE_OWN_NUMBER_FOR_VOICEMAIL_BOOL, false);
sDefaults.putBoolean(KEY_IGNORE_DATA_ENABLED_CHANGED_FOR_VIDEO_CALLS, true)10751         sDefaults.putBoolean(KEY_IGNORE_DATA_ENABLED_CHANGED_FOR_VIDEO_CALLS, true);
sDefaults.putBoolean(KEY_VILTE_DATA_IS_METERED_BOOL, true)10752         sDefaults.putBoolean(KEY_VILTE_DATA_IS_METERED_BOOL, true);
sDefaults.putBoolean(KEY_CARRIER_WFC_IMS_AVAILABLE_BOOL, false)10753         sDefaults.putBoolean(KEY_CARRIER_WFC_IMS_AVAILABLE_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_CROSS_SIM_IMS_AVAILABLE_BOOL, false)10754         sDefaults.putBoolean(KEY_CARRIER_CROSS_SIM_IMS_AVAILABLE_BOOL, false);
sDefaults.putBoolean(KEY_ENABLE_CROSS_SIM_CALLING_ON_OPPORTUNISTIC_DATA_BOOL, false)10755         sDefaults.putBoolean(KEY_ENABLE_CROSS_SIM_CALLING_ON_OPPORTUNISTIC_DATA_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_WFC_SUPPORTS_WIFI_ONLY_BOOL, false)10756         sDefaults.putBoolean(KEY_CARRIER_WFC_SUPPORTS_WIFI_ONLY_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_DEFAULT_WFC_IMS_ENABLED_BOOL, false)10757         sDefaults.putBoolean(KEY_CARRIER_DEFAULT_WFC_IMS_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_DEFAULT_WFC_IMS_ROAMING_ENABLED_BOOL, false)10758         sDefaults.putBoolean(KEY_CARRIER_DEFAULT_WFC_IMS_ROAMING_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_PROMOTE_WFC_ON_CALL_FAIL_BOOL, false)10759         sDefaults.putBoolean(KEY_CARRIER_PROMOTE_WFC_ON_CALL_FAIL_BOOL, false);
sDefaults.putInt(KEY_CARRIER_DEFAULT_WFC_IMS_MODE_INT, 2)10760         sDefaults.putInt(KEY_CARRIER_DEFAULT_WFC_IMS_MODE_INT, 2);
sDefaults.putInt(KEY_CARRIER_DEFAULT_WFC_IMS_ROAMING_MODE_INT, 2)10761         sDefaults.putInt(KEY_CARRIER_DEFAULT_WFC_IMS_ROAMING_MODE_INT, 2);
sDefaults.putBoolean(KEY_CARRIER_FORCE_DISABLE_ETWS_CMAS_TEST_BOOL, false)10762         sDefaults.putBoolean(KEY_CARRIER_FORCE_DISABLE_ETWS_CMAS_TEST_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_RCS_PROVISIONING_REQUIRED_BOOL, true)10763         sDefaults.putBoolean(KEY_CARRIER_RCS_PROVISIONING_REQUIRED_BOOL, true);
sDefaults.putBoolean(KEY_CARRIER_VOLTE_PROVISIONING_REQUIRED_BOOL, false)10764         sDefaults.putBoolean(KEY_CARRIER_VOLTE_PROVISIONING_REQUIRED_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_UT_PROVISIONING_REQUIRED_BOOL, false)10765         sDefaults.putBoolean(KEY_CARRIER_UT_PROVISIONING_REQUIRED_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_SS_OVER_UT_BOOL, false)10766         sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_SS_OVER_UT_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_VOLTE_OVERRIDE_WFC_PROVISIONING_BOOL, false)10767         sDefaults.putBoolean(KEY_CARRIER_VOLTE_OVERRIDE_WFC_PROVISIONING_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL, true)10768         sDefaults.putBoolean(KEY_CARRIER_VOLTE_TTY_SUPPORTED_BOOL, true);
sDefaults.putBoolean(KEY_CARRIER_VOWIFI_TTY_SUPPORTED_BOOL, true)10769         sDefaults.putBoolean(KEY_CARRIER_VOWIFI_TTY_SUPPORTED_BOOL, true);
sDefaults.putBoolean(KEY_CARRIER_ALLOW_TURNOFF_IMS_BOOL, true)10770         sDefaults.putBoolean(KEY_CARRIER_ALLOW_TURNOFF_IMS_BOOL, true);
sDefaults.putBoolean(KEY_CARRIER_IMS_GBA_REQUIRED_BOOL, false)10771         sDefaults.putBoolean(KEY_CARRIER_IMS_GBA_REQUIRED_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL, false)10772         sDefaults.putBoolean(KEY_CARRIER_INSTANT_LETTERING_AVAILABLE_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_USE_IMS_FIRST_FOR_EMERGENCY_BOOL, true)10773         sDefaults.putBoolean(KEY_CARRIER_USE_IMS_FIRST_FOR_EMERGENCY_BOOL, true);
sDefaults.putBoolean(KEY_PREFER_IN_SERVICE_SIM_FOR_NORMAL_ROUTED_EMERGENCY_CALLS_BOOL, false)10774         sDefaults.putBoolean(KEY_PREFER_IN_SERVICE_SIM_FOR_NORMAL_ROUTED_EMERGENCY_CALLS_BOOL,
10775                 false);
sDefaults.putBoolean(KEY_USE_ONLY_DIALED_SIM_ECC_LIST_BOOL, false)10776         sDefaults.putBoolean(KEY_USE_ONLY_DIALED_SIM_ECC_LIST_BOOL, false);
sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING, "")10777         sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING, "")10778         sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WLAN_CLASS_OVERRIDE_STRING, "")10779         sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WLAN_CLASS_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WWAN_CLASS_OVERRIDE_STRING, "")10780         sDefaults.putString(KEY_CARRIER_NETWORK_SERVICE_WWAN_CLASS_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_QUALIFIED_NETWORKS_SERVICE_PACKAGE_OVERRIDE_STRING, "")10781         sDefaults.putString(KEY_CARRIER_QUALIFIED_NETWORKS_SERVICE_PACKAGE_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_QUALIFIED_NETWORKS_SERVICE_CLASS_OVERRIDE_STRING, "")10782         sDefaults.putString(KEY_CARRIER_QUALIFIED_NETWORKS_SERVICE_CLASS_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING, "")10783         sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WWAN_PACKAGE_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING, "")10784         sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WLAN_PACKAGE_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WWAN_CLASS_OVERRIDE_STRING, "")10785         sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WWAN_CLASS_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WLAN_CLASS_OVERRIDE_STRING, "")10786         sDefaults.putString(KEY_CARRIER_DATA_SERVICE_WLAN_CLASS_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CONFIG_PLANS_PACKAGE_OVERRIDE_STRING, "")10787         sDefaults.putString(KEY_CONFIG_PLANS_PACKAGE_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_INVALID_CHARS_STRING, "")10788         sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_INVALID_CHARS_STRING, "");
sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_ESCAPED_CHARS_STRING, "")10789         sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_ESCAPED_CHARS_STRING, "");
sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_ENCODING_STRING, "")10790         sDefaults.putString(KEY_CARRIER_INSTANT_LETTERING_ENCODING_STRING, "");
sDefaults.putInt(KEY_CARRIER_INSTANT_LETTERING_LENGTH_LIMIT_INT, 64)10791         sDefaults.putInt(KEY_CARRIER_INSTANT_LETTERING_LENGTH_LIMIT_INT, 64);
sDefaults.putBoolean(KEY_DISABLE_CDMA_ACTIVATION_CODE_BOOL, false)10792         sDefaults.putBoolean(KEY_DISABLE_CDMA_ACTIVATION_CODE_BOOL, false);
sDefaults.putBoolean(KEY_DTMF_TYPE_ENABLED_BOOL, false)10793         sDefaults.putBoolean(KEY_DTMF_TYPE_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_ENABLE_DIALER_KEY_VIBRATION_BOOL, true)10794         sDefaults.putBoolean(KEY_ENABLE_DIALER_KEY_VIBRATION_BOOL, true);
sDefaults.putBoolean(KEY_HAS_IN_CALL_NOISE_SUPPRESSION_BOOL, false)10795         sDefaults.putBoolean(KEY_HAS_IN_CALL_NOISE_SUPPRESSION_BOOL, false);
sDefaults.putBoolean(KEY_HIDE_CARRIER_NETWORK_SETTINGS_BOOL, false)10796         sDefaults.putBoolean(KEY_HIDE_CARRIER_NETWORK_SETTINGS_BOOL, false);
sDefaults.putBoolean(KEY_ONLY_AUTO_SELECT_IN_HOME_NETWORK_BOOL, false)10797         sDefaults.putBoolean(KEY_ONLY_AUTO_SELECT_IN_HOME_NETWORK_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_SINGLE_OPERATOR_ROW_IN_CHOOSE_NETWORK_SETTING_BOOL, true)10798         sDefaults.putBoolean(KEY_SHOW_SINGLE_OPERATOR_ROW_IN_CHOOSE_NETWORK_SETTING_BOOL, true);
sDefaults.putBoolean(KEY_SHOW_SPN_FOR_HOME_IN_CHOOSE_NETWORK_SETTING_BOOL, false)10799         sDefaults.putBoolean(KEY_SHOW_SPN_FOR_HOME_IN_CHOOSE_NETWORK_SETTING_BOOL, false);
sDefaults.putBoolean(KEY_SIMPLIFIED_NETWORK_SETTINGS_BOOL, false)10800         sDefaults.putBoolean(KEY_SIMPLIFIED_NETWORK_SETTINGS_BOOL, false);
sDefaults.putBoolean(KEY_HIDE_SIM_LOCK_SETTINGS_BOOL, false)10801         sDefaults.putBoolean(KEY_HIDE_SIM_LOCK_SETTINGS_BOOL, false);
10802 
sDefaults.putBoolean(KEY_CARRIER_VOLTE_PROVISIONED_BOOL, false)10803         sDefaults.putBoolean(KEY_CARRIER_VOLTE_PROVISIONED_BOOL, false);
sDefaults.putBoolean(KEY_CALL_BARRING_VISIBILITY_BOOL, false)10804         sDefaults.putBoolean(KEY_CALL_BARRING_VISIBILITY_BOOL, false);
sDefaults.putBoolean(KEY_CALL_BARRING_SUPPORTS_PASSWORD_CHANGE_BOOL, true)10805         sDefaults.putBoolean(KEY_CALL_BARRING_SUPPORTS_PASSWORD_CHANGE_BOOL, true);
sDefaults.putBoolean(KEY_CALL_BARRING_SUPPORTS_DEACTIVATE_ALL_BOOL, true)10806         sDefaults.putBoolean(KEY_CALL_BARRING_SUPPORTS_DEACTIVATE_ALL_BOOL, true);
sDefaults.putInt(KEY_CALL_BARRING_DEFAULT_SERVICE_CLASS_INT, SERVICE_CLASS_VOICE)10807         sDefaults.putInt(KEY_CALL_BARRING_DEFAULT_SERVICE_CLASS_INT, SERVICE_CLASS_VOICE);
sDefaults.putBoolean(KEY_SUPPORT_SS_OVER_CDMA_BOOL, false)10808         sDefaults.putBoolean(KEY_SUPPORT_SS_OVER_CDMA_BOOL, false);
sDefaults.putBoolean(KEY_CALL_FORWARDING_VISIBILITY_BOOL, true)10809         sDefaults.putBoolean(KEY_CALL_FORWARDING_VISIBILITY_BOOL, true);
sDefaults.putBoolean(KEY_CALL_FORWARDING_WHEN_UNREACHABLE_SUPPORTED_BOOL, true)10810         sDefaults.putBoolean(KEY_CALL_FORWARDING_WHEN_UNREACHABLE_SUPPORTED_BOOL, true);
sDefaults.putBoolean(KEY_CALL_FORWARDING_WHEN_UNANSWERED_SUPPORTED_BOOL, true)10811         sDefaults.putBoolean(KEY_CALL_FORWARDING_WHEN_UNANSWERED_SUPPORTED_BOOL, true);
sDefaults.putBoolean(KEY_CALL_FORWARDING_WHEN_BUSY_SUPPORTED_BOOL, true)10812         sDefaults.putBoolean(KEY_CALL_FORWARDING_WHEN_BUSY_SUPPORTED_BOOL, true);
sDefaults.putBoolean(KEY_ADDITIONAL_SETTINGS_CALLER_ID_VISIBILITY_BOOL, true)10813         sDefaults.putBoolean(KEY_ADDITIONAL_SETTINGS_CALLER_ID_VISIBILITY_BOOL, true);
sDefaults.putBoolean(KEY_ADDITIONAL_SETTINGS_CALL_WAITING_VISIBILITY_BOOL, true)10814         sDefaults.putBoolean(KEY_ADDITIONAL_SETTINGS_CALL_WAITING_VISIBILITY_BOOL, true);
sDefaults.putBoolean(KEY_DISABLE_SUPPLEMENTARY_SERVICES_IN_AIRPLANE_MODE_BOOL, false)10815         sDefaults.putBoolean(KEY_DISABLE_SUPPLEMENTARY_SERVICES_IN_AIRPLANE_MODE_BOOL, false);
sDefaults.putBoolean(KEY_IGNORE_SIM_NETWORK_LOCKED_EVENTS_BOOL, false)10816         sDefaults.putBoolean(KEY_IGNORE_SIM_NETWORK_LOCKED_EVENTS_BOOL, false);
sDefaults.putBoolean(KEY_MDN_IS_ADDITIONAL_VOICEMAIL_NUMBER_BOOL, false)10817         sDefaults.putBoolean(KEY_MDN_IS_ADDITIONAL_VOICEMAIL_NUMBER_BOOL, false);
sDefaults.putBoolean(KEY_OPERATOR_SELECTION_EXPAND_BOOL, true)10818         sDefaults.putBoolean(KEY_OPERATOR_SELECTION_EXPAND_BOOL, true);
sDefaults.putBoolean(KEY_PREFER_2G_BOOL, false)10819         sDefaults.putBoolean(KEY_PREFER_2G_BOOL, false);
sDefaults.putBoolean(KEY_PREFER_3G_VISIBILITY_BOOL, true)10820         sDefaults.putBoolean(KEY_PREFER_3G_VISIBILITY_BOOL, true);
sDefaults.putBoolean(KEY_4G_ONLY_BOOL, false)10821         sDefaults.putBoolean(KEY_4G_ONLY_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_APN_SETTING_CDMA_BOOL, false)10822         sDefaults.putBoolean(KEY_SHOW_APN_SETTING_CDMA_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_CDMA_CHOICES_BOOL, false)10823         sDefaults.putBoolean(KEY_SHOW_CDMA_CHOICES_BOOL, false);
sDefaults.putBoolean(KEY_SMS_REQUIRES_DESTINATION_NUMBER_CONVERSION_BOOL, false)10824         sDefaults.putBoolean(KEY_SMS_REQUIRES_DESTINATION_NUMBER_CONVERSION_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_EMERGENCY_SMS_OVER_IMS_BOOL, false)10825         sDefaults.putBoolean(KEY_SUPPORT_EMERGENCY_SMS_OVER_IMS_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_ONSCREEN_DIAL_BUTTON_BOOL, true)10826         sDefaults.putBoolean(KEY_SHOW_ONSCREEN_DIAL_BUTTON_BOOL, true);
sDefaults.putBoolean(KEY_SIM_NETWORK_UNLOCK_ALLOW_DISMISS_BOOL, true)10827         sDefaults.putBoolean(KEY_SIM_NETWORK_UNLOCK_ALLOW_DISMISS_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORT_PAUSE_IMS_VIDEO_CALLS_BOOL, false)10828         sDefaults.putBoolean(KEY_SUPPORT_PAUSE_IMS_VIDEO_CALLS_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_SWAP_AFTER_MERGE_BOOL, true)10829         sDefaults.putBoolean(KEY_SUPPORT_SWAP_AFTER_MERGE_BOOL, true);
sDefaults.putBoolean(KEY_USE_HFA_FOR_PROVISIONING_BOOL, false)10830         sDefaults.putBoolean(KEY_USE_HFA_FOR_PROVISIONING_BOOL, false);
sDefaults.putBoolean(KEY_EDITABLE_VOICEMAIL_NUMBER_SETTING_BOOL, true)10831         sDefaults.putBoolean(KEY_EDITABLE_VOICEMAIL_NUMBER_SETTING_BOOL, true);
sDefaults.putBoolean(KEY_EDITABLE_VOICEMAIL_NUMBER_BOOL, false)10832         sDefaults.putBoolean(KEY_EDITABLE_VOICEMAIL_NUMBER_BOOL, false);
sDefaults.putBoolean(KEY_HIDE_VOICEMAIL_NUMBER_SETTING_BOOL, false)10833         sDefaults.putBoolean(KEY_HIDE_VOICEMAIL_NUMBER_SETTING_BOOL, false);
sDefaults.putBoolean(KEY_USE_OTASP_FOR_PROVISIONING_BOOL, false)10834         sDefaults.putBoolean(KEY_USE_OTASP_FOR_PROVISIONING_BOOL, false);
sDefaults.putBoolean(KEY_VOICEMAIL_NOTIFICATION_PERSISTENT_BOOL, false)10835         sDefaults.putBoolean(KEY_VOICEMAIL_NOTIFICATION_PERSISTENT_BOOL, false);
sDefaults.putBoolean(KEY_VOICE_PRIVACY_DISABLE_UI_BOOL, false)10836         sDefaults.putBoolean(KEY_VOICE_PRIVACY_DISABLE_UI_BOOL, false);
sDefaults.putBoolean(KEY_WORLD_PHONE_BOOL, false)10837         sDefaults.putBoolean(KEY_WORLD_PHONE_BOOL, false);
sDefaults.putBoolean(KEY_REQUIRE_ENTITLEMENT_CHECKS_BOOL, true)10838         sDefaults.putBoolean(KEY_REQUIRE_ENTITLEMENT_CHECKS_BOOL, true);
sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_TETHERING_BOOL, true)10839         sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_TETHERING_BOOL, true);
sDefaults.putBoolean(KEY_RESTART_RADIO_ON_PDP_FAIL_REGULAR_DEACTIVATION_BOOL, false)10840         sDefaults.putBoolean(KEY_RESTART_RADIO_ON_PDP_FAIL_REGULAR_DEACTIVATION_BOOL, false);
sDefaults.putIntArray(KEY_RADIO_RESTART_FAILURE_CAUSES_INT_ARRAY, new int[0])10841         sDefaults.putIntArray(KEY_RADIO_RESTART_FAILURE_CAUSES_INT_ARRAY, new int[0]);
sDefaults.putInt(KEY_VOLTE_REPLACEMENT_RAT_INT, 0)10842         sDefaults.putInt(KEY_VOLTE_REPLACEMENT_RAT_INT, 0);
sDefaults.putString(KEY_DEFAULT_SIM_CALL_MANAGER_STRING, "")10843         sDefaults.putString(KEY_DEFAULT_SIM_CALL_MANAGER_STRING, "");
sDefaults.putString(KEY_VVM_DESTINATION_NUMBER_STRING, "")10844         sDefaults.putString(KEY_VVM_DESTINATION_NUMBER_STRING, "");
sDefaults.putInt(KEY_VVM_PORT_NUMBER_INT, 0)10845         sDefaults.putInt(KEY_VVM_PORT_NUMBER_INT, 0);
sDefaults.putString(KEY_VVM_TYPE_STRING, "")10846         sDefaults.putString(KEY_VVM_TYPE_STRING, "");
sDefaults.putBoolean(KEY_VVM_CELLULAR_DATA_REQUIRED_BOOL, false)10847         sDefaults.putBoolean(KEY_VVM_CELLULAR_DATA_REQUIRED_BOOL, false);
sDefaults.putString(KEY_VVM_CLIENT_PREFIX_STRING, "//VVM")10848         sDefaults.putString(KEY_VVM_CLIENT_PREFIX_STRING, "//VVM");
sDefaults.putBoolean(KEY_VVM_SSL_ENABLED_BOOL, false)10849         sDefaults.putBoolean(KEY_VVM_SSL_ENABLED_BOOL, false);
sDefaults.putStringArray(KEY_VVM_DISABLED_CAPABILITIES_STRING_ARRAY, null)10850         sDefaults.putStringArray(KEY_VVM_DISABLED_CAPABILITIES_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_VVM_LEGACY_MODE_ENABLED_BOOL, false)10851         sDefaults.putBoolean(KEY_VVM_LEGACY_MODE_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_VVM_PREFETCH_BOOL, true)10852         sDefaults.putBoolean(KEY_VVM_PREFETCH_BOOL, true);
sDefaults.putString(KEY_CARRIER_VVM_PACKAGE_NAME_STRING, "")10853         sDefaults.putString(KEY_CARRIER_VVM_PACKAGE_NAME_STRING, "");
sDefaults.putStringArray(KEY_CARRIER_VVM_PACKAGE_NAME_STRING_ARRAY, null)10854         sDefaults.putStringArray(KEY_CARRIER_VVM_PACKAGE_NAME_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_SHOW_ICCID_IN_SIM_STATUS_BOOL, false)10855         sDefaults.putBoolean(KEY_SHOW_ICCID_IN_SIM_STATUS_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_SIGNAL_STRENGTH_IN_SIM_STATUS_BOOL, true)10856         sDefaults.putBoolean(KEY_SHOW_SIGNAL_STRENGTH_IN_SIM_STATUS_BOOL, true);
sDefaults.putBoolean(KEY_INFLATE_SIGNAL_STRENGTH_BOOL, false)10857         sDefaults.putBoolean(KEY_INFLATE_SIGNAL_STRENGTH_BOOL, false);
sDefaults.putBoolean(KEY_CI_ACTION_ON_SYS_UPDATE_BOOL, false)10858         sDefaults.putBoolean(KEY_CI_ACTION_ON_SYS_UPDATE_BOOL, false);
sDefaults.putString(KEY_CI_ACTION_ON_SYS_UPDATE_INTENT_STRING, "")10859         sDefaults.putString(KEY_CI_ACTION_ON_SYS_UPDATE_INTENT_STRING, "");
sDefaults.putString(KEY_CI_ACTION_ON_SYS_UPDATE_EXTRA_STRING, "")10860         sDefaults.putString(KEY_CI_ACTION_ON_SYS_UPDATE_EXTRA_STRING, "");
sDefaults.putString(KEY_CI_ACTION_ON_SYS_UPDATE_EXTRA_VAL_STRING, "")10861         sDefaults.putString(KEY_CI_ACTION_ON_SYS_UPDATE_EXTRA_VAL_STRING, "");
sDefaults.putBoolean(KEY_CSP_ENABLED_BOOL, false)10862         sDefaults.putBoolean(KEY_CSP_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_ALLOW_ADDING_APNS_BOOL, true)10863         sDefaults.putBoolean(KEY_ALLOW_ADDING_APNS_BOOL, true);
sDefaults.putStringArray(KEY_READ_ONLY_APN_TYPES_STRING_ARRAY, new String[] {"dun"})10864         sDefaults.putStringArray(KEY_READ_ONLY_APN_TYPES_STRING_ARRAY, new String[] {"dun"});
sDefaults.putStringArray(KEY_READ_ONLY_APN_FIELDS_STRING_ARRAY, null)10865         sDefaults.putStringArray(KEY_READ_ONLY_APN_FIELDS_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_APN_SETTINGS_DEFAULT_APN_TYPES_STRING_ARRAY, null)10866         sDefaults.putStringArray(KEY_APN_SETTINGS_DEFAULT_APN_TYPES_STRING_ARRAY, null);
Apn.getDefaults()10867         sDefaults.putAll(Apn.getDefaults());
10868 
sDefaults.putBoolean(KEY_BROADCAST_EMERGENCY_CALL_STATE_CHANGES_BOOL, false)10869         sDefaults.putBoolean(KEY_BROADCAST_EMERGENCY_CALL_STATE_CHANGES_BOOL, false);
sDefaults.putBoolean(KEY_ALWAYS_SHOW_EMERGENCY_ALERT_ONOFF_BOOL, false)10870         sDefaults.putBoolean(KEY_ALWAYS_SHOW_EMERGENCY_ALERT_ONOFF_BOOL, false);
sDefaults.putInt(KEY_DEFAULT_MTU_INT, 1500)10871         sDefaults.putInt(KEY_DEFAULT_MTU_INT, 1500);
sDefaults.putLong(KEY_CARRIER_DATA_CALL_APN_RETRY_AFTER_DISCONNECT_LONG, 3000)10872         sDefaults.putLong(KEY_CARRIER_DATA_CALL_APN_RETRY_AFTER_DISCONNECT_LONG, 3000);
sDefaults.putString(KEY_CARRIER_ERI_FILE_NAME_STRING, "eri.xml")10873         sDefaults.putString(KEY_CARRIER_ERI_FILE_NAME_STRING, "eri.xml");
sDefaults.putInt(KEY_DURATION_BLOCKING_DISABLED_AFTER_EMERGENCY_INT, 7200)10874         sDefaults.putInt(KEY_DURATION_BLOCKING_DISABLED_AFTER_EMERGENCY_INT, 7200);
sDefaults.putStringArray(KEY_CARRIER_METERED_APN_TYPES_STRINGS, new String[]{"default", "mms", "dun", "supl", "enterprise"})10875         sDefaults.putStringArray(KEY_CARRIER_METERED_APN_TYPES_STRINGS,
10876                 new String[]{"default", "mms", "dun", "supl", "enterprise"});
sDefaults.putStringArray(KEY_CARRIER_METERED_ROAMING_APN_TYPES_STRINGS, new String[]{"default", "mms", "dun", "supl", "enterprise"})10877         sDefaults.putStringArray(KEY_CARRIER_METERED_ROAMING_APN_TYPES_STRINGS,
10878                 new String[]{"default", "mms", "dun", "supl", "enterprise"});
sDefaults.putIntArray(KEY_ONLY_SINGLE_DC_ALLOWED_INT_ARRAY, new int[] {TelephonyManager.NETWORK_TYPE_CDMA, TelephonyManager.NETWORK_TYPE_1xRTT, TelephonyManager.NETWORK_TYPE_EVDO_0, TelephonyManager.NETWORK_TYPE_EVDO_A, TelephonyManager.NETWORK_TYPE_EVDO_B})10879         sDefaults.putIntArray(KEY_ONLY_SINGLE_DC_ALLOWED_INT_ARRAY,
10880                 new int[] {TelephonyManager.NETWORK_TYPE_CDMA, TelephonyManager.NETWORK_TYPE_1xRTT,
10881                         TelephonyManager.NETWORK_TYPE_EVDO_0, TelephonyManager.NETWORK_TYPE_EVDO_A,
10882                         TelephonyManager.NETWORK_TYPE_EVDO_B});
sDefaults.putIntArray(KEY_CAPABILITIES_EXEMPT_FROM_SINGLE_DC_CHECK_INT_ARRAY, new int[] {NetworkCapabilities.NET_CAPABILITY_IMS})10883         sDefaults.putIntArray(KEY_CAPABILITIES_EXEMPT_FROM_SINGLE_DC_CHECK_INT_ARRAY,
10884                 new int[] {NetworkCapabilities.NET_CAPABILITY_IMS});
sDefaults.putStringArray(KEY_GSM_ROAMING_NETWORKS_STRING_ARRAY, null)10885         sDefaults.putStringArray(KEY_GSM_ROAMING_NETWORKS_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_GSM_NONROAMING_NETWORKS_STRING_ARRAY, null)10886         sDefaults.putStringArray(KEY_GSM_NONROAMING_NETWORKS_STRING_ARRAY, null);
sDefaults.putString(KEY_CONFIG_IMS_PACKAGE_OVERRIDE_STRING, null)10887         sDefaults.putString(KEY_CONFIG_IMS_PACKAGE_OVERRIDE_STRING, null);
sDefaults.putString(KEY_CONFIG_IMS_MMTEL_PACKAGE_OVERRIDE_STRING, null)10888         sDefaults.putString(KEY_CONFIG_IMS_MMTEL_PACKAGE_OVERRIDE_STRING, null);
sDefaults.putString(KEY_CONFIG_IMS_RCS_PACKAGE_OVERRIDE_STRING, null)10889         sDefaults.putString(KEY_CONFIG_IMS_RCS_PACKAGE_OVERRIDE_STRING, null);
sDefaults.putStringArray(KEY_CDMA_ROAMING_NETWORKS_STRING_ARRAY, null)10890         sDefaults.putStringArray(KEY_CDMA_ROAMING_NETWORKS_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_CDMA_NONROAMING_NETWORKS_STRING_ARRAY, null)10891         sDefaults.putStringArray(KEY_CDMA_NONROAMING_NETWORKS_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_DIAL_STRING_REPLACE_STRING_ARRAY, null)10892         sDefaults.putStringArray(KEY_DIAL_STRING_REPLACE_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_INTERNATIONAL_ROAMING_DIAL_STRING_REPLACE_STRING_ARRAY, null)10893         sDefaults.putStringArray(KEY_INTERNATIONAL_ROAMING_DIAL_STRING_REPLACE_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_FORCE_HOME_NETWORK_BOOL, false)10894         sDefaults.putBoolean(KEY_FORCE_HOME_NETWORK_BOOL, false);
sDefaults.putInt(KEY_GSM_DTMF_TONE_DELAY_INT, 0)10895         sDefaults.putInt(KEY_GSM_DTMF_TONE_DELAY_INT, 0);
sDefaults.putInt(KEY_IMS_DTMF_TONE_DELAY_INT, 0)10896         sDefaults.putInt(KEY_IMS_DTMF_TONE_DELAY_INT, 0);
sDefaults.putInt(KEY_CDMA_DTMF_TONE_DELAY_INT, 100)10897         sDefaults.putInt(KEY_CDMA_DTMF_TONE_DELAY_INT, 100);
sDefaults.putBoolean(KEY_CALL_FORWARDING_MAP_NON_NUMBER_TO_VOICEMAIL_BOOL, false)10898         sDefaults.putBoolean(KEY_CALL_FORWARDING_MAP_NON_NUMBER_TO_VOICEMAIL_BOOL, false);
sDefaults.putBoolean(KEY_IGNORE_RTT_MODE_SETTING_BOOL, true)10899         sDefaults.putBoolean(KEY_IGNORE_RTT_MODE_SETTING_BOOL, true);
sDefaults.putInt(KEY_CDMA_3WAYCALL_FLASH_DELAY_INT , 0)10900         sDefaults.putInt(KEY_CDMA_3WAYCALL_FLASH_DELAY_INT , 0);
sDefaults.putBoolean(KEY_SUPPORT_ADHOC_CONFERENCE_CALLS_BOOL, false)10901         sDefaults.putBoolean(KEY_SUPPORT_ADHOC_CONFERENCE_CALLS_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_ADD_CONFERENCE_PARTICIPANTS_BOOL, false)10902         sDefaults.putBoolean(KEY_SUPPORT_ADD_CONFERENCE_PARTICIPANTS_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_CONFERENCE_CALL_BOOL, true)10903         sDefaults.putBoolean(KEY_SUPPORT_CONFERENCE_CALL_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORT_IMS_CONFERENCE_CALL_BOOL, true)10904         sDefaults.putBoolean(KEY_SUPPORT_IMS_CONFERENCE_CALL_BOOL, true);
sDefaults.putBoolean(KEY_LOCAL_DISCONNECT_EMPTY_IMS_CONFERENCE_BOOL, false)10905         sDefaults.putBoolean(KEY_LOCAL_DISCONNECT_EMPTY_IMS_CONFERENCE_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_MANAGE_IMS_CONFERENCE_CALL_BOOL, true)10906         sDefaults.putBoolean(KEY_SUPPORT_MANAGE_IMS_CONFERENCE_CALL_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_BOOL, true)10907         sDefaults.putBoolean(KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_ON_PEER_BOOL, true)10908         sDefaults.putBoolean(KEY_SUPPORT_IMS_CONFERENCE_EVENT_PACKAGE_ON_PEER_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_RTP_BOOL, false)10909         sDefaults.putBoolean(KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_RTP_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORTS_SDP_NEGOTIATION_OF_D2D_RTP_HEADER_EXTENSIONS_BOOL, false)10910         sDefaults.putBoolean(KEY_SUPPORTS_SDP_NEGOTIATION_OF_D2D_RTP_HEADER_EXTENSIONS_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_DTMF_BOOL, false)10911         sDefaults.putBoolean(KEY_SUPPORTS_DEVICE_TO_DEVICE_COMMUNICATION_USING_DTMF_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_VIDEO_CONFERENCE_CALL_BOOL, false)10912         sDefaults.putBoolean(KEY_SUPPORT_VIDEO_CONFERENCE_CALL_BOOL, false);
sDefaults.putBoolean(KEY_IS_IMS_CONFERENCE_SIZE_ENFORCED_BOOL, false)10913         sDefaults.putBoolean(KEY_IS_IMS_CONFERENCE_SIZE_ENFORCED_BOOL, false);
sDefaults.putInt(KEY_IMS_CONFERENCE_SIZE_LIMIT_INT, 5)10914         sDefaults.putInt(KEY_IMS_CONFERENCE_SIZE_LIMIT_INT, 5);
sDefaults.putBoolean(KEY_DISPLAY_HD_AUDIO_PROPERTY_BOOL, true)10915         sDefaults.putBoolean(KEY_DISPLAY_HD_AUDIO_PROPERTY_BOOL, true);
sDefaults.putBoolean(KEY_EDITABLE_ENHANCED_4G_LTE_BOOL, true)10916         sDefaults.putBoolean(KEY_EDITABLE_ENHANCED_4G_LTE_BOOL, true);
sDefaults.putBoolean(KEY_HIDE_ENHANCED_4G_LTE_BOOL, false)10917         sDefaults.putBoolean(KEY_HIDE_ENHANCED_4G_LTE_BOOL, false);
sDefaults.putBoolean(KEY_ENHANCED_4G_LTE_ON_BY_DEFAULT_BOOL, true)10918         sDefaults.putBoolean(KEY_ENHANCED_4G_LTE_ON_BY_DEFAULT_BOOL, true);
sDefaults.putBoolean(KEY_HIDE_IMS_APN_BOOL, false)10919         sDefaults.putBoolean(KEY_HIDE_IMS_APN_BOOL, false);
sDefaults.putBoolean(KEY_HIDE_PREFERRED_NETWORK_TYPE_BOOL, false)10920         sDefaults.putBoolean(KEY_HIDE_PREFERRED_NETWORK_TYPE_BOOL, false);
sDefaults.putBoolean(KEY_ALLOW_EMERGENCY_VIDEO_CALLS_BOOL, false)10921         sDefaults.putBoolean(KEY_ALLOW_EMERGENCY_VIDEO_CALLS_BOOL, false);
sDefaults.putStringArray(KEY_ENABLE_APPS_STRING_ARRAY, null)10922         sDefaults.putStringArray(KEY_ENABLE_APPS_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_EDITABLE_WFC_MODE_BOOL, true)10923         sDefaults.putBoolean(KEY_EDITABLE_WFC_MODE_BOOL, true);
sDefaults.putStringArray(KEY_WFC_OPERATOR_ERROR_CODES_STRING_ARRAY, null)10924         sDefaults.putStringArray(KEY_WFC_OPERATOR_ERROR_CODES_STRING_ARRAY, null);
sDefaults.putInt(KEY_WFC_SPN_FORMAT_IDX_INT, 0)10925         sDefaults.putInt(KEY_WFC_SPN_FORMAT_IDX_INT, 0);
sDefaults.putInt(KEY_WFC_DATA_SPN_FORMAT_IDX_INT, 0)10926         sDefaults.putInt(KEY_WFC_DATA_SPN_FORMAT_IDX_INT, 0);
sDefaults.putInt(KEY_WFC_FLIGHT_MODE_SPN_FORMAT_IDX_INT, -1)10927         sDefaults.putInt(KEY_WFC_FLIGHT_MODE_SPN_FORMAT_IDX_INT, -1);
sDefaults.putBoolean(KEY_WFC_SPN_USE_ROOT_LOCALE, false)10928         sDefaults.putBoolean(KEY_WFC_SPN_USE_ROOT_LOCALE, false);
sDefaults.putString(KEY_WFC_EMERGENCY_ADDRESS_CARRIER_APP_STRING, "")10929         sDefaults.putString(KEY_WFC_EMERGENCY_ADDRESS_CARRIER_APP_STRING, "");
sDefaults.putBoolean(KEY_CONFIG_WIFI_DISABLE_IN_ECBM, false)10930         sDefaults.putBoolean(KEY_CONFIG_WIFI_DISABLE_IN_ECBM, false);
sDefaults.putBoolean(KEY_CARRIER_NAME_OVERRIDE_BOOL, false)10931         sDefaults.putBoolean(KEY_CARRIER_NAME_OVERRIDE_BOOL, false);
sDefaults.putString(KEY_CARRIER_NAME_STRING, "")10932         sDefaults.putString(KEY_CARRIER_NAME_STRING, "");
sDefaults.putBoolean(KEY_WFC_CARRIER_NAME_OVERRIDE_BY_PNN_BOOL, false)10933         sDefaults.putBoolean(KEY_WFC_CARRIER_NAME_OVERRIDE_BY_PNN_BOOL, false);
sDefaults.putInt(KEY_CROSS_SIM_SPN_FORMAT_INT, 1)10934         sDefaults.putInt(KEY_CROSS_SIM_SPN_FORMAT_INT, 1);
sDefaults.putInt(KEY_SPN_DISPLAY_CONDITION_OVERRIDE_INT, -1)10935         sDefaults.putInt(KEY_SPN_DISPLAY_CONDITION_OVERRIDE_INT, -1);
sDefaults.putStringArray(KEY_SPDI_OVERRIDE_STRING_ARRAY, null)10936         sDefaults.putStringArray(KEY_SPDI_OVERRIDE_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_PNN_OVERRIDE_STRING_ARRAY, null)10937         sDefaults.putStringArray(KEY_PNN_OVERRIDE_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_OPL_OVERRIDE_STRING_ARRAY, null)10938         sDefaults.putStringArray(KEY_OPL_OVERRIDE_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_EHPLMN_OVERRIDE_STRING_ARRAY, null)10939         sDefaults.putStringArray(KEY_EHPLMN_OVERRIDE_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_ALLOW_ERI_BOOL, false)10940         sDefaults.putBoolean(KEY_ALLOW_ERI_BOOL, false);
sDefaults.putBoolean(KEY_ENABLE_CARRIER_DISPLAY_NAME_RESOLVER_BOOL, false)10941         sDefaults.putBoolean(KEY_ENABLE_CARRIER_DISPLAY_NAME_RESOLVER_BOOL, false);
sDefaults.putString(KEY_SIM_COUNTRY_ISO_OVERRIDE_STRING, "")10942         sDefaults.putString(KEY_SIM_COUNTRY_ISO_OVERRIDE_STRING, "");
sDefaults.putString(KEY_CARRIER_CALL_SCREENING_APP_STRING, "")10943         sDefaults.putString(KEY_CARRIER_CALL_SCREENING_APP_STRING, "");
sDefaults.putString(KEY_CALL_REDIRECTION_SERVICE_COMPONENT_NAME_STRING, null)10944         sDefaults.putString(KEY_CALL_REDIRECTION_SERVICE_COMPONENT_NAME_STRING, null);
sDefaults.putBoolean(KEY_CDMA_HOME_REGISTERED_PLMN_NAME_OVERRIDE_BOOL, false)10945         sDefaults.putBoolean(KEY_CDMA_HOME_REGISTERED_PLMN_NAME_OVERRIDE_BOOL, false);
sDefaults.putString(KEY_CDMA_HOME_REGISTERED_PLMN_NAME_STRING, "")10946         sDefaults.putString(KEY_CDMA_HOME_REGISTERED_PLMN_NAME_STRING, "");
sDefaults.putBoolean(KEY_SUPPORT_DIRECT_FDN_DIALING_BOOL, false)10947         sDefaults.putBoolean(KEY_SUPPORT_DIRECT_FDN_DIALING_BOOL, false);
sDefaults.putInt(KEY_FDN_NUMBER_LENGTH_LIMIT_INT, 20)10948         sDefaults.putInt(KEY_FDN_NUMBER_LENGTH_LIMIT_INT, 20);
sDefaults.putBoolean(KEY_CARRIER_DEFAULT_DATA_ROAMING_ENABLED_BOOL, false)10949         sDefaults.putBoolean(KEY_CARRIER_DEFAULT_DATA_ROAMING_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_SKIP_CF_FAIL_TO_DISABLE_DIALOG_BOOL, false)10950         sDefaults.putBoolean(KEY_SKIP_CF_FAIL_TO_DISABLE_DIALOG_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_ENHANCED_CALL_BLOCKING_BOOL, true)10951         sDefaults.putBoolean(KEY_SUPPORT_ENHANCED_CALL_BLOCKING_BOOL, true);
10952 
10953         // MMS defaults
sDefaults.putBoolean(KEY_MMS_ALIAS_ENABLED_BOOL, false)10954         sDefaults.putBoolean(KEY_MMS_ALIAS_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_MMS_ALLOW_ATTACH_AUDIO_BOOL, true)10955         sDefaults.putBoolean(KEY_MMS_ALLOW_ATTACH_AUDIO_BOOL, true);
sDefaults.putBoolean(KEY_MMS_APPEND_TRANSACTION_ID_BOOL, false)10956         sDefaults.putBoolean(KEY_MMS_APPEND_TRANSACTION_ID_BOOL, false);
sDefaults.putBoolean(KEY_MMS_GROUP_MMS_ENABLED_BOOL, true)10957         sDefaults.putBoolean(KEY_MMS_GROUP_MMS_ENABLED_BOOL, true);
sDefaults.putBoolean(KEY_MMS_MMS_DELIVERY_REPORT_ENABLED_BOOL, false)10958         sDefaults.putBoolean(KEY_MMS_MMS_DELIVERY_REPORT_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_MMS_MMS_ENABLED_BOOL, true)10959         sDefaults.putBoolean(KEY_MMS_MMS_ENABLED_BOOL, true);
sDefaults.putBoolean(KEY_MMS_MMS_READ_REPORT_ENABLED_BOOL, false)10960         sDefaults.putBoolean(KEY_MMS_MMS_READ_REPORT_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_MMS_MULTIPART_SMS_ENABLED_BOOL, true)10961         sDefaults.putBoolean(KEY_MMS_MULTIPART_SMS_ENABLED_BOOL, true);
sDefaults.putBoolean(KEY_MMS_NOTIFY_WAP_MMSC_ENABLED_BOOL, false)10962         sDefaults.putBoolean(KEY_MMS_NOTIFY_WAP_MMSC_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_MMS_SEND_MULTIPART_SMS_AS_SEPARATE_MESSAGES_BOOL, false)10963         sDefaults.putBoolean(KEY_MMS_SEND_MULTIPART_SMS_AS_SEPARATE_MESSAGES_BOOL, false);
sDefaults.putBoolean(KEY_MMS_SHOW_CELL_BROADCAST_APP_LINKS_BOOL, true)10964         sDefaults.putBoolean(KEY_MMS_SHOW_CELL_BROADCAST_APP_LINKS_BOOL, true);
sDefaults.putBoolean(KEY_MMS_SMS_DELIVERY_REPORT_ENABLED_BOOL, true)10965         sDefaults.putBoolean(KEY_MMS_SMS_DELIVERY_REPORT_ENABLED_BOOL, true);
sDefaults.putBoolean(KEY_MMS_SUPPORT_HTTP_CHARSET_HEADER_BOOL, false)10966         sDefaults.putBoolean(KEY_MMS_SUPPORT_HTTP_CHARSET_HEADER_BOOL, false);
sDefaults.putBoolean(KEY_MMS_SUPPORT_MMS_CONTENT_DISPOSITION_BOOL, true)10967         sDefaults.putBoolean(KEY_MMS_SUPPORT_MMS_CONTENT_DISPOSITION_BOOL, true);
sDefaults.putBoolean(KEY_MMS_CLOSE_CONNECTION_BOOL, false)10968         sDefaults.putBoolean(KEY_MMS_CLOSE_CONNECTION_BOOL, false);
sDefaults.putInt(KEY_MMS_ALIAS_MAX_CHARS_INT, 48)10969         sDefaults.putInt(KEY_MMS_ALIAS_MAX_CHARS_INT, 48);
sDefaults.putInt(KEY_MMS_ALIAS_MIN_CHARS_INT, 2)10970         sDefaults.putInt(KEY_MMS_ALIAS_MIN_CHARS_INT, 2);
sDefaults.putInt(KEY_MMS_HTTP_SOCKET_TIMEOUT_INT, 60 * 1000)10971         sDefaults.putInt(KEY_MMS_HTTP_SOCKET_TIMEOUT_INT, 60 * 1000);
sDefaults.putInt(KEY_MMS_MAX_IMAGE_HEIGHT_INT, 480)10972         sDefaults.putInt(KEY_MMS_MAX_IMAGE_HEIGHT_INT, 480);
sDefaults.putInt(KEY_MMS_MAX_IMAGE_WIDTH_INT, 640)10973         sDefaults.putInt(KEY_MMS_MAX_IMAGE_WIDTH_INT, 640);
sDefaults.putInt(KEY_MMS_MAX_MESSAGE_SIZE_INT, 300 * 1024)10974         sDefaults.putInt(KEY_MMS_MAX_MESSAGE_SIZE_INT, 300 * 1024);
sDefaults.putInt(KEY_MMS_MESSAGE_TEXT_MAX_SIZE_INT, -1)10975         sDefaults.putInt(KEY_MMS_MESSAGE_TEXT_MAX_SIZE_INT, -1);
sDefaults.putInt(KEY_MMS_RECIPIENT_LIMIT_INT, Integer.MAX_VALUE)10976         sDefaults.putInt(KEY_MMS_RECIPIENT_LIMIT_INT, Integer.MAX_VALUE);
sDefaults.putInt(KEY_MMS_SMS_TO_MMS_TEXT_LENGTH_THRESHOLD_INT, -1)10977         sDefaults.putInt(KEY_MMS_SMS_TO_MMS_TEXT_LENGTH_THRESHOLD_INT, -1);
sDefaults.putInt(KEY_MMS_SMS_TO_MMS_TEXT_THRESHOLD_INT, -1)10978         sDefaults.putInt(KEY_MMS_SMS_TO_MMS_TEXT_THRESHOLD_INT, -1);
sDefaults.putInt(KEY_MMS_SUBJECT_MAX_LENGTH_INT, 40)10979         sDefaults.putInt(KEY_MMS_SUBJECT_MAX_LENGTH_INT, 40);
sDefaults.putInt(KEY_MMS_NETWORK_RELEASE_TIMEOUT_MILLIS_INT, 5 * 1000)10980         sDefaults.putInt(KEY_MMS_NETWORK_RELEASE_TIMEOUT_MILLIS_INT, 5 * 1000);
sDefaults.putInt(KEY_MMS_MAX_NTN_PAYLOAD_SIZE_BYTES_INT, -1)10981         sDefaults.putInt(KEY_MMS_MAX_NTN_PAYLOAD_SIZE_BYTES_INT, -1);
sDefaults.putString(KEY_MMS_EMAIL_GATEWAY_NUMBER_STRING, "")10982         sDefaults.putString(KEY_MMS_EMAIL_GATEWAY_NUMBER_STRING, "");
sDefaults.putString(KEY_MMS_HTTP_PARAMS_STRING, "")10983         sDefaults.putString(KEY_MMS_HTTP_PARAMS_STRING, "");
sDefaults.putString(KEY_MMS_NAI_SUFFIX_STRING, "")10984         sDefaults.putString(KEY_MMS_NAI_SUFFIX_STRING, "");
sDefaults.putString(KEY_MMS_UA_PROF_TAG_NAME_STRING, "x-wap-profile")10985         sDefaults.putString(KEY_MMS_UA_PROF_TAG_NAME_STRING, "x-wap-profile");
sDefaults.putString(KEY_MMS_UA_PROF_URL_STRING, "")10986         sDefaults.putString(KEY_MMS_UA_PROF_URL_STRING, "");
sDefaults.putString(KEY_MMS_USER_AGENT_STRING, "")10987         sDefaults.putString(KEY_MMS_USER_AGENT_STRING, "");
sDefaults.putBoolean(KEY_ALLOW_NON_EMERGENCY_CALLS_IN_ECM_BOOL, true)10988         sDefaults.putBoolean(KEY_ALLOW_NON_EMERGENCY_CALLS_IN_ECM_BOOL, true);
sDefaults.putInt(KEY_EMERGENCY_SMS_MODE_TIMER_MS_INT, 0)10989         sDefaults.putInt(KEY_EMERGENCY_SMS_MODE_TIMER_MS_INT, 0);
sDefaults.putBoolean(KEY_ALLOW_HOLD_CALL_DURING_EMERGENCY_BOOL, true)10990         sDefaults.putBoolean(KEY_ALLOW_HOLD_CALL_DURING_EMERGENCY_BOOL, true);
sDefaults.putBoolean(KEY_USE_RCS_PRESENCE_BOOL, false)10991         sDefaults.putBoolean(KEY_USE_RCS_PRESENCE_BOOL, false);
sDefaults.putBoolean(KEY_USE_RCS_SIP_OPTIONS_BOOL, false)10992         sDefaults.putBoolean(KEY_USE_RCS_SIP_OPTIONS_BOOL, false);
sDefaults.putBoolean(KEY_FORCE_IMEI_BOOL, false)10993         sDefaults.putBoolean(KEY_FORCE_IMEI_BOOL, false);
sDefaults.putInt( KEY_CDMA_ROAMING_MODE_INT, TelephonyManager.CDMA_ROAMING_MODE_RADIO_DEFAULT)10994         sDefaults.putInt(
10995                 KEY_CDMA_ROAMING_MODE_INT, TelephonyManager.CDMA_ROAMING_MODE_RADIO_DEFAULT);
sDefaults.putBoolean(KEY_SUPPORT_CDMA_1X_VOICE_CALLS_BOOL, true)10996         sDefaults.putBoolean(KEY_SUPPORT_CDMA_1X_VOICE_CALLS_BOOL, true);
sDefaults.putString(KEY_RCS_CONFIG_SERVER_URL_STRING, "")10997         sDefaults.putString(KEY_RCS_CONFIG_SERVER_URL_STRING, "");
10998 
10999         // Carrier Signalling Receivers
sDefaults.putString(KEY_CARRIER_SETUP_APP_STRING, "")11000         sDefaults.putString(KEY_CARRIER_SETUP_APP_STRING, "");
sDefaults.putStringArray(KEY_CARRIER_APP_WAKE_SIGNAL_CONFIG_STRING_ARRAY, new String[]{ "com.android.carrierdefaultapp/.CarrierDefaultBroadcastReceiver:" + "com.android.internal.telephony.CARRIER_SIGNAL_RESET" })11001         sDefaults.putStringArray(KEY_CARRIER_APP_WAKE_SIGNAL_CONFIG_STRING_ARRAY,
11002                 new String[]{
11003                         "com.android.carrierdefaultapp/.CarrierDefaultBroadcastReceiver:"
11004                                 + "com.android.internal.telephony.CARRIER_SIGNAL_RESET"
11005                 });
sDefaults.putStringArray(KEY_CARRIER_APP_NO_WAKE_SIGNAL_CONFIG_STRING_ARRAY, null)11006         sDefaults.putStringArray(KEY_CARRIER_APP_NO_WAKE_SIGNAL_CONFIG_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_CARRIER_APP_REQUIRED_DURING_SIM_SETUP_BOOL, false)11007         sDefaults.putBoolean(KEY_CARRIER_APP_REQUIRED_DURING_SIM_SETUP_BOOL, false);
11008 
11009         // Default carrier app configurations
sDefaults.putStringArray(KEY_CARRIER_DEFAULT_ACTIONS_ON_REDIRECTION_STRING_ARRAY, new String[]{ "9, 4, 1" })11010         sDefaults.putStringArray(KEY_CARRIER_DEFAULT_ACTIONS_ON_REDIRECTION_STRING_ARRAY,
11011                 new String[]{
11012                         "9, 4, 1"
11013                         //9: CARRIER_ACTION_REGISTER_NETWORK_AVAIL
11014                         //4: CARRIER_ACTION_DISABLE_METERED_APNS
11015                         //1: CARRIER_ACTION_SHOW_PORTAL_NOTIFICATION
11016                 });
sDefaults.putStringArray(KEY_CARRIER_DEFAULT_ACTIONS_ON_RESET, new String[]{ "6, 8" })11017         sDefaults.putStringArray(KEY_CARRIER_DEFAULT_ACTIONS_ON_RESET, new String[]{
11018                 "6, 8"
11019                 //6: CARRIER_ACTION_CANCEL_ALL_NOTIFICATIONS
11020                 //8: CARRIER_ACTION_DISABLE_DEFAULT_URL_HANDLER
11021                 });
sDefaults.putStringArray(KEY_CARRIER_DEFAULT_ACTIONS_ON_DEFAULT_NETWORK_AVAILABLE, new String[] { false + ": 7", true + ": 8" })11022         sDefaults.putStringArray(KEY_CARRIER_DEFAULT_ACTIONS_ON_DEFAULT_NETWORK_AVAILABLE,
11023                 new String[] {
11024                         false + ": 7", //7: CARRIER_ACTION_ENABLE_DEFAULT_URL_HANDLER
11025                         true + ": 8"  //8: CARRIER_ACTION_DISABLE_DEFAULT_URL_HANDLER
11026                 });
sDefaults.putStringArray(KEY_CARRIER_DEFAULT_REDIRECTION_URL_STRING_ARRAY, null)11027         sDefaults.putStringArray(KEY_CARRIER_DEFAULT_REDIRECTION_URL_STRING_ARRAY, null);
11028 
sDefaults.putInt(KEY_MONTHLY_DATA_CYCLE_DAY_INT, DATA_CYCLE_USE_PLATFORM_DEFAULT)11029         sDefaults.putInt(KEY_MONTHLY_DATA_CYCLE_DAY_INT, DATA_CYCLE_USE_PLATFORM_DEFAULT);
sDefaults.putLong(KEY_DATA_WARNING_THRESHOLD_BYTES_LONG, DATA_CYCLE_USE_PLATFORM_DEFAULT)11030         sDefaults.putLong(KEY_DATA_WARNING_THRESHOLD_BYTES_LONG, DATA_CYCLE_USE_PLATFORM_DEFAULT);
sDefaults.putBoolean(KEY_DATA_WARNING_NOTIFICATION_BOOL, true)11031         sDefaults.putBoolean(KEY_DATA_WARNING_NOTIFICATION_BOOL, true);
sDefaults.putBoolean(KEY_LIMITED_SIM_FUNCTION_NOTIFICATION_FOR_DSDS_BOOL, false)11032         sDefaults.putBoolean(KEY_LIMITED_SIM_FUNCTION_NOTIFICATION_FOR_DSDS_BOOL, false);
sDefaults.putLong(KEY_DATA_LIMIT_THRESHOLD_BYTES_LONG, DATA_CYCLE_USE_PLATFORM_DEFAULT)11033         sDefaults.putLong(KEY_DATA_LIMIT_THRESHOLD_BYTES_LONG, DATA_CYCLE_USE_PLATFORM_DEFAULT);
sDefaults.putBoolean(KEY_DATA_LIMIT_NOTIFICATION_BOOL, true)11034         sDefaults.putBoolean(KEY_DATA_LIMIT_NOTIFICATION_BOOL, true);
sDefaults.putBoolean(KEY_DATA_RAPID_NOTIFICATION_BOOL, true)11035         sDefaults.putBoolean(KEY_DATA_RAPID_NOTIFICATION_BOOL, true);
11036 
11037         // Rat families: {GPRS, EDGE}, {EVDO, EVDO_A, EVDO_B}, {UMTS, HSPA, HSDPA, HSUPA, HSPAP},
11038         // {LTE, LTE_CA}
11039         // Order is important - lowest precedence first
sDefaults.putStringArray(KEY_RATCHET_RAT_FAMILIES, new String[]{"1,2", "7,8,12", "3,11,9,10,15", "14,19"})11040         sDefaults.putStringArray(KEY_RATCHET_RAT_FAMILIES,
11041                 new String[]{"1,2", "7,8,12", "3,11,9,10,15", "14,19"});
sDefaults.putBoolean(KEY_TREAT_DOWNGRADED_VIDEO_CALLS_AS_VIDEO_CALLS_BOOL, false)11042         sDefaults.putBoolean(KEY_TREAT_DOWNGRADED_VIDEO_CALLS_AS_VIDEO_CALLS_BOOL, false);
sDefaults.putBoolean(KEY_DROP_VIDEO_CALL_WHEN_ANSWERING_AUDIO_CALL_BOOL, false)11043         sDefaults.putBoolean(KEY_DROP_VIDEO_CALL_WHEN_ANSWERING_AUDIO_CALL_BOOL, false);
sDefaults.putBoolean(KEY_ALLOW_MERGE_WIFI_CALLS_WHEN_VOWIFI_OFF_BOOL, true)11044         sDefaults.putBoolean(KEY_ALLOW_MERGE_WIFI_CALLS_WHEN_VOWIFI_OFF_BOOL, true);
sDefaults.putBoolean(KEY_ALLOW_ADD_CALL_DURING_VIDEO_CALL_BOOL, true)11045         sDefaults.putBoolean(KEY_ALLOW_ADD_CALL_DURING_VIDEO_CALL_BOOL, true);
sDefaults.putBoolean(KEY_ALLOW_HOLD_VIDEO_CALL_BOOL, true)11046         sDefaults.putBoolean(KEY_ALLOW_HOLD_VIDEO_CALL_BOOL, true);
sDefaults.putBoolean(KEY_WIFI_CALLS_CAN_BE_HD_AUDIO, true)11047         sDefaults.putBoolean(KEY_WIFI_CALLS_CAN_BE_HD_AUDIO, true);
sDefaults.putBoolean(KEY_VIDEO_CALLS_CAN_BE_HD_AUDIO, true)11048         sDefaults.putBoolean(KEY_VIDEO_CALLS_CAN_BE_HD_AUDIO, true);
sDefaults.putBoolean(KEY_GSM_CDMA_CALLS_CAN_BE_HD_AUDIO, false)11049         sDefaults.putBoolean(KEY_GSM_CDMA_CALLS_CAN_BE_HD_AUDIO, false);
sDefaults.putBoolean(KEY_ALLOW_VIDEO_CALLING_FALLBACK_BOOL, true)11050         sDefaults.putBoolean(KEY_ALLOW_VIDEO_CALLING_FALLBACK_BOOL, true);
11051 
sDefaults.putStringArray(KEY_IMS_REASONINFO_MAPPING_STRING_ARRAY, null)11052         sDefaults.putStringArray(KEY_IMS_REASONINFO_MAPPING_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_ENHANCED_4G_LTE_TITLE_VARIANT_BOOL, false)11053         sDefaults.putBoolean(KEY_ENHANCED_4G_LTE_TITLE_VARIANT_BOOL, false);
sDefaults.putInt(KEY_ENHANCED_4G_LTE_TITLE_VARIANT_INT, 0)11054         sDefaults.putInt(KEY_ENHANCED_4G_LTE_TITLE_VARIANT_INT, 0);
sDefaults.putBoolean(KEY_NOTIFY_VT_HANDOVER_TO_WIFI_FAILURE_BOOL, false)11055         sDefaults.putBoolean(KEY_NOTIFY_VT_HANDOVER_TO_WIFI_FAILURE_BOOL, false);
sDefaults.putStringArray(KEY_FILTERED_CNAP_NAMES_STRING_ARRAY, null)11056         sDefaults.putStringArray(KEY_FILTERED_CNAP_NAMES_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_EDITABLE_WFC_ROAMING_MODE_BOOL, false)11057         sDefaults.putBoolean(KEY_EDITABLE_WFC_ROAMING_MODE_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_BLOCKING_PAY_PHONE_OPTION_BOOL, false)11058         sDefaults.putBoolean(KEY_SHOW_BLOCKING_PAY_PHONE_OPTION_BOOL, false);
sDefaults.putBoolean(KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL, false)11059         sDefaults.putBoolean(KEY_USE_WFC_HOME_NETWORK_MODE_IN_ROAMING_NETWORK_BOOL, false);
sDefaults.putBoolean(KEY_STK_DISABLE_LAUNCH_BROWSER_BOOL, false)11060         sDefaults.putBoolean(KEY_STK_DISABLE_LAUNCH_BROWSER_BOOL, false);
sDefaults.putBoolean(KEY_ALLOW_METERED_NETWORK_FOR_CERT_DOWNLOAD_BOOL, false)11061         sDefaults.putBoolean(KEY_ALLOW_METERED_NETWORK_FOR_CERT_DOWNLOAD_BOOL, false);
sDefaults.putBoolean(KEY_HIDE_DIGITS_HELPER_TEXT_ON_STK_INPUT_SCREEN_BOOL, true)11062         sDefaults.putBoolean(KEY_HIDE_DIGITS_HELPER_TEXT_ON_STK_INPUT_SCREEN_BOOL, true);
sDefaults.putInt(KEY_PREF_NETWORK_NOTIFICATION_DELAY_INT, -1)11063         sDefaults.putInt(KEY_PREF_NETWORK_NOTIFICATION_DELAY_INT, -1);
sDefaults.putInt(KEY_EMERGENCY_NOTIFICATION_DELAY_INT, -1)11064         sDefaults.putInt(KEY_EMERGENCY_NOTIFICATION_DELAY_INT, -1);
sDefaults.putBoolean(KEY_ALLOW_USSD_REQUESTS_VIA_TELEPHONY_MANAGER_BOOL, true)11065         sDefaults.putBoolean(KEY_ALLOW_USSD_REQUESTS_VIA_TELEPHONY_MANAGER_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORT_3GPP_CALL_FORWARDING_WHILE_ROAMING_BOOL, true)11066         sDefaults.putBoolean(KEY_SUPPORT_3GPP_CALL_FORWARDING_WHILE_ROAMING_BOOL, true);
sDefaults.putBoolean(KEY_DISPLAY_VOICEMAIL_NUMBER_AS_DEFAULT_CALL_FORWARDING_NUMBER_BOOL, false)11067         sDefaults.putBoolean(KEY_DISPLAY_VOICEMAIL_NUMBER_AS_DEFAULT_CALL_FORWARDING_NUMBER_BOOL,
11068                 false);
sDefaults.putBoolean(KEY_NOTIFY_INTERNATIONAL_CALL_ON_WFC_BOOL, false)11069         sDefaults.putBoolean(KEY_NOTIFY_INTERNATIONAL_CALL_ON_WFC_BOOL, false);
sDefaults.putBoolean(KEY_HIDE_PRESET_APN_DETAILS_BOOL, false)11070         sDefaults.putBoolean(KEY_HIDE_PRESET_APN_DETAILS_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_VIDEO_CALL_CHARGES_ALERT_DIALOG_BOOL, false)11071         sDefaults.putBoolean(KEY_SHOW_VIDEO_CALL_CHARGES_ALERT_DIALOG_BOOL, false);
sDefaults.putStringArray(KEY_CALL_FORWARDING_BLOCKS_WHILE_ROAMING_STRING_ARRAY, null)11072         sDefaults.putStringArray(KEY_CALL_FORWARDING_BLOCKS_WHILE_ROAMING_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_SUPPORT_IMS_CALL_FORWARDING_WHILE_ROAMING_BOOL, true)11073         sDefaults.putBoolean(KEY_SUPPORT_IMS_CALL_FORWARDING_WHILE_ROAMING_BOOL, true);
sDefaults.putInt(KEY_LTE_EARFCNS_RSRP_BOOST_INT, 0)11074         sDefaults.putInt(KEY_LTE_EARFCNS_RSRP_BOOST_INT, 0);
sDefaults.putStringArray(KEY_BOOSTED_LTE_EARFCNS_STRING_ARRAY, null)11075         sDefaults.putStringArray(KEY_BOOSTED_LTE_EARFCNS_STRING_ARRAY, null);
sDefaults.putIntArray(KEY_NRARFCNS_RSRP_BOOST_INT_ARRAY, null)11076         sDefaults.putIntArray(KEY_NRARFCNS_RSRP_BOOST_INT_ARRAY, null);
sDefaults.putStringArray(KEY_BOOSTED_NRARFCNS_STRING_ARRAY, null)11077         sDefaults.putStringArray(KEY_BOOSTED_NRARFCNS_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_USE_ONLY_RSRP_FOR_LTE_SIGNAL_BAR_BOOL, false)11078         sDefaults.putBoolean(KEY_USE_ONLY_RSRP_FOR_LTE_SIGNAL_BAR_BOOL, false);
sDefaults.putBoolean(KEY_DISABLE_VOICE_BARRING_NOTIFICATION_BOOL, false)11079         sDefaults.putBoolean(KEY_DISABLE_VOICE_BARRING_NOTIFICATION_BOOL, false);
sDefaults.putInt(IMSI_KEY_AVAILABILITY_INT, 0)11080         sDefaults.putInt(IMSI_KEY_AVAILABILITY_INT, 0);
sDefaults.putString(IMSI_KEY_DOWNLOAD_URL_STRING, null)11081         sDefaults.putString(IMSI_KEY_DOWNLOAD_URL_STRING, null);
sDefaults.putString(IMSI_CARRIER_PUBLIC_KEY_EPDG_STRING, null)11082         sDefaults.putString(IMSI_CARRIER_PUBLIC_KEY_EPDG_STRING, null);
sDefaults.putString(IMSI_CARRIER_PUBLIC_KEY_WLAN_STRING, null)11083         sDefaults.putString(IMSI_CARRIER_PUBLIC_KEY_WLAN_STRING, null);
sDefaults.putBoolean(KEY_CONVERT_CDMA_CALLER_ID_MMI_CODES_WHILE_ROAMING_ON_3GPP_BOOL, false)11084         sDefaults.putBoolean(KEY_CONVERT_CDMA_CALLER_ID_MMI_CODES_WHILE_ROAMING_ON_3GPP_BOOL,
11085                 false);
sDefaults.putStringArray(KEY_NON_ROAMING_OPERATOR_STRING_ARRAY, null)11086         sDefaults.putStringArray(KEY_NON_ROAMING_OPERATOR_STRING_ARRAY, null);
sDefaults.putStringArray(KEY_ROAMING_OPERATOR_STRING_ARRAY, null)11087         sDefaults.putStringArray(KEY_ROAMING_OPERATOR_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_SHOW_ROAMING_INDICATOR_BOOL, true)11088         sDefaults.putBoolean(KEY_SHOW_ROAMING_INDICATOR_BOOL, true);
sDefaults.putBoolean(KEY_SHOW_IMS_REGISTRATION_STATUS_BOOL, false)11089         sDefaults.putBoolean(KEY_SHOW_IMS_REGISTRATION_STATUS_BOOL, false);
sDefaults.putBoolean(KEY_RTT_SUPPORTED_BOOL, false)11090         sDefaults.putBoolean(KEY_RTT_SUPPORTED_BOOL, false);
sDefaults.putBoolean(KEY_TTY_SUPPORTED_BOOL, true)11091         sDefaults.putBoolean(KEY_TTY_SUPPORTED_BOOL, true);
sDefaults.putBoolean(KEY_RTT_AUTO_UPGRADE_BOOL, false)11092         sDefaults.putBoolean(KEY_RTT_AUTO_UPGRADE_BOOL, false);
sDefaults.putBoolean(KEY_RTT_SUPPORTED_FOR_VT_BOOL, false)11093         sDefaults.putBoolean(KEY_RTT_SUPPORTED_FOR_VT_BOOL, false);
sDefaults.putBoolean(KEY_RTT_UPGRADE_SUPPORTED_BOOL, false)11094         sDefaults.putBoolean(KEY_RTT_UPGRADE_SUPPORTED_BOOL, false);
sDefaults.putBoolean(KEY_RTT_DOWNGRADE_SUPPORTED_BOOL, false)11095         sDefaults.putBoolean(KEY_RTT_DOWNGRADE_SUPPORTED_BOOL, false);
sDefaults.putBoolean(KEY_HIDE_TTY_HCO_VCO_WITH_RTT_BOOL, false)11096         sDefaults.putBoolean(KEY_HIDE_TTY_HCO_VCO_WITH_RTT_BOOL, false);
sDefaults.putBoolean(KEY_RTT_SUPPORTED_WHILE_ROAMING_BOOL, false)11097         sDefaults.putBoolean(KEY_RTT_SUPPORTED_WHILE_ROAMING_BOOL, false);
sDefaults.putBoolean(KEY_RTT_UPGRADE_SUPPORTED_FOR_DOWNGRADED_VT_CALL_BOOL, true)11098         sDefaults.putBoolean(KEY_RTT_UPGRADE_SUPPORTED_FOR_DOWNGRADED_VT_CALL_BOOL, true);
sDefaults.putBoolean(KEY_VT_UPGRADE_SUPPORTED_FOR_DOWNGRADED_RTT_CALL_BOOL, true)11099         sDefaults.putBoolean(KEY_VT_UPGRADE_SUPPORTED_FOR_DOWNGRADED_RTT_CALL_BOOL, true);
sDefaults.putBoolean(KEY_DISABLE_CHARGE_INDICATION_BOOL, false)11100         sDefaults.putBoolean(KEY_DISABLE_CHARGE_INDICATION_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_NO_REPLY_TIMER_FOR_CFNRY_BOOL, true)11101         sDefaults.putBoolean(KEY_SUPPORT_NO_REPLY_TIMER_FOR_CFNRY_BOOL, true);
sDefaults.putInt(KEY_NO_REPLY_TIMER_FOR_CFNRY_SEC_INT, 20)11102         sDefaults.putInt(KEY_NO_REPLY_TIMER_FOR_CFNRY_SEC_INT, 20);
sDefaults.putStringArray(KEY_FEATURE_ACCESS_CODES_STRING_ARRAY, null)11103         sDefaults.putStringArray(KEY_FEATURE_ACCESS_CODES_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_IDENTIFY_HIGH_DEFINITION_CALLS_IN_CALL_LOG_BOOL, false)11104         sDefaults.putBoolean(KEY_IDENTIFY_HIGH_DEFINITION_CALLS_IN_CALL_LOG_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_PRECISE_FAILED_CAUSE_BOOL, false)11105         sDefaults.putBoolean(KEY_SHOW_PRECISE_FAILED_CAUSE_BOOL, false);
sDefaults.putBoolean(KEY_SPN_DISPLAY_RULE_USE_ROAMING_FROM_SERVICE_STATE_BOOL, false)11106         sDefaults.putBoolean(KEY_SPN_DISPLAY_RULE_USE_ROAMING_FROM_SERVICE_STATE_BOOL, false);
sDefaults.putBoolean(KEY_ALWAYS_SHOW_DATA_RAT_ICON_BOOL, false)11107         sDefaults.putBoolean(KEY_ALWAYS_SHOW_DATA_RAT_ICON_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_4G_FOR_LTE_DATA_ICON_BOOL, false)11108         sDefaults.putBoolean(KEY_SHOW_4G_FOR_LTE_DATA_ICON_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_4GLTE_FOR_LTE_DATA_ICON_BOOL, false)11109         sDefaults.putBoolean(KEY_SHOW_4GLTE_FOR_LTE_DATA_ICON_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_4G_FOR_3G_DATA_ICON_BOOL, false)11110         sDefaults.putBoolean(KEY_SHOW_4G_FOR_3G_DATA_ICON_BOOL, false);
sDefaults.putString(KEY_OPERATOR_NAME_FILTER_PATTERN_STRING, "")11111         sDefaults.putString(KEY_OPERATOR_NAME_FILTER_PATTERN_STRING, "");
sDefaults.putString(KEY_SHOW_CARRIER_DATA_ICON_PATTERN_STRING, "")11112         sDefaults.putString(KEY_SHOW_CARRIER_DATA_ICON_PATTERN_STRING, "");
sDefaults.putBoolean(KEY_HIDE_LTE_PLUS_DATA_ICON_BOOL, true)11113         sDefaults.putBoolean(KEY_HIDE_LTE_PLUS_DATA_ICON_BOOL, true);
sDefaults.putBoolean(KEY_SHOW_5G_SLICE_ICON_BOOL, true)11114         sDefaults.putBoolean(KEY_SHOW_5G_SLICE_ICON_BOOL, true);
sDefaults.putInt(KEY_LTE_PLUS_THRESHOLD_BANDWIDTH_KHZ_INT, 20000)11115         sDefaults.putInt(KEY_LTE_PLUS_THRESHOLD_BANDWIDTH_KHZ_INT, 20000);
sDefaults.putInt(KEY_NR_ADVANCED_THRESHOLD_BANDWIDTH_KHZ_INT, 0)11116         sDefaults.putInt(KEY_NR_ADVANCED_THRESHOLD_BANDWIDTH_KHZ_INT, 0);
sDefaults.putBoolean(KEY_INCLUDE_LTE_FOR_NR_ADVANCED_THRESHOLD_BANDWIDTH_BOOL, false)11117         sDefaults.putBoolean(KEY_INCLUDE_LTE_FOR_NR_ADVANCED_THRESHOLD_BANDWIDTH_BOOL, false);
sDefaults.putBoolean(KEY_RATCHET_NR_ADVANCED_BANDWIDTH_IF_RRC_IDLE_BOOL, false)11118         sDefaults.putBoolean(KEY_RATCHET_NR_ADVANCED_BANDWIDTH_IF_RRC_IDLE_BOOL, false);
sDefaults.putIntArray(KEY_CARRIER_NR_AVAILABILITIES_INT_ARRAY, new int[]{CARRIER_NR_AVAILABILITY_NSA, CARRIER_NR_AVAILABILITY_SA})11119         sDefaults.putIntArray(KEY_CARRIER_NR_AVAILABILITIES_INT_ARRAY,
11120                 new int[]{CARRIER_NR_AVAILABILITY_NSA, CARRIER_NR_AVAILABILITY_SA});
sDefaults.putBoolean(KEY_LTE_ENABLED_BOOL, true)11121         sDefaults.putBoolean(KEY_LTE_ENABLED_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORT_TDSCDMA_BOOL, false)11122         sDefaults.putBoolean(KEY_SUPPORT_TDSCDMA_BOOL, false);
sDefaults.putStringArray(KEY_SUPPORT_TDSCDMA_ROAMING_NETWORKS_STRING_ARRAY, null)11123         sDefaults.putStringArray(KEY_SUPPORT_TDSCDMA_ROAMING_NETWORKS_STRING_ARRAY, null);
sDefaults.putBoolean(KEY_WORLD_MODE_ENABLED_BOOL, false)11124         sDefaults.putBoolean(KEY_WORLD_MODE_ENABLED_BOOL, false);
sDefaults.putString(KEY_CARRIER_SETTINGS_ACTIVITY_COMPONENT_NAME_STRING, "")11125         sDefaults.putString(KEY_CARRIER_SETTINGS_ACTIVITY_COMPONENT_NAME_STRING, "");
sDefaults.putBoolean(KEY_SHOW_OPERATOR_NAME_IN_STATUSBAR_BOOL, false)11126         sDefaults.putBoolean(KEY_SHOW_OPERATOR_NAME_IN_STATUSBAR_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_CONFIG_APPLIED_BOOL, false)11127         sDefaults.putBoolean(KEY_CARRIER_CONFIG_APPLIED_BOOL, false);
sDefaults.putBoolean(KEY_CHECK_PRICING_WITH_CARRIER_FOR_DATA_ROAMING_BOOL, false)11128         sDefaults.putBoolean(KEY_CHECK_PRICING_WITH_CARRIER_FOR_DATA_ROAMING_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_DATA_CONNECTED_ROAMING_NOTIFICATION_BOOL, false)11129         sDefaults.putBoolean(KEY_SHOW_DATA_CONNECTED_ROAMING_NOTIFICATION_BOOL, false);
sDefaults.putStringArray(KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_EXCLUDED_MCCS_STRING_ARRAY, new String[0])11130         sDefaults.putStringArray(KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_EXCLUDED_MCCS_STRING_ARRAY,
11131                 new String[0]);
sDefaults.putStringArray( KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_INCLUDED_MCC_MNCS_STRING_ARRAY, new String[0])11132         sDefaults.putStringArray(
11133                 KEY_DATA_CONNECTED_ROAMING_NOTIFICATION_INCLUDED_MCC_MNCS_STRING_ARRAY,
11134                 new String[0]);
sDefaults.putIntArray(KEY_LTE_RSRP_THRESHOLDS_INT_ARRAY, new int[] { -128, -118, -108, -98, })11135         sDefaults.putIntArray(KEY_LTE_RSRP_THRESHOLDS_INT_ARRAY,
11136                 // Boundaries: [-140 dBm, -44 dBm]
11137                 new int[] {
11138                         -128, /* SIGNAL_STRENGTH_POOR */
11139                         -118, /* SIGNAL_STRENGTH_MODERATE */
11140                         -108, /* SIGNAL_STRENGTH_GOOD */
11141                         -98,  /* SIGNAL_STRENGTH_GREAT */
11142                 });
sDefaults.putIntArray(KEY_LTE_RSRQ_THRESHOLDS_INT_ARRAY, new int[] { -20, -17, -14, -11 })11143         sDefaults.putIntArray(KEY_LTE_RSRQ_THRESHOLDS_INT_ARRAY,
11144                 // Boundaries: [-34 dB, 3 dB]
11145                 new int[] {
11146                         -20, /* SIGNAL_STRENGTH_POOR */
11147                         -17, /* SIGNAL_STRENGTH_MODERATE */
11148                         -14, /* SIGNAL_STRENGTH_GOOD */
11149                         -11  /* SIGNAL_STRENGTH_GREAT */
11150                 });
sDefaults.putIntArray(KEY_LTE_RSSNR_THRESHOLDS_INT_ARRAY, new int[] { -3, 1, 5, 13 })11151         sDefaults.putIntArray(KEY_LTE_RSSNR_THRESHOLDS_INT_ARRAY,
11152                 // Boundaries: [-20 dBm, 30 dBm]
11153                 new int[] {
11154                         -3, /* SIGNAL_STRENGTH_POOR */
11155                         1,  /* SIGNAL_STRENGTH_MODERATE */
11156                         5,  /* SIGNAL_STRENGTH_GOOD */
11157                         13  /* SIGNAL_STRENGTH_GREAT */
11158                 });
sDefaults.putIntArray(KEY_WCDMA_RSCP_THRESHOLDS_INT_ARRAY, new int[] { -115, -105, -95, -85 })11159         sDefaults.putIntArray(KEY_WCDMA_RSCP_THRESHOLDS_INT_ARRAY,
11160                 // Boundaries: [-120 dBm, -25 dBm]
11161                 new int[] {
11162                         -115, /* SIGNAL_STRENGTH_POOR */
11163                         -105, /* SIGNAL_STRENGTH_MODERATE */
11164                         -95,  /* SIGNAL_STRENGTH_GOOD */
11165                         -85   /* SIGNAL_STRENGTH_GREAT */
11166                 });
11167         // TODO(b/249896055): On enabling ECNO measurement part for Signal Bar level indication
11168         // system functionality, below values to be rechecked.
sDefaults.putIntArray(KEY_WCDMA_ECNO_THRESHOLDS_INT_ARRAY, new int[] { -24, -14, -6, 1 })11169         sDefaults.putIntArray(KEY_WCDMA_ECNO_THRESHOLDS_INT_ARRAY,
11170                 // Boundaries: [-24 dBm, 1 dBm]
11171                 new int[] {
11172                         -24, /* SIGNAL_STRENGTH_POOR */
11173                         -14, /* SIGNAL_STRENGTH_MODERATE */
11174                         -6,  /* SIGNAL_STRENGTH_GOOD */
11175                         1    /* SIGNAL_STRENGTH_GREAT */
11176                 });
sDefaults.putIntArray(KEY_5G_NR_SSRSRP_THRESHOLDS_INT_ARRAY, new int[] { -110, -90, -80, -65, })11177         sDefaults.putIntArray(KEY_5G_NR_SSRSRP_THRESHOLDS_INT_ARRAY,
11178                 // Boundaries: [-140 dB, -44 dB]
11179                 new int[] {
11180                     -110, /* SIGNAL_STRENGTH_POOR */
11181                     -90,  /* SIGNAL_STRENGTH_MODERATE */
11182                     -80,  /* SIGNAL_STRENGTH_GOOD */
11183                     -65,  /* SIGNAL_STRENGTH_GREAT */
11184                 });
sDefaults.putIntArray(KEY_5G_NR_SSRSRQ_THRESHOLDS_INT_ARRAY, new int[] { -31, -19, -7, 6 })11185         sDefaults.putIntArray(KEY_5G_NR_SSRSRQ_THRESHOLDS_INT_ARRAY,
11186                 // Boundaries: [-43 dB, 20 dB]
11187                 new int[] {
11188                     -31, /* SIGNAL_STRENGTH_POOR */
11189                     -19, /* SIGNAL_STRENGTH_MODERATE */
11190                     -7,  /* SIGNAL_STRENGTH_GOOD */
11191                     6    /* SIGNAL_STRENGTH_GREAT */
11192                 });
sDefaults.putIntArray(KEY_5G_NR_SSSINR_THRESHOLDS_INT_ARRAY, new int[] { -5, 5, 15, 30 })11193         sDefaults.putIntArray(KEY_5G_NR_SSSINR_THRESHOLDS_INT_ARRAY,
11194                 // Boundaries: [-23 dB, 40 dB]
11195                 new int[] {
11196                     -5, /* SIGNAL_STRENGTH_POOR */
11197                     5,  /* SIGNAL_STRENGTH_MODERATE */
11198                     15, /* SIGNAL_STRENGTH_GOOD */
11199                     30  /* SIGNAL_STRENGTH_GREAT */
11200                 });
sDefaults.putInt(KEY_GERAN_RSSI_HYSTERESIS_DB_INT, 2)11201         sDefaults.putInt(KEY_GERAN_RSSI_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_UTRAN_RSCP_HYSTERESIS_DB_INT, 2)11202         sDefaults.putInt(KEY_UTRAN_RSCP_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_EUTRAN_RSRP_HYSTERESIS_DB_INT, 2)11203         sDefaults.putInt(KEY_EUTRAN_RSRP_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_EUTRAN_RSRQ_HYSTERESIS_DB_INT, 2)11204         sDefaults.putInt(KEY_EUTRAN_RSRQ_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_EUTRAN_RSSNR_HYSTERESIS_DB_INT, 2)11205         sDefaults.putInt(KEY_EUTRAN_RSSNR_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_NGRAN_SSRSRP_HYSTERESIS_DB_INT, 2)11206         sDefaults.putInt(KEY_NGRAN_SSRSRP_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_NGRAN_SSRSRQ_HYSTERESIS_DB_INT, 2)11207         sDefaults.putInt(KEY_NGRAN_SSRSRQ_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_NGRAN_SSSINR_HYSTERESIS_DB_INT, 2)11208         sDefaults.putInt(KEY_NGRAN_SSSINR_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_UTRAN_ECNO_HYSTERESIS_DB_INT, 2)11209         sDefaults.putInt(KEY_UTRAN_ECNO_HYSTERESIS_DB_INT, 2);
sDefaults.putInt(KEY_PARAMETERS_USE_FOR_5G_NR_SIGNAL_BAR_INT, CellSignalStrengthNr.USE_SSRSRP)11210         sDefaults.putInt(KEY_PARAMETERS_USE_FOR_5G_NR_SIGNAL_BAR_INT,
11211                 CellSignalStrengthNr.USE_SSRSRP);
sDefaults.putBoolean(KEY_SIGNAL_STRENGTH_NR_NSA_USE_LTE_AS_PRIMARY_BOOL, true)11212         sDefaults.putBoolean(KEY_SIGNAL_STRENGTH_NR_NSA_USE_LTE_AS_PRIMARY_BOOL, true);
sDefaults.putStringArray(KEY_BANDWIDTH_STRING_ARRAY, new String[]{ "GPRS:24,24", "EDGE:70,18", "UMTS:115,115", "CDMA:14,14", "1xRTT:30,30", "EvDo_0:750,48", "EvDo_A:950,550", "HSDPA:4300,620", "HSUPA:4300,1800", "HSPA:4300,1800", "EvDo_B:1500,550", "eHRPD:750,48", "iDEN:14,14", "LTE:30000,15000", "HSPA+:13000,3400", "GSM:24,24", "TD_SCDMA:115,115", "LTE_CA:30000,15000", "NR_NSA:47000,18000", "NR_NSA_MMWAVE:145000,60000", "NR_SA:145000,60000", "NR_SA_MMWAVE:145000,60000"})11213         sDefaults.putStringArray(KEY_BANDWIDTH_STRING_ARRAY, new String[]{
11214                 "GPRS:24,24", "EDGE:70,18", "UMTS:115,115", "CDMA:14,14",
11215                 "1xRTT:30,30", "EvDo_0:750,48", "EvDo_A:950,550", "HSDPA:4300,620",
11216                 "HSUPA:4300,1800", "HSPA:4300,1800", "EvDo_B:1500,550", "eHRPD:750,48",
11217                 "iDEN:14,14", "LTE:30000,15000", "HSPA+:13000,3400", "GSM:24,24",
11218                 "TD_SCDMA:115,115", "LTE_CA:30000,15000", "NR_NSA:47000,18000",
11219                 "NR_NSA_MMWAVE:145000,60000", "NR_SA:145000,60000", "NR_SA_MMWAVE:145000,60000"});
sDefaults.putBoolean(KEY_BANDWIDTH_NR_NSA_USE_LTE_VALUE_FOR_UPLINK_BOOL, false)11220         sDefaults.putBoolean(KEY_BANDWIDTH_NR_NSA_USE_LTE_VALUE_FOR_UPLINK_BOOL, false);
sDefaults.putString(KEY_WCDMA_DEFAULT_SIGNAL_STRENGTH_MEASUREMENT_STRING, "rssi")11221         sDefaults.putString(KEY_WCDMA_DEFAULT_SIGNAL_STRENGTH_MEASUREMENT_STRING, "rssi");
sDefaults.putLong( KEY_UNDELIVERED_SMS_MESSAGE_EXPIRATION_TIME, (long) (60 * 60 * 1000) * 24 * 7)11222         sDefaults.putLong(
11223                 KEY_UNDELIVERED_SMS_MESSAGE_EXPIRATION_TIME, (long) (60 * 60 * 1000) * 24 * 7);
sDefaults.putBoolean(KEY_CONFIG_SHOW_ORIG_DIAL_STRING_FOR_CDMA_BOOL, false)11224         sDefaults.putBoolean(KEY_CONFIG_SHOW_ORIG_DIAL_STRING_FOR_CDMA_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_CALL_BLOCKING_DISABLED_NOTIFICATION_ALWAYS_BOOL, false)11225         sDefaults.putBoolean(KEY_SHOW_CALL_BLOCKING_DISABLED_NOTIFICATION_ALWAYS_BOOL, false);
sDefaults.putBoolean(KEY_CALL_FORWARDING_OVER_UT_WARNING_BOOL, false)11226         sDefaults.putBoolean(KEY_CALL_FORWARDING_OVER_UT_WARNING_BOOL, false);
sDefaults.putBoolean(KEY_CALL_BARRING_OVER_UT_WARNING_BOOL, false)11227         sDefaults.putBoolean(KEY_CALL_BARRING_OVER_UT_WARNING_BOOL, false);
sDefaults.putBoolean(KEY_CALLER_ID_OVER_UT_WARNING_BOOL, false)11228         sDefaults.putBoolean(KEY_CALLER_ID_OVER_UT_WARNING_BOOL, false);
sDefaults.putBoolean(KEY_CALL_WAITING_OVER_UT_WARNING_BOOL, false)11229         sDefaults.putBoolean(KEY_CALL_WAITING_OVER_UT_WARNING_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORT_CLIR_NETWORK_DEFAULT_BOOL, true)11230         sDefaults.putBoolean(KEY_SUPPORT_CLIR_NETWORK_DEFAULT_BOOL, true);
sDefaults.putBoolean(KEY_SUPPORT_EMERGENCY_DIALER_SHORTCUT_BOOL, true)11231         sDefaults.putBoolean(KEY_SUPPORT_EMERGENCY_DIALER_SHORTCUT_BOOL, true);
sDefaults.putBoolean(KEY_USE_CALL_FORWARDING_USSD_BOOL, false)11232         sDefaults.putBoolean(KEY_USE_CALL_FORWARDING_USSD_BOOL, false);
sDefaults.putBoolean(KEY_USE_CALLER_ID_USSD_BOOL, false)11233         sDefaults.putBoolean(KEY_USE_CALLER_ID_USSD_BOOL, false);
sDefaults.putBoolean(KEY_USE_CALL_WAITING_USSD_BOOL, false)11234         sDefaults.putBoolean(KEY_USE_CALL_WAITING_USSD_BOOL, false);
sDefaults.putInt(KEY_CALL_WAITING_SERVICE_CLASS_INT, 1 )11235         sDefaults.putInt(KEY_CALL_WAITING_SERVICE_CLASS_INT, 1 /* SERVICE_CLASS_VOICE */);
sDefaults.putString(KEY_5G_ICON_CONFIGURATION_STRING, "connected_mmwave:5G,connected:5G,connected_rrc_idle:5G,not_restricted_rrc_idle:5G," + "not_restricted_rrc_con:5G")11236         sDefaults.putString(KEY_5G_ICON_CONFIGURATION_STRING,
11237                 "connected_mmwave:5G,connected:5G,connected_rrc_idle:5G,not_restricted_rrc_idle:5G,"
11238                         + "not_restricted_rrc_con:5G");
sDefaults.putString(KEY_5G_ICON_DISPLAY_GRACE_PERIOD_STRING, "")11239         sDefaults.putString(KEY_5G_ICON_DISPLAY_GRACE_PERIOD_STRING, "");
sDefaults.putString(KEY_5G_ICON_DISPLAY_SECONDARY_GRACE_PERIOD_STRING, "")11240         sDefaults.putString(KEY_5G_ICON_DISPLAY_SECONDARY_GRACE_PERIOD_STRING, "");
sDefaults.putInt(KEY_NR_ADVANCED_PCI_CHANGE_SECONDARY_TIMER_SECONDS_INT, 0)11241         sDefaults.putInt(KEY_NR_ADVANCED_PCI_CHANGE_SECONDARY_TIMER_SECONDS_INT, 0);
sDefaults.putInt(KEY_NR_ADVANCED_BANDS_SECONDARY_TIMER_SECONDS_INT, 0)11242         sDefaults.putInt(KEY_NR_ADVANCED_BANDS_SECONDARY_TIMER_SECONDS_INT, 0);
sDefaults.putBoolean(KEY_NR_TIMERS_RESET_IF_NON_ENDC_AND_RRC_IDLE_BOOL, false)11243         sDefaults.putBoolean(KEY_NR_TIMERS_RESET_IF_NON_ENDC_AND_RRC_IDLE_BOOL, false);
sDefaults.putBoolean(KEY_NR_TIMERS_RESET_ON_VOICE_QOS_BOOL, false)11244         sDefaults.putBoolean(KEY_NR_TIMERS_RESET_ON_VOICE_QOS_BOOL, false);
sDefaults.putBoolean(KEY_NR_TIMERS_RESET_ON_PLMN_CHANGE_BOOL, false)11245         sDefaults.putBoolean(KEY_NR_TIMERS_RESET_ON_PLMN_CHANGE_BOOL, false);
11246         /* Default value is 1 hour. */
sDefaults.putLong(KEY_5G_WATCHDOG_TIME_MS_LONG, 3600000)11247         sDefaults.putLong(KEY_5G_WATCHDOG_TIME_MS_LONG, 3600000);
sDefaults.putIntArray(KEY_ADDITIONAL_NR_ADVANCED_BANDS_INT_ARRAY, new int[0])11248         sDefaults.putIntArray(KEY_ADDITIONAL_NR_ADVANCED_BANDS_INT_ARRAY, new int[0]);
sDefaults.putInt(KEY_NR_ADVANCED_CAPABLE_PCO_ID_INT, 0)11249         sDefaults.putInt(KEY_NR_ADVANCED_CAPABLE_PCO_ID_INT, 0);
sDefaults.putBoolean(KEY_ENABLE_NR_ADVANCED_WHILE_ROAMING_BOOL, true)11250         sDefaults.putBoolean(KEY_ENABLE_NR_ADVANCED_WHILE_ROAMING_BOOL, true);
sDefaults.putBoolean(KEY_LTE_ENDC_USING_USER_DATA_FOR_RRC_DETECTION_BOOL, false)11251         sDefaults.putBoolean(KEY_LTE_ENDC_USING_USER_DATA_FOR_RRC_DETECTION_BOOL, false);
sDefaults.putStringArray(KEY_UNMETERED_NETWORK_TYPES_STRING_ARRAY, new String[] { "NR_NSA", "NR_NSA_MMWAVE", "NR_SA", "NR_SA_MMWAVE"})11252         sDefaults.putStringArray(KEY_UNMETERED_NETWORK_TYPES_STRING_ARRAY, new String[] {
11253                 "NR_NSA", "NR_NSA_MMWAVE", "NR_SA", "NR_SA_MMWAVE"});
sDefaults.putStringArray(KEY_ROAMING_UNMETERED_NETWORK_TYPES_STRING_ARRAY, new String[0])11254         sDefaults.putStringArray(KEY_ROAMING_UNMETERED_NETWORK_TYPES_STRING_ARRAY, new String[0]);
sDefaults.putBoolean(KEY_ASCII_7_BIT_SUPPORT_FOR_LONG_MESSAGE_BOOL, false)11255         sDefaults.putBoolean(KEY_ASCII_7_BIT_SUPPORT_FOR_LONG_MESSAGE_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_WIFI_CALLING_ICON_IN_STATUS_BAR_BOOL, false)11256         sDefaults.putBoolean(KEY_SHOW_WIFI_CALLING_ICON_IN_STATUS_BAR_BOOL, false);
sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_OPP_DATA_AUTO_PROVISIONING_BOOL, false)11257         sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_OPP_DATA_AUTO_PROVISIONING_BOOL, false);
sDefaults.putString(KEY_SMDP_SERVER_ADDRESS_STRING, "")11258         sDefaults.putString(KEY_SMDP_SERVER_ADDRESS_STRING, "");
sDefaults.putInt(KEY_ESIM_MAX_DOWNLOAD_RETRY_ATTEMPTS_INT, 5)11259         sDefaults.putInt(KEY_ESIM_MAX_DOWNLOAD_RETRY_ATTEMPTS_INT, 5);
sDefaults.putInt(KEY_ESIM_DOWNLOAD_RETRY_BACKOFF_TIMER_SEC_INT, 60)11260         sDefaults.putInt(KEY_ESIM_DOWNLOAD_RETRY_BACKOFF_TIMER_SEC_INT, 60);
sDefaults.putIntArray(KEY_OPPORTUNISTIC_CARRIER_IDS_INT_ARRAY, new int[] {0})11261         sDefaults.putIntArray(KEY_OPPORTUNISTIC_CARRIER_IDS_INT_ARRAY, new int[] {0});
sDefaults.putBoolean(KEY_OPPORTUNISTIC_ESIM_DOWNLOAD_VIA_WIFI_ONLY_BOOL, false)11262         sDefaults.putBoolean(KEY_OPPORTUNISTIC_ESIM_DOWNLOAD_VIA_WIFI_ONLY_BOOL, false);
11263         /* Default value is minimum RSRP level needed for SIGNAL_STRENGTH_GOOD */
sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_RSRP_INT, -108)11264         sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_RSRP_INT, -108);
11265         /* Default value is minimum RSRP level needed for SIGNAL_STRENGTH_MODERATE */
sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSRP_INT, -118)11266         sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSRP_INT, -118);
11267         /* Default value is minimum RSSNR level needed for SIGNAL_STRENGTH_GOOD */
sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_RSSNR_INT, 5)11268         sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_RSSNR_INT, 5);
11269         /* Default value is minimum RSSNR level needed for SIGNAL_STRENGTH_MODERATE */
sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSSNR_INT, 1)11270         sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_EXIT_THRESHOLD_RSSNR_INT, 1);
11271         /* Default value is 1024 kbps */
sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_BANDWIDTH_INT, 1024)11272         sDefaults.putInt(KEY_OPPORTUNISTIC_NETWORK_ENTRY_THRESHOLD_BANDWIDTH_INT, 1024);
11273         /* Default value is 10 seconds */
sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_ENTRY_OR_EXIT_HYSTERESIS_TIME_LONG, 10000)11274         sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_ENTRY_OR_EXIT_HYSTERESIS_TIME_LONG, 10000);
11275         /* Default value is 10 seconds. */
sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_HYSTERESIS_TIME_LONG, 10000)11276         sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_HYSTERESIS_TIME_LONG, 10000);
11277         /* Default value is 3 seconds. */
sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG, 3000)11278         sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_DATA_SWITCH_EXIT_HYSTERESIS_TIME_LONG, 3000);
OpportunisticNetwork.getDefaults()11279         sDefaults.putAll(OpportunisticNetwork.getDefaults());
sDefaults.putBoolean(KEY_PING_TEST_BEFORE_DATA_SWITCH_BOOL, true)11280         sDefaults.putBoolean(KEY_PING_TEST_BEFORE_DATA_SWITCH_BOOL, true);
sDefaults.putBoolean(KEY_SWITCH_DATA_TO_PRIMARY_IF_PRIMARY_IS_OOS_BOOL, true)11281         sDefaults.putBoolean(KEY_SWITCH_DATA_TO_PRIMARY_IF_PRIMARY_IS_OOS_BOOL, true);
11282         /* Default value is 60 seconds. */
sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_PING_PONG_TIME_LONG, 60000)11283         sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_PING_PONG_TIME_LONG, 60000);
11284         /* Default value is 10 seconds. */
sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_BACKOFF_TIME_LONG, 10000)11285         sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_BACKOFF_TIME_LONG, 10000);
11286         /* Default value is 60 seconds. */
sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_MAX_BACKOFF_TIME_LONG, 60000)11287         sDefaults.putLong(KEY_OPPORTUNISTIC_NETWORK_MAX_BACKOFF_TIME_LONG, 60000);
sDefaults.putBoolean(KEY_ENABLE_4G_OPPORTUNISTIC_NETWORK_SCAN_BOOL, true)11288         sDefaults.putBoolean(KEY_ENABLE_4G_OPPORTUNISTIC_NETWORK_SCAN_BOOL, true);
sDefaults.putLong(KEY_TIME_TO_SWITCH_BACK_TO_PRIMARY_IF_OPPORTUNISTIC_OOS_LONG, 60000L)11289         sDefaults.putLong(KEY_TIME_TO_SWITCH_BACK_TO_PRIMARY_IF_OPPORTUNISTIC_OOS_LONG, 60000L);
sDefaults.putLong(KEY_OPPORTUNISTIC_TIME_TO_SCAN_AFTER_CAPABILITY_SWITCH_TO_PRIMARY_LONG, 120000L)11290         sDefaults.putLong(KEY_OPPORTUNISTIC_TIME_TO_SCAN_AFTER_CAPABILITY_SWITCH_TO_PRIMARY_LONG,
11291                 120000L);
ImsServiceEntitlement.getDefaults()11292         sDefaults.putAll(ImsServiceEntitlement.getDefaults());
Gps.getDefaults()11293         sDefaults.putAll(Gps.getDefaults());
sDefaults.putIntArray(KEY_CDMA_ENHANCED_ROAMING_INDICATOR_FOR_HOME_NETWORK_INT_ARRAY, new int[] { 1 })11294         sDefaults.putIntArray(KEY_CDMA_ENHANCED_ROAMING_INDICATOR_FOR_HOME_NETWORK_INT_ARRAY,
11295                 new int[] {
11296                         1 /* Roaming Indicator Off */
11297                 });
sDefaults.putStringArray(KEY_EMERGENCY_NUMBER_PREFIX_STRING_ARRAY, new String[0])11298         sDefaults.putStringArray(KEY_EMERGENCY_NUMBER_PREFIX_STRING_ARRAY, new String[0]);
sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_CALLER_ID_VERTICAL_SERVICE_CODES_BOOL, false)11299         sDefaults.putBoolean(KEY_CARRIER_SUPPORTS_CALLER_ID_VERTICAL_SERVICE_CODES_BOOL, false);
sDefaults.putBoolean(KEY_USE_USIM_BOOL, false)11300         sDefaults.putBoolean(KEY_USE_USIM_BOOL, false);
sDefaults.putBoolean(KEY_SHOW_WFC_LOCATION_PRIVACY_POLICY_BOOL, false)11301         sDefaults.putBoolean(KEY_SHOW_WFC_LOCATION_PRIVACY_POLICY_BOOL, false);
sDefaults.putBoolean(KEY_AUTO_CANCEL_CS_REJECT_NOTIFICATION, true)11302         sDefaults.putBoolean(KEY_AUTO_CANCEL_CS_REJECT_NOTIFICATION, true);
sDefaults.putString(KEY_SMART_FORWARDING_CONFIG_COMPONENT_NAME_STRING, "")11303         sDefaults.putString(KEY_SMART_FORWARDING_CONFIG_COMPONENT_NAME_STRING, "");
sDefaults.putBoolean(KEY_ALWAYS_SHOW_PRIMARY_SIGNAL_BAR_IN_OPPORTUNISTIC_NETWORK_BOOLEAN, false)11304         sDefaults.putBoolean(KEY_ALWAYS_SHOW_PRIMARY_SIGNAL_BAR_IN_OPPORTUNISTIC_NETWORK_BOOLEAN,
11305                 false);
sDefaults.putString(KEY_SUBSCRIPTION_GROUP_UUID_STRING, "")11306         sDefaults.putString(KEY_SUBSCRIPTION_GROUP_UUID_STRING, "");
sDefaults.putBoolean(KEY_IS_OPPORTUNISTIC_SUBSCRIPTION_BOOL, false)11307         sDefaults.putBoolean(KEY_IS_OPPORTUNISTIC_SUBSCRIPTION_BOOL, false);
sDefaults.putIntArray(KEY_GSM_RSSI_THRESHOLDS_INT_ARRAY, new int[] { -107, -103, -97, -89, })11308         sDefaults.putIntArray(KEY_GSM_RSSI_THRESHOLDS_INT_ARRAY,
11309                 new int[] {
11310                         -107, /* SIGNAL_STRENGTH_POOR */
11311                         -103, /* SIGNAL_STRENGTH_MODERATE */
11312                         -97,  /* SIGNAL_STRENGTH_GOOD */
11313                         -89,  /* SIGNAL_STRENGTH_GREAT */
11314                 });
sDefaults.putBoolean(KEY_SUPPORT_WPS_OVER_IMS_BOOL, true)11315         sDefaults.putBoolean(KEY_SUPPORT_WPS_OVER_IMS_BOOL, true);
Ims.getDefaults()11316         sDefaults.putAll(Ims.getDefaults());
ImsVoice.getDefaults()11317         sDefaults.putAll(ImsVoice.getDefaults());
ImsSms.getDefaults()11318         sDefaults.putAll(ImsSms.getDefaults());
ImsRtt.getDefaults()11319         sDefaults.putAll(ImsRtt.getDefaults());
ImsEmergency.getDefaults()11320         sDefaults.putAll(ImsEmergency.getDefaults());
ImsVt.getDefaults()11321         sDefaults.putAll(ImsVt.getDefaults());
ImsWfc.getDefaults()11322         sDefaults.putAll(ImsWfc.getDefaults());
ImsSs.getDefaults()11323         sDefaults.putAll(ImsSs.getDefaults());
Bsf.getDefaults()11324         sDefaults.putAll(Bsf.getDefaults());
Iwlan.getDefaults()11325         sDefaults.putAll(Iwlan.getDefaults());
sDefaults.putStringArray(KEY_CARRIER_CERTIFICATE_STRING_ARRAY, new String[0])11326         sDefaults.putStringArray(KEY_CARRIER_CERTIFICATE_STRING_ARRAY, new String[0]);
sDefaults.putBoolean(KEY_FORMAT_INCOMING_NUMBER_TO_NATIONAL_FOR_JP_BOOL, false)11327         sDefaults.putBoolean(KEY_FORMAT_INCOMING_NUMBER_TO_NATIONAL_FOR_JP_BOOL, false);
11328         if (Flags.doNotOverridePreciseLabel()) {
sDefaults.putIntArray(KEY_DISCONNECT_CAUSE_PLAY_BUSYTONE_INT_ARRAY, new int[]{})11329             sDefaults.putIntArray(KEY_DISCONNECT_CAUSE_PLAY_BUSYTONE_INT_ARRAY, new int[]{});
11330         } else {
sDefaults.putIntArray(KEY_DISCONNECT_CAUSE_PLAY_BUSYTONE_INT_ARRAY, new int[]{4 })11331             sDefaults.putIntArray(KEY_DISCONNECT_CAUSE_PLAY_BUSYTONE_INT_ARRAY,
11332                     new int[]{4 /* BUSY */});
11333         }
sDefaults.putBoolean(KEY_PREVENT_CLIR_ACTIVATION_AND_DEACTIVATION_CODE_BOOL, false)11334         sDefaults.putBoolean(KEY_PREVENT_CLIR_ACTIVATION_AND_DEACTIVATION_CODE_BOOL, false);
sDefaults.putLong(KEY_DATA_SWITCH_VALIDATION_TIMEOUT_LONG, 5000)11335         sDefaults.putLong(KEY_DATA_SWITCH_VALIDATION_TIMEOUT_LONG, 5000);
sDefaults.putStringArray(KEY_MMI_TWO_DIGIT_NUMBER_PATTERN_STRING_ARRAY, new String[0])11336         sDefaults.putStringArray(KEY_MMI_TWO_DIGIT_NUMBER_PATTERN_STRING_ARRAY, new String[0]);
sDefaults.putInt(KEY_PARAMETERS_USED_FOR_LTE_SIGNAL_BAR_INT, CellSignalStrengthLte.USE_RSRP)11337         sDefaults.putInt(KEY_PARAMETERS_USED_FOR_LTE_SIGNAL_BAR_INT,
11338                 CellSignalStrengthLte.USE_RSRP);
sDefaults.putInt(KEY_MIN_UDP_PORT_4500_NAT_TIMEOUT_SEC_INT, 300)11339         sDefaults.putInt(KEY_MIN_UDP_PORT_4500_NAT_TIMEOUT_SEC_INT, 300);
sDefaults.putInt(KEY_PREFERRED_IKE_PROTOCOL_INT, -1)11340         sDefaults.putInt(KEY_PREFERRED_IKE_PROTOCOL_INT, -1);
11341         // Default wifi configurations.
Wifi.getDefaults()11342         sDefaults.putAll(Wifi.getDefaults());
sDefaults.putBoolean(ENABLE_EAP_METHOD_PREFIX_BOOL, false)11343         sDefaults.putBoolean(ENABLE_EAP_METHOD_PREFIX_BOOL, false);
sDefaults.putInt(KEY_GBA_MODE_INT, GBA_ME)11344         sDefaults.putInt(KEY_GBA_MODE_INT, GBA_ME);
sDefaults.putInt(KEY_GBA_UA_SECURITY_ORGANIZATION_INT, UaSecurityProtocolIdentifier.ORG_3GPP)11345         sDefaults.putInt(KEY_GBA_UA_SECURITY_ORGANIZATION_INT,
11346                 UaSecurityProtocolIdentifier.ORG_3GPP);
sDefaults.putInt(KEY_GBA_UA_SECURITY_PROTOCOL_INT, UaSecurityProtocolIdentifier.UA_SECURITY_PROTOCOL_3GPP_TLS_DEFAULT)11347         sDefaults.putInt(KEY_GBA_UA_SECURITY_PROTOCOL_INT,
11348                 UaSecurityProtocolIdentifier.UA_SECURITY_PROTOCOL_3GPP_TLS_DEFAULT);
sDefaults.putInt(KEY_GBA_UA_TLS_CIPHER_SUITE_INT, TlsParams.TLS_NULL_WITH_NULL_NULL)11349         sDefaults.putInt(KEY_GBA_UA_TLS_CIPHER_SUITE_INT, TlsParams.TLS_NULL_WITH_NULL_NULL);
11350 
sDefaults.putBoolean(KEY_SHOW_FORWARDED_NUMBER_BOOL, false)11351         sDefaults.putBoolean(KEY_SHOW_FORWARDED_NUMBER_BOOL, false);
sDefaults.putLong(KEY_DATA_SWITCH_VALIDATION_MIN_INTERVAL_MILLIS_LONG, TimeUnit.DAYS.toMillis(1))11352         sDefaults.putLong(KEY_DATA_SWITCH_VALIDATION_MIN_INTERVAL_MILLIS_LONG,
11353                 TimeUnit.DAYS.toMillis(1));
sDefaults.putStringArray(KEY_MISSED_INCOMING_CALL_SMS_ORIGINATOR_STRING_ARRAY, new String[0])11354         sDefaults.putStringArray(KEY_MISSED_INCOMING_CALL_SMS_ORIGINATOR_STRING_ARRAY,
11355                 new String[0]);
11356 
11357         // Do not modify the priority unless you know what you are doing. This will have significant
11358         // impacts on the order of data network setup.
sDefaults.putStringArray( KEY_TELEPHONY_NETWORK_CAPABILITY_PRIORITIES_STRING_ARRAY, new String[] { "eims:90", "supl:80", "mms:70", "xcap:70", "cbs:50", "mcx:50", "fota:50", "ims:40", "rcs:40", "dun:30", "enterprise:20", "internet:20", "prioritize_bandwidth:20", "prioritize_latency:20" })11359         sDefaults.putStringArray(
11360                 KEY_TELEPHONY_NETWORK_CAPABILITY_PRIORITIES_STRING_ARRAY, new String[] {
11361                         "eims:90", "supl:80", "mms:70", "xcap:70", "cbs:50", "mcx:50", "fota:50",
11362                         "ims:40", "rcs:40", "dun:30", "enterprise:20", "internet:20",
11363                         "prioritize_bandwidth:20", "prioritize_latency:20"
11364                 });
sDefaults.putStringArray( KEY_TELEPHONY_DATA_SETUP_RETRY_RULES_STRING_ARRAY, new String[] { "capabilities=eims, retry_interval=1000, maximum_retries=20", "permanent_fail_causes=8|27|28|29|30|32|33|35|50|51|111|-5|-6|65537|65538|" + "-3|65543|65547|2252|2253|2254, retry_interval=2500", "capabilities=mms|supl|cbs|rcs, retry_interval=2000", "capabilities=internet|enterprise|dun|ims|fota|xcap|mcx|" + "prioritize_bandwidth|prioritize_latency, retry_interval=" + "2500|3000|5000|10000|15000|20000|40000|60000|120000|240000|" + "600000|1200000|1800000, maximum_retries=20" })11365         sDefaults.putStringArray(
11366                 KEY_TELEPHONY_DATA_SETUP_RETRY_RULES_STRING_ARRAY, new String[] {
11367                         "capabilities=eims, retry_interval=1000, maximum_retries=20",
11368                         // Permanent fail causes. When setup data call fails with the following
11369                         // fail causes, telephony data frameworks will stop timer-based retry on
11370                         // the failed APN until power cycle, APM, or some special events. Note that
11371                         // even timer-based retry is not performed, condition-based (RAT changes,
11372                         // registration state changes) retry can still happen.
11373                         "permanent_fail_causes=8|27|28|29|30|32|33|35|50|51|111|-5|-6|65537|65538|"
11374                                 + "-3|65543|65547|2252|2253|2254, retry_interval=2500",
11375                         "capabilities=mms|supl|cbs|rcs, retry_interval=2000",
11376                         "capabilities=internet|enterprise|dun|ims|fota|xcap|mcx|"
11377                                 + "prioritize_bandwidth|prioritize_latency, retry_interval="
11378                                 + "2500|3000|5000|10000|15000|20000|40000|60000|120000|240000|"
11379                                 + "600000|1200000|1800000, maximum_retries=20"
11380                 });
sDefaults.putStringArray( KEY_TELEPHONY_DATA_HANDOVER_RETRY_RULES_STRING_ARRAY, new String[] { "retry_interval=1000|2000|4000|8000|16000, maximum_retries=5" })11381         sDefaults.putStringArray(
11382                 KEY_TELEPHONY_DATA_HANDOVER_RETRY_RULES_STRING_ARRAY, new String[] {
11383                         "retry_interval=1000|2000|4000|8000|16000, maximum_retries=5"
11384                 });
sDefaults.putBoolean(KEY_DELAY_IMS_TEAR_DOWN_UNTIL_CALL_END_BOOL, false)11385         sDefaults.putBoolean(KEY_DELAY_IMS_TEAR_DOWN_UNTIL_CALL_END_BOOL, false);
sDefaults.putStringArray(KEY_MISSED_INCOMING_CALL_SMS_PATTERN_STRING_ARRAY, new String[0])11386         sDefaults.putStringArray(KEY_MISSED_INCOMING_CALL_SMS_PATTERN_STRING_ARRAY, new String[0]);
sDefaults.putPersistableBundle( KEY_CARRIER_SUPPORTED_SATELLITE_SERVICES_PER_PROVIDER_BUNDLE, PersistableBundle.EMPTY)11387         sDefaults.putPersistableBundle(
11388                 KEY_CARRIER_SUPPORTED_SATELLITE_SERVICES_PER_PROVIDER_BUNDLE,
11389                 PersistableBundle.EMPTY);
sDefaults.putPersistableBundle( KEY_REGIONAL_SATELLITE_EARFCN_BUNDLE, PersistableBundle.EMPTY)11390         sDefaults.putPersistableBundle(
11391                 KEY_REGIONAL_SATELLITE_EARFCN_BUNDLE,
11392                 PersistableBundle.EMPTY);
sDefaults.putBoolean(KEY_SATELLITE_ATTACH_SUPPORTED_BOOL, false)11393         sDefaults.putBoolean(KEY_SATELLITE_ATTACH_SUPPORTED_BOOL, false);
sDefaults.putInt(KEY_SATELLITE_CONNECTION_HYSTERESIS_SEC_INT, 180)11394         sDefaults.putInt(KEY_SATELLITE_CONNECTION_HYSTERESIS_SEC_INT, 180);
sDefaults.putIntArray(KEY_NTN_LTE_RSRP_THRESHOLDS_INT_ARRAY, new int[]{ -128, -118, -108, -98 })11395         sDefaults.putIntArray(KEY_NTN_LTE_RSRP_THRESHOLDS_INT_ARRAY,
11396                 // Boundaries: [-140 dBm, -44 dBm]
11397                 new int[]{
11398                         -128, /* SIGNAL_STRENGTH_POOR */
11399                         -118, /* SIGNAL_STRENGTH_MODERATE */
11400                         -108, /* SIGNAL_STRENGTH_GOOD */
11401                         -98  /* SIGNAL_STRENGTH_GREAT */
11402                 });
sDefaults.putIntArray(KEY_NTN_LTE_RSRQ_THRESHOLDS_INT_ARRAY, new int[]{ -20, -17, -14, -11 })11403         sDefaults.putIntArray(KEY_NTN_LTE_RSRQ_THRESHOLDS_INT_ARRAY,
11404                 // Boundaries: [-34 dB, 3 dB]
11405                 new int[]{
11406                         -20, /* SIGNAL_STRENGTH_POOR */
11407                         -17, /* SIGNAL_STRENGTH_MODERATE */
11408                         -14, /* SIGNAL_STRENGTH_GOOD */
11409                         -11  /* SIGNAL_STRENGTH_GREAT */
11410                 });
sDefaults.putIntArray(KEY_NTN_LTE_RSSNR_THRESHOLDS_INT_ARRAY, new int[] { -3, 1, 5, 13 })11411         sDefaults.putIntArray(KEY_NTN_LTE_RSSNR_THRESHOLDS_INT_ARRAY,
11412                 // Boundaries: [-20 dBm, 30 dBm]
11413                 new int[] {
11414                         -3, /* SIGNAL_STRENGTH_POOR */
11415                         1, /* SIGNAL_STRENGTH_MODERATE */
11416                         5,  /* SIGNAL_STRENGTH_GOOD */
11417                         13   /* SIGNAL_STRENGTH_GREAT */
11418                 });
sDefaults.putInt(KEY_PARAMETERS_USED_FOR_NTN_LTE_SIGNAL_BAR_INT, CellSignalStrengthLte.USE_RSRP)11419         sDefaults.putInt(KEY_PARAMETERS_USED_FOR_NTN_LTE_SIGNAL_BAR_INT,
11420                 CellSignalStrengthLte.USE_RSRP);
sDefaults.putBoolean(KEY_REMOVE_SATELLITE_PLMN_IN_MANUAL_NETWORK_SCAN_BOOL, true)11421         sDefaults.putBoolean(KEY_REMOVE_SATELLITE_PLMN_IN_MANUAL_NETWORK_SCAN_BOOL, true);
sDefaults.putInt(KEY_SATELLITE_DATA_SUPPORT_MODE_INT, CarrierConfigManager.SATELLITE_DATA_SUPPORT_ONLY_RESTRICTED)11422         sDefaults.putInt(KEY_SATELLITE_DATA_SUPPORT_MODE_INT,
11423                 CarrierConfigManager.SATELLITE_DATA_SUPPORT_ONLY_RESTRICTED);
sDefaults.putBoolean(KEY_SATELLITE_IGNORE_DATA_ROAMING_SETTING_BOOL, false)11424         sDefaults.putBoolean(KEY_SATELLITE_IGNORE_DATA_ROAMING_SETTING_BOOL, false);
sDefaults.putBoolean(KEY_OVERRIDE_WFC_ROAMING_MODE_WHILE_USING_NTN_BOOL, true)11425         sDefaults.putBoolean(KEY_OVERRIDE_WFC_ROAMING_MODE_WHILE_USING_NTN_BOOL, true);
sDefaults.putInt(KEY_SATELLITE_ENTITLEMENT_STATUS_REFRESH_DAYS_INT, 7)11426         sDefaults.putInt(KEY_SATELLITE_ENTITLEMENT_STATUS_REFRESH_DAYS_INT, 7);
sDefaults.putBoolean(KEY_SATELLITE_ENTITLEMENT_SUPPORTED_BOOL, false)11427         sDefaults.putBoolean(KEY_SATELLITE_ENTITLEMENT_SUPPORTED_BOOL, false);
sDefaults.putString(KEY_SATELLITE_ENTITLEMENT_APP_NAME_STRING, "androidSatmode")11428         sDefaults.putString(KEY_SATELLITE_ENTITLEMENT_APP_NAME_STRING, "androidSatmode");
sDefaults.putString(KEY_SATELLITE_INFORMATION_REDIRECT_URL_STRING, "")11429         sDefaults.putString(KEY_SATELLITE_INFORMATION_REDIRECT_URL_STRING, "");
sDefaults.putIntArray(KEY_CARRIER_ROAMING_SATELLITE_DEFAULT_SERVICES_INT_ARRAY, new int[] { NetworkRegistrationInfo.SERVICE_TYPE_SMS, NetworkRegistrationInfo.SERVICE_TYPE_MMS })11430         sDefaults.putIntArray(KEY_CARRIER_ROAMING_SATELLITE_DEFAULT_SERVICES_INT_ARRAY,
11431                 new int[] {
11432                         NetworkRegistrationInfo.SERVICE_TYPE_SMS,
11433                         NetworkRegistrationInfo.SERVICE_TYPE_MMS
11434                 });
sDefaults.putStringArray(KEY_SATELLITE_SUPPORTED_MSG_APPS_STRING_ARRAY, new String[]{ "com.google.android.apps.messaging"})11435         sDefaults.putStringArray(KEY_SATELLITE_SUPPORTED_MSG_APPS_STRING_ARRAY, new String[]{
11436                 "com.google.android.apps.messaging"});
sDefaults.putBoolean(KEY_DISABLE_DUN_APN_WHILE_ROAMING_WITH_PRESET_APN_BOOL, false)11437         sDefaults.putBoolean(KEY_DISABLE_DUN_APN_WHILE_ROAMING_WITH_PRESET_APN_BOOL, false);
sDefaults.putBoolean(KEY_EMERGENCY_MESSAGING_SUPPORTED_BOOL, false)11438         sDefaults.putBoolean(KEY_EMERGENCY_MESSAGING_SUPPORTED_BOOL, false);
sDefaults.putInt(KEY_EMERGENCY_CALL_TO_SATELLITE_T911_HANDOVER_TIMEOUT_MILLIS_INT, (int) TimeUnit.SECONDS.toMillis(30))11439         sDefaults.putInt(KEY_EMERGENCY_CALL_TO_SATELLITE_T911_HANDOVER_TIMEOUT_MILLIS_INT,
11440                 (int) TimeUnit.SECONDS.toMillis(30));
sDefaults.putString(KEY_SATELLITE_DISPLAY_NAME_STRING, "")11441         sDefaults.putString(KEY_SATELLITE_DISPLAY_NAME_STRING, "");
sDefaults.putBoolean(KEY_SATELLITE_ESOS_SUPPORTED_BOOL, false)11442         sDefaults.putBoolean(KEY_SATELLITE_ESOS_SUPPORTED_BOOL, false);
sDefaults.putBoolean(KEY_SATELLITE_ROAMING_P2P_SMS_SUPPORTED_BOOL, false)11443         sDefaults.putBoolean(KEY_SATELLITE_ROAMING_P2P_SMS_SUPPORTED_BOOL, false);
sDefaults.putString(KEY_SATELLITE_NIDD_APN_NAME_STRING, "")11444         sDefaults.putString(KEY_SATELLITE_NIDD_APN_NAME_STRING, "");
sDefaults.putBoolean(KEY_SATELLITE_ROAMING_TURN_OFF_SESSION_FOR_EMERGENCY_CALL_BOOL, true)11445         sDefaults.putBoolean(KEY_SATELLITE_ROAMING_TURN_OFF_SESSION_FOR_EMERGENCY_CALL_BOOL, true);
sDefaults.putInt(KEY_CARRIER_ROAMING_NTN_CONNECT_TYPE_INT, 0)11446         sDefaults.putInt(KEY_CARRIER_ROAMING_NTN_CONNECT_TYPE_INT, 0);
sDefaults.putInt(KEY_CARRIER_ROAMING_NTN_EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_INT, SatelliteManager.EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_T911)11447         sDefaults.putInt(KEY_CARRIER_ROAMING_NTN_EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_INT,
11448                 SatelliteManager.EMERGENCY_CALL_TO_SATELLITE_HANDOVER_TYPE_T911);
sDefaults.putInt(KEY_CARRIER_SUPPORTED_SATELLITE_NOTIFICATION_HYSTERESIS_SEC_INT, 180)11449         sDefaults.putInt(KEY_CARRIER_SUPPORTED_SATELLITE_NOTIFICATION_HYSTERESIS_SEC_INT, 180);
11450         if (Flags.starlinkDataBugfix()) {
sDefaults.putLong(KEY_SATELLITE_CONNECTED_NOTIFICATION_THROTTLE_MILLIS_INT, TimeUnit.DAYS.toMillis(7))11451             sDefaults.putLong(KEY_SATELLITE_CONNECTED_NOTIFICATION_THROTTLE_MILLIS_INT,
11452                     TimeUnit.DAYS.toMillis(7));
11453         }
sDefaults.putInt(KEY_SATELLITE_ROAMING_SCREEN_OFF_INACTIVITY_TIMEOUT_SEC_INT, 30)11454         sDefaults.putInt(KEY_SATELLITE_ROAMING_SCREEN_OFF_INACTIVITY_TIMEOUT_SEC_INT, 30);
sDefaults.putInt(KEY_SATELLITE_ROAMING_P2P_SMS_INACTIVITY_TIMEOUT_SEC_INT, 180)11455         sDefaults.putInt(KEY_SATELLITE_ROAMING_P2P_SMS_INACTIVITY_TIMEOUT_SEC_INT, 180);
sDefaults.putInt(KEY_SATELLITE_ROAMING_ESOS_INACTIVITY_TIMEOUT_SEC_INT, 600)11456         sDefaults.putInt(KEY_SATELLITE_ROAMING_ESOS_INACTIVITY_TIMEOUT_SEC_INT, 600);
sDefaults.putString(KEY_DEFAULT_PREFERRED_APN_NAME_STRING, "")11457         sDefaults.putString(KEY_DEFAULT_PREFERRED_APN_NAME_STRING, "");
sDefaults.putBoolean(KEY_SUPPORTS_CALL_COMPOSER_BOOL, false)11458         sDefaults.putBoolean(KEY_SUPPORTS_CALL_COMPOSER_BOOL, false);
sDefaults.putBoolean(KEY_SUPPORTS_BUSINESS_CALL_COMPOSER_BOOL, false)11459         sDefaults.putBoolean(KEY_SUPPORTS_BUSINESS_CALL_COMPOSER_BOOL, false);
sDefaults.putString(KEY_CALL_COMPOSER_PICTURE_SERVER_URL_STRING, "")11460         sDefaults.putString(KEY_CALL_COMPOSER_PICTURE_SERVER_URL_STRING, "");
sDefaults.putBoolean(KEY_USE_ACS_FOR_RCS_BOOL, false)11461         sDefaults.putBoolean(KEY_USE_ACS_FOR_RCS_BOOL, false);
sDefaults.putBoolean(KEY_NETWORK_TEMP_NOT_METERED_SUPPORTED_BOOL, true)11462         sDefaults.putBoolean(KEY_NETWORK_TEMP_NOT_METERED_SUPPORTED_BOOL, true);
sDefaults.putInt(KEY_DEFAULT_RTT_MODE_INT, 0)11463         sDefaults.putInt(KEY_DEFAULT_RTT_MODE_INT, 0);
sDefaults.putBoolean(KEY_STORE_SIM_PIN_FOR_UNATTENDED_REBOOT_BOOL, true)11464         sDefaults.putBoolean(KEY_STORE_SIM_PIN_FOR_UNATTENDED_REBOOT_BOOL, true);
sDefaults.putBoolean(KEY_HIDE_ENABLE_2G, false)11465         sDefaults.putBoolean(KEY_HIDE_ENABLE_2G, false);
sDefaults.putStringArray(KEY_ALLOWED_INITIAL_ATTACH_APN_TYPES_STRING_ARRAY, new String[]{"ia", "default"})11466         sDefaults.putStringArray(KEY_ALLOWED_INITIAL_ATTACH_APN_TYPES_STRING_ARRAY,
11467                 new String[]{"ia", "default"});
sDefaults.putBoolean(KEY_CARRIER_PROVISIONS_WIFI_MERGED_NETWORKS_BOOL, false)11468         sDefaults.putBoolean(KEY_CARRIER_PROVISIONS_WIFI_MERGED_NETWORKS_BOOL, false);
sDefaults.putBoolean(KEY_USE_IP_FOR_CALLING_INDICATOR_BOOL, false)11469         sDefaults.putBoolean(KEY_USE_IP_FOR_CALLING_INDICATOR_BOOL, false);
sDefaults.putBoolean(KEY_DISPLAY_CALL_STRENGTH_INDICATOR_BOOL, true)11470         sDefaults.putBoolean(KEY_DISPLAY_CALL_STRENGTH_INDICATOR_BOOL, true);
sDefaults.putString(KEY_CARRIER_PROVISIONING_APP_STRING, "")11471         sDefaults.putString(KEY_CARRIER_PROVISIONING_APP_STRING, "");
sDefaults.putBoolean(KEY_DISPLAY_NO_DATA_NOTIFICATION_ON_PERMANENT_FAILURE_BOOL, false)11472         sDefaults.putBoolean(KEY_DISPLAY_NO_DATA_NOTIFICATION_ON_PERMANENT_FAILURE_BOOL, false);
sDefaults.putBoolean(KEY_UNTHROTTLE_DATA_RETRY_WHEN_TAC_CHANGES_BOOL, false)11473         sDefaults.putBoolean(KEY_UNTHROTTLE_DATA_RETRY_WHEN_TAC_CHANGES_BOOL, false);
sDefaults.putBoolean(KEY_VONR_SETTING_VISIBILITY_BOOL, true)11474         sDefaults.putBoolean(KEY_VONR_SETTING_VISIBILITY_BOOL, true);
sDefaults.putBoolean(KEY_VONR_ENABLED_BOOL, false)11475         sDefaults.putBoolean(KEY_VONR_ENABLED_BOOL, false);
sDefaults.putBoolean(KEY_VONR_ON_BY_DEFAULT_BOOL, true)11476         sDefaults.putBoolean(KEY_VONR_ON_BY_DEFAULT_BOOL, true);
sDefaults.putIntArray(KEY_SUPPORTED_PREMIUM_CAPABILITIES_INT_ARRAY, new int[0])11477         sDefaults.putIntArray(KEY_SUPPORTED_PREMIUM_CAPABILITIES_INT_ARRAY, new int[0]);
sDefaults.putLong(KEY_PREMIUM_CAPABILITY_NOTIFICATION_DISPLAY_TIMEOUT_MILLIS_LONG, TimeUnit.MINUTES.toMillis(30))11478         sDefaults.putLong(KEY_PREMIUM_CAPABILITY_NOTIFICATION_DISPLAY_TIMEOUT_MILLIS_LONG,
11479                 TimeUnit.MINUTES.toMillis(30));
sDefaults.putLong(KEY_PREMIUM_CAPABILITY_NOTIFICATION_BACKOFF_HYSTERESIS_TIME_MILLIS_LONG, TimeUnit.MINUTES.toMillis(30))11480         sDefaults.putLong(KEY_PREMIUM_CAPABILITY_NOTIFICATION_BACKOFF_HYSTERESIS_TIME_MILLIS_LONG,
11481                 TimeUnit.MINUTES.toMillis(30));
sDefaults.putInt(KEY_PREMIUM_CAPABILITY_MAXIMUM_DAILY_NOTIFICATION_COUNT_INT, 2)11482         sDefaults.putInt(KEY_PREMIUM_CAPABILITY_MAXIMUM_DAILY_NOTIFICATION_COUNT_INT, 2);
sDefaults.putInt(KEY_PREMIUM_CAPABILITY_MAXIMUM_MONTHLY_NOTIFICATION_COUNT_INT, 10)11483         sDefaults.putInt(KEY_PREMIUM_CAPABILITY_MAXIMUM_MONTHLY_NOTIFICATION_COUNT_INT, 10);
sDefaults.putLong( KEY_PREMIUM_CAPABILITY_PURCHASE_CONDITION_BACKOFF_HYSTERESIS_TIME_MILLIS_LONG, TimeUnit.MINUTES.toMillis(30))11484         sDefaults.putLong(
11485                 KEY_PREMIUM_CAPABILITY_PURCHASE_CONDITION_BACKOFF_HYSTERESIS_TIME_MILLIS_LONG,
11486                 TimeUnit.MINUTES.toMillis(30));
sDefaults.putLong(KEY_PREMIUM_CAPABILITY_NETWORK_SETUP_TIME_MILLIS_LONG, TimeUnit.MINUTES.toMillis(5))11487         sDefaults.putLong(KEY_PREMIUM_CAPABILITY_NETWORK_SETUP_TIME_MILLIS_LONG,
11488                 TimeUnit.MINUTES.toMillis(5));
sDefaults.putString(KEY_PREMIUM_CAPABILITY_PURCHASE_URL_STRING, null)11489         sDefaults.putString(KEY_PREMIUM_CAPABILITY_PURCHASE_URL_STRING, null);
sDefaults.putBoolean(KEY_PREMIUM_CAPABILITY_SUPPORTED_ON_LTE_BOOL, false)11490         sDefaults.putBoolean(KEY_PREMIUM_CAPABILITY_SUPPORTED_ON_LTE_BOOL, false);
sDefaults.putStringArray(KEY_IWLAN_HANDOVER_POLICY_STRING_ARRAY, new String[]{ "source=GERAN|UTRAN|EUTRAN|NGRAN|IWLAN, " + "target=GERAN|UTRAN|EUTRAN|NGRAN|IWLAN, type=allowed"})11491         sDefaults.putStringArray(KEY_IWLAN_HANDOVER_POLICY_STRING_ARRAY, new String[]{
11492                 "source=GERAN|UTRAN|EUTRAN|NGRAN|IWLAN, "
11493                         + "target=GERAN|UTRAN|EUTRAN|NGRAN|IWLAN, type=allowed"});
11494         PersistableBundle auto_data_switch_rat_signal_score_string_bundle = new PersistableBundle();
11495         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11496                 "NR_SA_MMWAVE", new int[]{6300, 10227, 16000, 18488, 19017});
11497         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11498                 "NR_NSA_MMWAVE", new int[]{5700, 9227, 12488, 13517, 15978});
11499         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11500                 "LTE", new int[]{3731, 5965, 8618, 11179, 13384});
11501         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11502                 "LTE_CA", new int[]{3831, 6065, 8718, 11379, 14484});
11503         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11504                 "NR_SA", new int[]{2288, 6795, 6955, 7562, 15484});
11505         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11506                 "NR_NSA", new int[]{2463, 6827, 8029, 9007, 15884});
11507         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11508                 "UMTS", new int[]{100, 169, 183, 192, 300});
11509         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11510                 "eHRPD", new int[]{10, 400, 600, 800, 1000});
11511         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11512                 "TD_SCDMA", new int[]{1, 50, 100, 500, 1000});
11513         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11514                 "iDEN", new int[]{1, 2, 10, 50, 100});
11515         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11516                 "EvDo_B", new int[]{1000, 1495, 2186, 2532, 2600});
11517         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11518                 "HSPA+", new int[]{1619, 2500, 3393, 4129, 4212});
11519         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11520                 "HSPA", new int[]{1000, 1495, 2186, 2532, 2544});
11521         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11522                 "HSUPA", new int[]{1500, 1919, 2132, 2362, 2704});
11523         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11524                 "HSDPA", new int[]{1500, 1732, 4000, 7000, 8000});
11525         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11526                 "EvDo_A", new int[]{600, 840, 1200, 1300, 1400});
11527         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11528                 "EvDo_0", new int[]{300, 600, 1000, 1500, 2000});
11529         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11530                 "1xRTT", new int[]{50, 60, 70, 80, 90});
11531         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11532                 "EDGE", new int[]{154, 169, 183, 192, 267});
11533         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11534                 "GPRS", new int[]{15, 30, 40, 45, 50});
11535         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11536                 "CDMA", new int[]{1, 50, 100, 300, 2000});
11537         auto_data_switch_rat_signal_score_string_bundle.putIntArray(
11538                 "GSM", new int[]{1, 2, 10, 50, 100});
sDefaults.putPersistableBundle(KEY_AUTO_DATA_SWITCH_RAT_SIGNAL_SCORE_BUNDLE, auto_data_switch_rat_signal_score_string_bundle)11539         sDefaults.putPersistableBundle(KEY_AUTO_DATA_SWITCH_RAT_SIGNAL_SCORE_BUNDLE,
11540                 auto_data_switch_rat_signal_score_string_bundle);
sDefaults.putInt(KEY_CELLULAR_USAGE_SETTING_INT, SubscriptionManager.USAGE_SETTING_UNKNOWN)11541         sDefaults.putInt(KEY_CELLULAR_USAGE_SETTING_INT,
11542                 SubscriptionManager.USAGE_SETTING_UNKNOWN);
11543         // Default data stall recovery configurations.
sDefaults.putLongArray(KEY_DATA_STALL_RECOVERY_TIMERS_LONG_ARRAY, new long[] {180000, 180000, 180000, 180000})11544         sDefaults.putLongArray(KEY_DATA_STALL_RECOVERY_TIMERS_LONG_ARRAY,
11545                 new long[] {180000, 180000, 180000, 180000});
sDefaults.putBooleanArray(KEY_DATA_STALL_RECOVERY_SHOULD_SKIP_BOOL_ARRAY, new boolean[] {false, false, true, false, false})11546         sDefaults.putBooleanArray(KEY_DATA_STALL_RECOVERY_SHOULD_SKIP_BOOL_ARRAY,
11547                 new boolean[] {false, false, true, false, false});
sDefaults.putStringArray(KEY_CARRIER_SERVICE_NAME_STRING_ARRAY, new String[0])11548         sDefaults.putStringArray(KEY_CARRIER_SERVICE_NAME_STRING_ARRAY, new String[0]);
sDefaults.putStringArray(KEY_CARRIER_SERVICE_NUMBER_STRING_ARRAY, new String[0])11549         sDefaults.putStringArray(KEY_CARRIER_SERVICE_NUMBER_STRING_ARRAY, new String[0]);
sDefaults.putIntArray(KEY_CELLULAR_SERVICE_CAPABILITIES_INT_ARRAY, new int[]{1, 2, 3})11550         sDefaults.putIntArray(KEY_CELLULAR_SERVICE_CAPABILITIES_INT_ARRAY, new int[]{1, 2, 3});
sDefaults.putInt(KEY_WEAR_CONNECTIVITY_BT_TO_CELL_DELAY_MS_INT, -1)11551         sDefaults.putInt(KEY_WEAR_CONNECTIVITY_BT_TO_CELL_DELAY_MS_INT, -1);
sDefaults.putInt(KEY_WEAR_CONNECTIVITY_EXTEND_BT_TO_CELL_DELAY_ON_WIFI_MS_INT, -1)11552         sDefaults.putInt(KEY_WEAR_CONNECTIVITY_EXTEND_BT_TO_CELL_DELAY_ON_WIFI_MS_INT, -1);
sDefaults.putInt(KEY_SATELLITE_SOS_MAX_DATAGRAM_SIZE_BYTES_INT, 255)11553         sDefaults.putInt(KEY_SATELLITE_SOS_MAX_DATAGRAM_SIZE_BYTES_INT, 255);
11554     }
11555 
11556     /**
11557      * Wi-Fi configs used in WiFi Module.
11558      *
11559      * @hide
11560      */
11561     @SystemApi
11562     public static final class Wifi {
11563         /** Prefix of all Wifi.KEY_* constants. */
11564         public static final String KEY_PREFIX = "wifi.";
11565         /**
11566         * It contains the maximum client count definition that the carrier sets.
11567         * The default is 0, which means that the carrier hasn't set a requirement.
11568         */
11569         public static final String KEY_HOTSPOT_MAX_CLIENT_COUNT =
11570                 KEY_PREFIX + "hotspot_maximum_client_count";
11571 
11572         /**
11573          * This configuration is intended to be a narrow exception for provisioning
11574          * {@link android.net.wifi.WifiNetworkSuggestion} of widely-known carrier networks that do
11575          * not support using randomized MAC address.
11576          * Carrier provisioned {@link android.net.wifi.WifiNetworkSuggestion} with SSIDs included
11577          * in this list will have MAC randomization disabled.
11578          *
11579          * Note: the SSIDs in the list are expected to be interpreted as is - do not add double
11580          * quotes to the SSIDs.
11581          */
11582         public static final String KEY_SUGGESTION_SSID_LIST_WITH_MAC_RANDOMIZATION_DISABLED =
11583                 KEY_PREFIX + "suggestion_ssid_list_with_mac_randomization_disabled";
11584 
11585         /**
11586          * Avoid SoftAp in 5GHz if cellular is on unlicensed 5Ghz using License Assisted Access
11587          * (LAA).
11588          */
11589         public static final String KEY_AVOID_5GHZ_SOFTAP_FOR_LAA_BOOL =
11590                 KEY_PREFIX + "avoid_5ghz_softap_for_laa_bool";
11591 
11592         /**
11593          * Avoid Wifi Direct in 5GHz if cellular is on unlicensed 5Ghz using License Assisted
11594          * Access (LAA).
11595          */
11596         public static final String KEY_AVOID_5GHZ_WIFI_DIRECT_FOR_LAA_BOOL =
11597                 KEY_PREFIX + "avoid_5ghz_wifi_direct_for_laa_bool";
11598 
getDefaults()11599         private static PersistableBundle getDefaults() {
11600             PersistableBundle defaults = new PersistableBundle();
11601             defaults.putInt(KEY_HOTSPOT_MAX_CLIENT_COUNT, 0);
11602             defaults.putStringArray(KEY_SUGGESTION_SSID_LIST_WITH_MAC_RANDOMIZATION_DISABLED,
11603                     new String[0]);
11604             defaults.putBoolean(KEY_AVOID_5GHZ_SOFTAP_FOR_LAA_BOOL, false);
11605             defaults.putBoolean(KEY_AVOID_5GHZ_WIFI_DIRECT_FOR_LAA_BOOL, false);
11606 
11607             return defaults;
11608         }
11609 
Wifi()11610         private Wifi() {}
11611     }
11612 
11613     /**
11614      * Gets the configuration values for a particular subscription, which is associated with a
11615      * specific SIM card. If an invalid subId is used, the returned config will contain default
11616      * values. After using this method to get the configuration bundle,
11617      * {@link #isConfigForIdentifiedCarrier(PersistableBundle)} should be called to confirm whether
11618      * any carrier specific configuration has been applied.
11619      *
11620      * <p>Requires Permission:
11621      * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}, or the calling app
11622      * has carrier privileges (see {@link TelephonyManager#hasCarrierPrivileges()}).
11623      *
11624      * @param subId the subscription ID, normally obtained from {@link SubscriptionManager}.
11625      * @return A {@link PersistableBundle} containing the config for the given subId, or default
11626      *         values for an invalid subId.
11627      *
11628      * @throws UnsupportedOperationException If the device does not have
11629      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11630      *
11631      * @deprecated Use {@link #getConfigForSubId(int, String...)} instead.
11632      */
11633     @SuppressAutoDoc // Blocked by b/72967236 - no support for carrier privileges
11634     @RequiresPermission(Manifest.permission.READ_PHONE_STATE)
11635     @Nullable
11636     @Deprecated
getConfigForSubId(int subId)11637     public PersistableBundle getConfigForSubId(int subId) {
11638         try {
11639             ICarrierConfigLoader loader = getICarrierConfigLoader();
11640             if (loader == null) {
11641                 Rlog.w(TAG, "Error getting config for subId " + subId
11642                         + " ICarrierConfigLoader is null");
11643                 return null;
11644             }
11645             return loader.getConfigForSubIdWithFeature(subId, mContext.getOpPackageName(),
11646                     mContext.getAttributionTag());
11647         } catch (RemoteException ex) {
11648             Rlog.e(TAG, "Error getting config for subId " + subId + ": " + ex);
11649         }
11650         return null;
11651     }
11652 
11653     /**
11654      * Gets the configuration values of the specified keys for a particular subscription.
11655      *
11656      * <p>If an invalid subId is used, the returned configuration will contain default values for
11657      * the specified keys. If the value for the key can't be found, the returned configuration will
11658      * filter the key out.
11659      *
11660      * <p>After using this method to get the configuration bundle,
11661      * {@link #isConfigForIdentifiedCarrier(PersistableBundle)} should be called to confirm whether
11662      * any carrier specific configuration has been applied.
11663      *
11664      * <p>Note that on success, the key/value for {@link #KEY_CARRIER_CONFIG_VERSION_STRING} and
11665      * {@link #KEY_CARRIER_CONFIG_APPLIED_BOOL} are always in the returned bundle, no matter if they
11666      * were explicitly requested.
11667      *
11668      * <p>Requires Permission:
11669      * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}, or the calling app
11670      * has carrier privileges on the specified subscription (see
11671      * {@link TelephonyManager#hasCarrierPrivileges()}).
11672      *
11673      * @param subId The subscription ID on which the carrier config should be retrieved.
11674      * @param keys The carrier config keys to retrieve values.
11675      * @return A {@link PersistableBundle} with key/value mapping for the specified configuration
11676      * on success, or an empty (but never null) bundle on failure (for example, when the calling app
11677      * has no permission).
11678      *
11679      * @throws UnsupportedOperationException If the device does not have
11680      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11681      */
11682     @RequiresPermission(anyOf = {
11683             Manifest.permission.READ_PHONE_STATE,
11684             "carrier privileges",
11685     })
11686     @NonNull
getConfigForSubId(int subId, @NonNull String... keys)11687     public PersistableBundle getConfigForSubId(int subId, @NonNull String... keys) {
11688         Objects.requireNonNull(keys, "Config keys should be non-null");
11689         for (String key : keys) {
11690             Objects.requireNonNull(key, "Config key should be non-null");
11691         }
11692 
11693         try {
11694             ICarrierConfigLoader loader = getICarrierConfigLoader();
11695             if (loader == null) {
11696                 Rlog.w(TAG, "Error getting config for subId " + subId
11697                         + " ICarrierConfigLoader is null");
11698                 throw new IllegalStateException("Carrier config loader is not available.");
11699             }
11700             return loader.getConfigSubsetForSubIdWithFeature(subId, mContext.getOpPackageName(),
11701                     mContext.getAttributionTag(), keys);
11702         } catch (RemoteException ex) {
11703             Rlog.e(TAG, "Error getting config for subId " + subId + ": " + ex);
11704             ex.rethrowAsRuntimeException();
11705         }
11706         return new PersistableBundle();
11707     }
11708 
11709     /**
11710      * Overrides the carrier config of the provided subscription ID with the provided values.
11711      *
11712      * Any further queries to carrier config from any process will return the overridden values
11713      * after this method returns. The overrides are effective for the lifetime of the phone process
11714      * until the user passes in {@code null} for {@code overrideValues}. This removes all previous
11715      * overrides and sets the carrier config back to production values.
11716      *
11717      * May throw an {@link IllegalArgumentException} if {@code overrideValues} contains invalid
11718      * values for the specified config keys.
11719      *
11720      * NOTE: This API is meant for testing purposes only.
11721      *
11722      * @param subscriptionId The subscription ID for which the override should be done.
11723      * @param overrideValues Key-value pairs of the values that are to be overridden. If set to
11724      *                       {@code null}, this will remove all previous overrides and set the
11725      *                       carrier configuration back to production values.
11726      *
11727      * @throws UnsupportedOperationException If the device does not have
11728      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11729      * @hide
11730      */
11731     @RequiresPermission(Manifest.permission.MODIFY_PHONE_STATE)
11732     @SystemApi
overrideConfig(int subscriptionId, @Nullable PersistableBundle overrideValues)11733     public void overrideConfig(int subscriptionId, @Nullable PersistableBundle overrideValues) {
11734         overrideConfig(subscriptionId, overrideValues, false);
11735     }
11736 
11737     /**
11738      * Overrides the carrier config of the provided subscription ID with the provided values.
11739      *
11740      * Any further queries to carrier config from any process will return the overridden values
11741      * after this method returns. The overrides are effective until the user passes in {@code null}
11742      * for {@code overrideValues}. This removes all previous overrides and sets the carrier config
11743      * back to production values.
11744      *
11745      * The overrides is stored persistently and will survive a reboot if {@code persistent} is true.
11746      *
11747      * May throw an {@link IllegalArgumentException} if {@code overrideValues} contains invalid
11748      * values for the specified config keys.
11749      *
11750      * NOTE: This API is meant for testing purposes only.
11751      *
11752      * @param subscriptionId The subscription ID for which the override should be done.
11753      * @param overrideValues Key-value pairs of the values that are to be overridden. If set to
11754      *                       {@code null}, this will remove all previous overrides and set the
11755      *                       carrier configuration back to production values.
11756      * @param persistent     Determines whether the override should be persistent.
11757      * @hide
11758      */
11759     @RequiresPermission(Manifest.permission.MODIFY_PHONE_STATE)
overrideConfig(int subscriptionId, @Nullable PersistableBundle overrideValues, boolean persistent)11760     public void overrideConfig(int subscriptionId, @Nullable PersistableBundle overrideValues,
11761             boolean persistent) {
11762         try {
11763             ICarrierConfigLoader loader = getICarrierConfigLoader();
11764             if (loader == null) {
11765                 Rlog.w(TAG, "Error setting config for subId " + subscriptionId
11766                         + " ICarrierConfigLoader is null");
11767                 return;
11768             }
11769             loader.overrideConfig(subscriptionId, overrideValues, persistent);
11770         } catch (RemoteException ex) {
11771             Rlog.e(TAG, "Error setting config for subId " + subscriptionId + ": " + ex);
11772         }
11773     }
11774 
11775     /**
11776      * Gets the configuration values for the default subscription. After using this method to get
11777      * the configuration bundle, {@link #isConfigForIdentifiedCarrier(PersistableBundle)} should be
11778      * called to confirm whether any carrier specific configuration has been applied.
11779      *
11780      * <p>Requires Permission:
11781      * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}, or the calling app
11782      * has carrier privileges (see {@link TelephonyManager#hasCarrierPrivileges()}).
11783      *
11784      * @see #getConfigForSubId
11785      * @see #getConfig(String...)
11786      *
11787      * @throws UnsupportedOperationException If the device does not have
11788      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11789      *
11790      * @deprecated use {@link #getConfig(String...)} instead.
11791      */
11792     @SuppressAutoDoc // Blocked by b/72967236 - no support for carrier privileges
11793     @RequiresPermission(Manifest.permission.READ_PHONE_STATE)
11794     @Nullable
11795     @Deprecated
getConfig()11796     public PersistableBundle getConfig() {
11797         return getConfigForSubId(SubscriptionManager.getDefaultSubscriptionId());
11798     }
11799 
11800     /**
11801      * Gets the configuration values of the specified config keys applied for the default
11802      * subscription.
11803      *
11804      * <p>If the value for the key can't be found, the returned bundle will filter the key out.
11805      *
11806      * <p>After using this method to get the configuration bundle, {@link
11807      * #isConfigForIdentifiedCarrier(PersistableBundle)} should be called to confirm whether any
11808      * carrier specific configuration has been applied.
11809      *
11810      * <p>Note that on success, the key/value for {@link #KEY_CARRIER_CONFIG_VERSION_STRING} and
11811      * {@link #KEY_CARRIER_CONFIG_APPLIED_BOOL} are always in the returned bundle, no matter if
11812      * they were explicitly requested.
11813      *
11814      * <p>Requires Permission:
11815      * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}, or the calling app
11816      * has carrier privileges for the default subscription (see
11817      * {@link TelephonyManager#hasCarrierPrivileges()}).
11818      *
11819      * @param keys The config keys to retrieve values
11820      * @return A {@link PersistableBundle} with key/value mapping for the specified carrier
11821      * configs on success, or an empty (but never null) bundle on failure.
11822      * @see #getConfigForSubId(int, String...)
11823      * @see SubscriptionManager#getDefaultSubscriptionId()
11824      *
11825      * @throws UnsupportedOperationException If the device does not have
11826      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11827      */
11828     @RequiresPermission(anyOf = {
11829             Manifest.permission.READ_PHONE_STATE,
11830             "carrier privileges",
11831     })
11832     @NonNull
getConfig(@onNull String... keys)11833     public PersistableBundle getConfig(@NonNull String... keys) {
11834         return getConfigForSubId(SubscriptionManager.getDefaultSubscriptionId(), keys);
11835     }
11836 
11837     /**
11838      * Determines whether a configuration {@link PersistableBundle} obtained from
11839      * {@link #getConfig()} or {@link #getConfigForSubId(int)} corresponds to an identified carrier.
11840      *
11841      * <p>When an app receives the {@link CarrierConfigManager#ACTION_CARRIER_CONFIG_CHANGED}
11842      * broadcast which informs it that the carrier configuration has changed, it is possible
11843      * that another reload of the carrier configuration has begun since the intent was sent.
11844      * In this case, the carrier configuration the app fetches (e.g. via {@link #getConfig()})
11845      * may not represent the configuration for the current carrier. It should be noted that it
11846      * does not necessarily mean the configuration belongs to current carrier when this function
11847      * return true because it may belong to another previous identified carrier. Users should
11848      * always call {@link #getConfig()} or {@link #getConfigForSubId(int)} after receiving the
11849      * broadcast {@link #ACTION_CARRIER_CONFIG_CHANGED}.
11850      *
11851      * <p>After using {@link #getConfig()} or {@link #getConfigForSubId(int)} an app should always
11852      * use this method to confirm whether any carrier specific configuration has been applied.
11853      * Especially when an app misses the broadcast {@link #ACTION_CARRIER_CONFIG_CHANGED} but it
11854      * still needs to get the current configuration, it must use this method to verify whether the
11855      * configuration is default or carrier overridden.
11856      *
11857      * @param bundle the configuration bundle to be checked.
11858      * @return boolean true if any carrier specific configuration bundle has been applied, false
11859      * otherwise or the bundle is null.
11860      */
isConfigForIdentifiedCarrier(PersistableBundle bundle)11861     public static boolean isConfigForIdentifiedCarrier(PersistableBundle bundle) {
11862         return bundle != null && bundle.getBoolean(KEY_CARRIER_CONFIG_APPLIED_BOOL);
11863     }
11864 
11865     /**
11866      * Calling this method triggers telephony services to fetch the current carrier configuration.
11867      *
11868      * <p>Normally this does not need to be called because the platform reloads config on its own.
11869      * This should be called by a carrier service app if it wants to update config at an arbitrary
11870      * moment.
11871      *
11872      * <p>Requires Permission:
11873      * {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}, or the calling app
11874      * has carrier privileges (see {@link TelephonyManager#hasCarrierPrivileges()}).
11875      *
11876      * <p>This method returns before the reload has completed, and {@link
11877      * android.service.carrier.CarrierService#onLoadConfig} will be called from an arbitrary thread.
11878      *
11879      * @throws UnsupportedOperationException If the device does not have
11880      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11881      */
11882     @SuppressAutoDoc // Blocked by b/72967236 - no support for carrier privileges
11883     @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE)
notifyConfigChangedForSubId(int subId)11884     public void notifyConfigChangedForSubId(int subId) {
11885         try {
11886             ICarrierConfigLoader loader = getICarrierConfigLoader();
11887             if (loader == null) {
11888                 Rlog.w(TAG, "Error reloading config for subId=" + subId
11889                         + " ICarrierConfigLoader is null");
11890                 return;
11891             }
11892             loader.notifyConfigChangedForSubId(subId);
11893         } catch (RemoteException ex) {
11894             Rlog.e(TAG, "Error reloading config for subId=" + subId + ": " + ex);
11895         }
11896     }
11897 
11898     /**
11899      * Request the carrier config loader to update the config for phoneId.
11900      *
11901      * <p>Depending on simState, the config may be cleared or loaded from config app. This is only
11902      * used by SubscriptionInfoUpdater.
11903      *
11904      * @throws UnsupportedOperationException If the device does not have
11905      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11906      * @hide
11907      */
11908     @SystemApi
11909     @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE)
updateConfigForPhoneId(int phoneId, String simState)11910     public void updateConfigForPhoneId(int phoneId, String simState) {
11911         try {
11912             ICarrierConfigLoader loader = getICarrierConfigLoader();
11913             if (loader == null) {
11914                 Rlog.w(TAG, "Error updating config for phoneId=" + phoneId
11915                         + " ICarrierConfigLoader is null");
11916                 return;
11917             }
11918             loader.updateConfigForPhoneId(phoneId, simState);
11919         } catch (RemoteException ex) {
11920             Rlog.e(TAG, "Error updating config for phoneId=" + phoneId + ": " + ex);
11921         }
11922     }
11923 
11924     /**
11925      * Gets the package name for a default carrier service.
11926      * @return the package name for a default carrier service; empty string if not available.
11927      *
11928      * @throws UnsupportedOperationException If the device does not have
11929      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11930      * @hide
11931      */
11932     @NonNull
11933     @SystemApi
11934     @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE)
getDefaultCarrierServicePackageName()11935     public String getDefaultCarrierServicePackageName() {
11936         try {
11937             ICarrierConfigLoader loader = getICarrierConfigLoader();
11938             if (loader == null) {
11939                 Rlog.w(TAG, "getDefaultCarrierServicePackageName ICarrierConfigLoader is null");
11940                 return "";
11941             }
11942             return loader.getDefaultCarrierServicePackageName();
11943         } catch (RemoteException ex) {
11944             Rlog.e(TAG, "getDefaultCarrierServicePackageName ICarrierConfigLoader is null" + ex);
11945             ex.rethrowAsRuntimeException();
11946         }
11947         return "";
11948     }
11949 
11950     /**
11951      * Returns a new bundle with the default value for every supported configuration variable.
11952      *
11953      * @hide
11954      */
11955     @NonNull
11956     @SystemApi
11957     @SuppressLint("RequiresPermission")
getDefaultConfig()11958     public static PersistableBundle getDefaultConfig() {
11959         return new PersistableBundle(sDefaults);
11960     }
11961 
11962     /** @hide */
11963     @Nullable
getICarrierConfigLoader()11964     private ICarrierConfigLoader getICarrierConfigLoader() {
11965         return ICarrierConfigLoader.Stub.asInterface(
11966                 TelephonyFrameworkInitializer
11967                         .getTelephonyServiceManager()
11968                         .getCarrierConfigServiceRegisterer()
11969                         .get());
11970     }
11971 
11972     /**
11973      * Gets the configuration values for a component using its prefix.
11974      *
11975      * <p>Requires Permission:
11976      * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}, or the calling app
11977      * has carrier privileges (see {@link TelephonyManager#hasCarrierPrivileges()}).
11978      *
11979      * @param prefix prefix of the component.
11980      * @param subId the subscription ID, normally obtained from {@link SubscriptionManager}.
11981      *
11982      * @see #getConfigForSubId
11983      *
11984      * @throws UnsupportedOperationException If the device does not have
11985      *          {@link PackageManager#FEATURE_TELEPHONY_SUBSCRIPTION}.
11986      */
11987     @SuppressAutoDoc // Blocked by b/72967236 - no support for carrier privileges
11988     @RequiresPermission(Manifest.permission.READ_PHONE_STATE)
11989     @Nullable
getConfigByComponentForSubId(@onNull String prefix, int subId)11990     public PersistableBundle getConfigByComponentForSubId(@NonNull String prefix, int subId) {
11991         PersistableBundle configs = getConfigForSubId(subId);
11992 
11993         if (configs == null) {
11994             return null;
11995         }
11996 
11997         PersistableBundle ret = new PersistableBundle();
11998         for (String configKey : configs.keySet()) {
11999             if (configKey.startsWith(prefix)) {
12000                 addConfig(configKey, configs.get(configKey), ret);
12001             }
12002         }
12003 
12004         return ret;
12005     }
12006 
addConfig(String key, Object value, PersistableBundle configs)12007     private void addConfig(String key, Object value, PersistableBundle configs) {
12008         if (value instanceof String) {
12009             configs.putString(key, (String) value);
12010         } else if (value instanceof String[]) {
12011             configs.putStringArray(key, (String[]) value);
12012         } else if (value instanceof Integer) {
12013             configs.putInt(key, (Integer) value);
12014         } else if (value instanceof Long) {
12015             configs.putLong(key, (Long) value);
12016         } else if (value instanceof Double) {
12017             configs.putDouble(key, (Double) value);
12018         } else if (value instanceof Boolean) {
12019             configs.putBoolean(key, (Boolean) value);
12020         } else if (value instanceof int[]) {
12021             configs.putIntArray(key, (int[]) value);
12022         } else if (value instanceof double[]) {
12023             configs.putDoubleArray(key, (double[]) value);
12024         } else if (value instanceof boolean[]) {
12025             configs.putBooleanArray(key, (boolean[]) value);
12026         } else if (value instanceof long[]) {
12027             configs.putLongArray(key, (long[]) value);
12028         } else if (value instanceof PersistableBundle) {
12029             configs.putPersistableBundle(key, (PersistableBundle) value);
12030         }
12031     }
12032 
12033     /**
12034      * Listener interface to get a notification when the carrier configurations have changed.
12035      *
12036      * Use this listener to receive timely updates when the carrier configuration changes. System
12037      * components should prefer this listener over {@link #ACTION_CARRIER_CONFIG_CHANGED}
12038      * whenever possible.
12039      *
12040      * To register the listener, call
12041      * {@link #registerCarrierConfigChangeListener(Executor, CarrierConfigChangeListener)}.
12042      * To unregister, call
12043      * {@link #unregisterCarrierConfigChangeListener(CarrierConfigChangeListener)}.
12044      *
12045      * Note that on registration, registrants will NOT receive a notification on last carrier config
12046      * change. Only carrier configs change AFTER the registration will be sent to registrants. And
12047      * unlike {@link #ACTION_CARRIER_CONFIG_CHANGED}, notification wouldn't send when the device is
12048      * unlocked. Registrants only receive the notification when there has been real carrier config
12049      * changes.
12050      *
12051      * @see #registerCarrierConfigChangeListener(Executor, CarrierConfigChangeListener)
12052      * @see #unregisterCarrierConfigChangeListener(CarrierConfigChangeListener)
12053      * @see #ACTION_CARRIER_CONFIG_CHANGED
12054      * @see #getConfig(String...)
12055      * @see #getConfigForSubId(int, String...)
12056      */
12057     public interface CarrierConfigChangeListener {
12058         /**
12059          * Called when carrier configurations have changed.
12060          *
12061          * @param logicalSlotIndex  The logical SIM slot index on which to monitor and get
12062          *                          notification. It is guaranteed to be valid.
12063          * @param subscriptionId    The subscription on the SIM slot. May be
12064          *                          {@link SubscriptionManager#INVALID_SUBSCRIPTION_ID}.
12065          * @param carrierId         The optional carrier Id, may be
12066          *                          {@link TelephonyManager#UNKNOWN_CARRIER_ID}.
12067          *                          See {@link TelephonyManager#getSimCarrierId()}.
12068          * @param specificCarrierId The optional fine-grained carrierId, may be {@link
12069          *                          TelephonyManager#UNKNOWN_CARRIER_ID}. A specific carrierId may
12070          *                          be different from the carrierId above in a MVNO scenario. See
12071          *                          detail in {@link TelephonyManager#getSimSpecificCarrierId()}.
12072          */
onCarrierConfigChanged(int logicalSlotIndex, int subscriptionId, int carrierId, int specificCarrierId)12073         void onCarrierConfigChanged(int logicalSlotIndex, int subscriptionId, int carrierId,
12074                 int specificCarrierId);
12075     }
12076 
12077     /**
12078      * Register a {@link CarrierConfigChangeListener} to get a notification when carrier
12079      * configurations have changed.
12080      *
12081      * @param executor The executor on which the listener will be called.
12082      * @param listener The CarrierConfigChangeListener called when carrier configs has changed.
12083      */
registerCarrierConfigChangeListener(@onNull @allbackExecutor Executor executor, @NonNull CarrierConfigChangeListener listener)12084     public void registerCarrierConfigChangeListener(@NonNull @CallbackExecutor Executor executor,
12085             @NonNull CarrierConfigChangeListener listener) {
12086         Objects.requireNonNull(executor, "Executor should be non-null.");
12087         Objects.requireNonNull(listener, "Listener should be non-null.");
12088 
12089         TelephonyRegistryManager trm = mContext.getSystemService(TelephonyRegistryManager.class);
12090         if (trm == null) {
12091             throw new IllegalStateException("Telephony registry service is null");
12092         }
12093         trm.addCarrierConfigChangedListener(executor, listener);
12094     }
12095 
12096     /**
12097      * Unregister the {@link CarrierConfigChangeListener} to stop notification on carrier
12098      * configurations change.
12099      *
12100      * @param listener The CarrierConfigChangeListener which was registered with method
12101      * {@link #registerCarrierConfigChangeListener(Executor, CarrierConfigChangeListener)}.
12102      */
unregisterCarrierConfigChangeListener( @onNull CarrierConfigChangeListener listener)12103     public void unregisterCarrierConfigChangeListener(
12104             @NonNull CarrierConfigChangeListener listener) {
12105         Objects.requireNonNull(listener, "Listener should be non-null.");
12106 
12107         TelephonyRegistryManager trm = mContext.getSystemService(TelephonyRegistryManager.class);
12108         if (trm == null) {
12109             throw new IllegalStateException("Telephony registry service is null");
12110         }
12111         trm.removeCarrierConfigChangedListener(listener);
12112     }
12113 
12114     /**
12115      * Get subset of specified carrier configuration if available or empty bundle, without throwing
12116      * {@link RuntimeException} to caller.
12117      *
12118      * <p>This is a system internally used only utility to reduce the repetitive logic.
12119      *
12120      * <p>Requires Permission:
12121      * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}, or the calling app
12122      * has carrier privileges on the specified subscription (see
12123      * {@link TelephonyManager#hasCarrierPrivileges()}).
12124      *
12125      * @param context Context used to get the CarrierConfigManager service.
12126      * @param subId The subscription ID to get the config from.
12127      * @param keys The config keys the client is interested in.
12128      * @return Config bundle with key/value for the specified keys or empty bundle when failed
12129      * @hide
12130      */
12131     @RequiresPermission(anyOf = {
12132             Manifest.permission.READ_PHONE_STATE,
12133             "carrier privileges",
12134     })
12135     @NonNull
getCarrierConfigSubset( @onNull Context context, int subId, @NonNull String... keys)12136     public static PersistableBundle getCarrierConfigSubset(
12137             @NonNull Context context, int subId, @NonNull String... keys) {
12138         PersistableBundle configs = null;
12139         CarrierConfigManager ccm = context.getSystemService(CarrierConfigManager.class);
12140         try {
12141             configs = ccm.getConfigForSubId(subId, keys);
12142         } catch (RuntimeException exception) {
12143             Rlog.w(TAG, "CarrierConfigLoader is not available.");
12144         }
12145         return configs != null ? configs : new PersistableBundle();
12146     }
12147 }
12148