Added in API level 34

DevicePolicyIdentifiers


class DevicePolicyIdentifiers
kotlin.Any
   ↳ android.app.admin.DevicePolicyIdentifiers

Class containing identifiers for policy APIs in DevicePolicyManager, for example they will be passed in PolicyUpdateReceiver#onPolicySetResult and PolicyUpdateReceiver#onPolicyChanged to communicate updates of a certain policy back to the admin.

Summary

Constants
static String

String identifier for DevicePolicyManager#setAccountManagementDisabled.

static String

String identifier for DevicePolicyManager#setApplicationHidden.

static String

String identifier for DevicePolicyManager#setApplicationRestrictions.

static String

String identifier for DevicePolicyManager#setAutoTimeZoneEnabled.

static String

String identifier for DevicePolicyManager#setAutoTimeEnabled.

static String

String identifier for DevicePolicyManager#setBackupServiceEnabled.

static String

String identifier for DevicePolicyManager#setCameraDisabled.

static String

String identifier for DevicePolicyManager#setContentProtectionPolicy.

static String

String identifier for DevicePolicyManager#setKeyguardDisabledFeatures.

static String

String identifier for DevicePolicyManager#setLockTaskPackages.

static String

String identifier for DevicePolicyManager#setPackagesSuspended.

static String

String identifier for DevicePolicyManager#setUninstallBlocked.

static String

String identifier for DevicePolicyManager#setRequiredPasswordComplexity.

static String

String identifier for DevicePolicyManager#setPermissionGrantState.

static String

String identifier for DevicePolicyManager#addPersistentPreferredActivity.

static String

String identifier for DevicePolicyManager#setResetPasswordToken.

static String

String identifier for DevicePolicyManager#setSecurityLoggingEnabled.

static String

String identifier for DevicePolicyManager#setStatusBarDisabled.

static String

String identifier for DevicePolicyManager#setUsbDataSignalingEnabled.

static String

String identifier for DevicePolicyManager#setUserControlDisabledPackages.

Public methods
static String

Returns a string identifier for the provided user restrictions, see DevicePolicyManager#addUserRestriction and UserManager for the list of available restrictions.

Constants

ACCOUNT_MANAGEMENT_DISABLED_POLICY

Added in API level 34
static val ACCOUNT_MANAGEMENT_DISABLED_POLICY: String

String identifier for DevicePolicyManager#setAccountManagementDisabled.

Value: "accountManagementDisabled"

APPLICATION_HIDDEN_POLICY

Added in API level 34
static val APPLICATION_HIDDEN_POLICY: String

String identifier for DevicePolicyManager#setApplicationHidden.

Value: "applicationHidden"

APPLICATION_RESTRICTIONS_POLICY

Added in API level 34
static val APPLICATION_RESTRICTIONS_POLICY: String

String identifier for DevicePolicyManager#setApplicationRestrictions.

Value: "applicationRestrictions"

AUTO_TIMEZONE_POLICY

Added in API level 34
static val AUTO_TIMEZONE_POLICY: String

String identifier for DevicePolicyManager#setAutoTimeZoneEnabled.

Value: "autoTimezone"

AUTO_TIME_POLICY

Added in API level 34
static val AUTO_TIME_POLICY: String

String identifier for DevicePolicyManager#setAutoTimeEnabled.

Value: "autoTime"

BACKUP_SERVICE_POLICY

Added in API level 34
static val BACKUP_SERVICE_POLICY: String

String identifier for DevicePolicyManager#setBackupServiceEnabled.

Value: "backupService"

CAMERA_DISABLED_POLICY

Added in API level 34
static val CAMERA_DISABLED_POLICY: String

String identifier for DevicePolicyManager#setCameraDisabled.

Value: "cameraDisabled"

CONTENT_PROTECTION_POLICY

Added in API level 35
static val CONTENT_PROTECTION_POLICY: String

String identifier for DevicePolicyManager#setContentProtectionPolicy.

Value: "contentProtection"

KEYGUARD_DISABLED_FEATURES_POLICY

Added in API level 34
static val KEYGUARD_DISABLED_FEATURES_POLICY: String

String identifier for DevicePolicyManager#setKeyguardDisabledFeatures.

Value: "keyguardDisabledFeatures"

LOCK_TASK_POLICY

Added in API level 34
static val LOCK_TASK_POLICY: String

String identifier for DevicePolicyManager#setLockTaskPackages.

