diff --git a/core/api/current.txt b/core/api/current.txt index d9a83c926cf8d..759522cdbb5d5 100644 --- a/core/api/current.txt +++ b/core/api/current.txt @@ -32615,6 +32615,7 @@ package android.os { field public static final String DISALLOW_SHARING_ADMIN_CONFIGURED_WIFI = "no_sharing_admin_configured_wifi"; field public static final String DISALLOW_SMS = "no_sms"; field public static final String DISALLOW_SYSTEM_ERROR_DIALOGS = "no_system_error_dialogs"; + field public static final String DISALLOW_ULTRA_WIDEBAND_RADIO = "no_ultra_wideband_radio"; field public static final String DISALLOW_UNIFIED_PASSWORD = "no_unified_password"; field public static final String DISALLOW_UNINSTALL_APPS = "no_uninstall_apps"; field public static final String DISALLOW_UNMUTE_MICROPHONE = "no_unmute_microphone"; diff --git a/core/java/android/os/UserManager.java b/core/java/android/os/UserManager.java index 3d20d6373ae29..4a9afca6fd795 100644 --- a/core/java/android/os/UserManager.java +++ b/core/java/android/os/UserManager.java @@ -1505,6 +1505,30 @@ public class UserManager { */ public static final String DISALLOW_CELLULAR_2G = "no_cellular_2g"; + /** + * This user restriction specifies if Ultra-wideband is disallowed on the device. If + * Ultra-wideband is disallowed it cannot be turned on via Settings. + * + *
This restriction can only be set by a device owner or a profile owner of an + * organization-owned managed profile on the parent profile. + * In both cases, the restriction applies globally on the device and will turn off the + * ultra-wideband radio if it's currently on and prevent the radio from being turned on in + * the future. + * + *
+ * Ultra-wideband (UWB) is a radio technology that can use a very low energy level + * for short-range, high-bandwidth communications over a large portion of the radio spectrum. + * + *
Default is false.
+ *
+ *
Key for user restrictions. + *
Type: Boolean
+ * @see DevicePolicyManager#addUserRestriction(ComponentName, String)
+ * @see DevicePolicyManager#clearUserRestriction(ComponentName, String)
+ * @see #getUserRestrictions()
+ */
+ public static final String DISALLOW_ULTRA_WIDEBAND_RADIO = "no_ultra_wideband_radio";
+
/**
* List of key values that can be passed into the various user restriction related methods
* in {@link UserManager} & {@link DevicePolicyManager}.
@@ -1587,6 +1611,7 @@ public class UserManager {
DISALLOW_WIFI_DIRECT,
DISALLOW_ADD_WIFI_CONFIG,
DISALLOW_CELLULAR_2G,
+ DISALLOW_ULTRA_WIDEBAND_RADIO,
})
@Retention(RetentionPolicy.SOURCE)
public @interface UserRestrictionKey {}
diff --git a/services/core/java/com/android/server/pm/UserRestrictionsUtils.java b/services/core/java/com/android/server/pm/UserRestrictionsUtils.java
index dbd026efed8a9..27d74d517fb94 100644
--- a/services/core/java/com/android/server/pm/UserRestrictionsUtils.java
+++ b/services/core/java/com/android/server/pm/UserRestrictionsUtils.java
@@ -148,7 +148,8 @@ public class UserRestrictionsUtils {
UserManager.DISALLOW_SHARING_ADMIN_CONFIGURED_WIFI,
UserManager.DISALLOW_WIFI_DIRECT,
UserManager.DISALLOW_ADD_WIFI_CONFIG,
- UserManager.DISALLOW_CELLULAR_2G
+ UserManager.DISALLOW_CELLULAR_2G,
+ UserManager.DISALLOW_ULTRA_WIDEBAND_RADIO
});
public static final Set