Value: "lockTask"

PACKAGES_SUSPENDED_POLICY

Added in API level 34
static val PACKAGES_SUSPENDED_POLICY: String

String identifier for DevicePolicyManager#setPackagesSuspended.

Value: "packagesSuspended"

PACKAGE_UNINSTALL_BLOCKED_POLICY

Added in API level 34
static val PACKAGE_UNINSTALL_BLOCKED_POLICY: String

String identifier for DevicePolicyManager#setUninstallBlocked.

Value: "packageUninstallBlocked"

PASSWORD_COMPLEXITY_POLICY

Added in API level 35
static val PASSWORD_COMPLEXITY_POLICY: String

String identifier for DevicePolicyManager#setRequiredPasswordComplexity.

Value: "passwordComplexity"

PERMISSION_GRANT_POLICY

Added in API level 34
static val PERMISSION_GRANT_POLICY: String

String identifier for DevicePolicyManager#setPermissionGrantState.

Value: "permissionGrant"

PERSISTENT_PREFERRED_ACTIVITY_POLICY

Added in API level 34
static val PERSISTENT_PREFERRED_ACTIVITY_POLICY: String

String identifier for DevicePolicyManager#addPersistentPreferredActivity.

Value: "persistentPreferredActivity"

RESET_PASSWORD_TOKEN_POLICY

Added in API level 34
static val RESET_PASSWORD_TOKEN_POLICY: String

String identifier for DevicePolicyManager#setResetPasswordToken.

Value: "resetPasswordToken"

SECURITY_LOGGING_POLICY

Added in API level 35
static val SECURITY_LOGGING_POLICY: String

String identifier for DevicePolicyManager#setSecurityLoggingEnabled.

Value: "securityLogging"

STATUS_BAR_DISABLED_POLICY

Added in API level 34
static val STATUS_BAR_DISABLED_POLICY: String

String identifier for DevicePolicyManager#setStatusBarDisabled.

Value: "statusBarDisabled"

USB_DATA_SIGNALING_POLICY

Added in API level 35
static val USB_DATA_SIGNALING_POLICY: String

String identifier for DevicePolicyManager#setUsbDataSignalingEnabled.

Value: "usbDataSignaling"

USER_CONTROL_DISABLED_PACKAGES_POLICY

Added in API level 34
static val USER_CONTROL_DISABLED_PACKAGES_POLICY: String

String identifier for DevicePolicyManager#setUserControlDisabledPackages.

Value: "userControlDisabledPackages"

Public methods

getIdentifierForUserRestriction

Added in API level 34
static fun getIdentifierForUserRestriction(restriction: String): String

Returns a string identifier for the provided user restrictions, see DevicePolicyManager#addUserRestriction and UserManager for the list of available restrictions.

Parameters
restriction String: Value is android.os.UserManager#ALLOW_PARENT_PROFILE_APP_LINKING, android.os.UserManager.DISALLOW_ADD_CLONE_PROFILE, android.os.UserManager#DISALLOW_ADD_MANAGED_PROFILE, android.os.UserManager#DISALLOW_ADD_PRIVATE_PROFILE, android.os.UserManager#DISALLOW_ADD_USER, android.os.UserManager#DISALLOW_ADD_WIFI_CONFIG, android.os.UserManager#DISALLOW_ADJUST_VOLUME, android.os.UserManager#DISALLOW_AIRPLANE_MODE, android.os.UserManager#DISALLOW_AMBIENT_DISPLAY, android.os.UserManager#DISALLOW_APPS_CONTROL, android.os.UserManager#DISALLOW_ASSIST_CONTENT, android.os.UserManager#DISALLOW_AUTOFILL, android.os.UserManager.DISALLOW_BIOMETRIC, android.os.UserManager#DISALLOW_BLUETOOTH, android.os.UserManager#DISALLOW_BLUETOOTH_SHARING, android.os.UserManager.DISALLOW_CAMERA, android.os.UserManager#DISALLOW_CAMERA_TOGGLE, android.os.UserManager#DISALLOW_CELLULAR_2G, android.os.UserManager#DISALLOW_CHANGE_NEAR_FIELD_COMMUNICATION_RADIO, android.os.UserManager#DISALLOW_CHANGE_WIFI_STATE, android.os.UserManager#DISALLOW_CONFIG_BLUETOOTH, android.os.UserManager#DISALLOW_CONFIG_BRIGHTNESS, android.os.UserManager#DISALLOW_CONFIG_CELL_BROADCASTS, android.os.UserManager#DISALLOW_CONFIG_CREDENTIALS, android.os.UserManager#DISALLOW_CONFIG_DATE_TIME, android.os.UserManager#DISALLOW_CONFIG_DEFAULT_APPS, android.os.UserManager#DISALLOW_CONFIG_LOCALE, android.os.UserManager#DISALLOW_CONFIG_LOCATION, android.os.UserManager#DISALLOW_CONFIG_MOBILE_NETWORKS, android.os.UserManager#DISALLOW_CONFIG_PRIVATE_DNS, android.os.UserManager#DISALLOW_CONFIG_SCREEN_TIMEOUT, android.os.UserManager#DISALLOW_CONFIG_TETHERING, android.os.UserManager#DISALLOW_CONFIG_VPN, android.os.UserManager#DISALLOW_CONFIG_WIFI, android.os.UserManager#DISALLOW_CONTENT_CAPTURE, android.os.UserManager#DISALLOW_CONTENT_SUGGESTIONS, android.os.UserManager#DISALLOW_CREATE_WINDOWS, android.os.UserManager#DISALLOW_CROSS_PROFILE_COPY_PASTE, android.os.UserManager#DISALLOW_DATA_ROAMING, android.os.UserManager#DISALLOW_DEBUGGING_FEATURES, android.os.UserManager#DISALLOW_FACTORY_RESET, android.os.UserManager#DISALLOW_FUN, android.os.UserManager#DISALLOW_GRANT_ADMIN, android.os.UserManager#DISALLOW_INSTALL_APPS, android.os.UserManager#DISALLOW_INSTALL_UNKNOWN_SOURCES, android.os.UserManager#DISALLOW_INSTALL_UNKNOWN_SOURCES_GLOBALLY, android.os.UserManager#DISALLOW_MICROPHONE_TOGGLE, android.os.UserManager#DISALLOW_MODIFY_ACCOUNTS, android.os.UserManager#DISALLOW_MOUNT_PHYSICAL_MEDIA, android.os.UserManager#DISALLOW_NEAR_FIELD_COMMUNICATION_RADIO, android.os.UserManager#DISALLOW_NETWORK_RESET, android.os.UserManager.DISALLOW_OEM_UNLOCK, android.os.UserManager#DISALLOW_OUTGOING_BEAM, android.os.UserManager#DISALLOW_OUTGOING_CALLS, android.os.UserManager#DISALLOW_PRINTING, android.os.UserManager.DISALLOW_RECORD_AUDIO, android.os.UserManager#DISALLOW_REMOVE_MANAGED_PROFILE, android.os.UserManager#DISALLOW_REMOVE_USER, android.os.UserManager.DISALLOW_RUN_IN_BACKGROUND, android.os.UserManager#DISALLOW_SAFE_BOOT, android.os.UserManager#DISALLOW_SET_USER_ICON, android.os.UserManager#DISALLOW_SET_WALLPAPER, android.os.UserManager#DISALLOW_SHARE_INTO_MANAGED_PROFILE, android.os.UserManager#DISALLOW_SHARE_LOCATION, android.os.UserManager#DISALLOW_SHARING_ADMIN_CONFIGURED_WIFI, android.os.UserManager#DISALLOW_SIM_GLOBALLY, android.os.UserManager#DISALLOW_SMS, android.os.UserManager#DISALLOW_SYSTEM_ERROR_DIALOGS, android.os.UserManager.DISALLOW_THREAD_NETWORK, android.os.UserManager#DISALLOW_ULTRA_WIDEBAND_RADIO, android.os.UserManager#DISALLOW_UNIFIED_PASSWORD, android.os.UserManager#DISALLOW_UNINSTALL_APPS, android.os.UserManager.DISALLOW_UNMUTE_DEVICE, android.os.UserManager#DISALLOW_UNMUTE_MICROPHONE, android.os.UserManager#DISALLOW_USB_FILE_TRANSFER, android.os.UserManager#DISALLOW_USER_SWITCH, android.os.UserManager.DISALLOW_WALLPAPER, android.os.UserManager#DISALLOW_WIFI_DIRECT, android.os.UserManager#DISALLOW_WIFI_TETHERING, android.os.UserManager#ENSURE_VERIFY_APPS, or android.os.UserManager#KEY_RESTRICTIONS_PENDING This value cannot be null.
Return
String This value cannot be null.