Java android.app.admin DevicePolicyManager fields, constructors, methods, implement or subclass

Example usage for Java android.app.admin DevicePolicyManager fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for android.app.admin DevicePolicyManager.

The text is from its open source code.

Field

StringACTION_PROVISION_MANAGED_USER
Activity action: Starts the provisioning flow which sets up a managed user.
StringEXTRA_PROVISIONING_ADMIN_EXTRAS_BUNDLE
A android.os.Parcelable extra of type android.os.PersistableBundle that allows a mobile device management application or NFC programmer application which starts managed provisioning to pass data to the management application instance after provisioning.
StringEXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME
A String extra holding the package name of the mobile device management application that will be set as the profile owner or device owner.
StringEXTRA_PROVISIONING_TIME_ZONE
A String extra holding the time zone android.app.AlarmManager that the device will be set to.
StringEXTRA_PROVISIONING_LOCAL_TIME
A Long extra holding the wall clock time (in milliseconds) to be set on the device's android.app.AlarmManager .
StringEXTRA_PROVISIONING_LOCALE
A String extra holding the java.util.Locale that the device will be set to.
StringEXTRA_PROVISIONING_WIFI_SSID
A String extra holding the ssid of the wifi network that should be used during nfc device owner provisioning for downloading the mobile device management application.
StringEXTRA_PROVISIONING_WIFI_SECURITY_TYPE
A String extra indicating the security type of the wifi network in #EXTRA_PROVISIONING_WIFI_SSID and could be one of NONE , WPA or WEP .
StringEXTRA_PROVISIONING_WIFI_PASSWORD
A String extra holding the password of the wifi network in #EXTRA_PROVISIONING_WIFI_SSID .
StringEXTRA_PROVISIONING_SKIP_ENCRYPTION
A boolean extra indicating whether device encryption can be skipped as part of device owner or managed profile provisioning.
StringMIME_TYPE_PROVISIONING_NFC
This MIME type is used for starting the device owner provisioning.
StringACTION_ADD_DEVICE_ADMIN
Activity action: ask the user to add a new device administrator to the system.
StringEXTRA_DEVICE_ADMIN
The ComponentName of the administrator component.
StringEXTRA_ADD_EXPLANATION
An optional CharSequence providing additional explanation for why the admin is being added.
StringACTION_SET_NEW_PASSWORD
Activity action: have the user enter a new password.
StringACTION_SET_NEW_PARENT_PROFILE_PASSWORD
Activity action: have the user enter a new password for the parent profile.
intPERMISSION_POLICY_PROMPT
Permission policy to prompt user for new permission requests for runtime permissions.
intPERMISSION_POLICY_AUTO_GRANT
Permission policy to always grant new permission requests for runtime permissions.
intPERMISSION_POLICY_AUTO_DENY
Permission policy to always deny new permission requests for runtime permissions.
intPERMISSION_GRANT_STATE_GRANTED
Runtime permission state: The permission is granted to the app and the user cannot manage the permission through the UI.
intPASSWORD_QUALITY_UNSPECIFIED
Constant for #setPasswordQuality : the policy has no requirements for the password.
intPASSWORD_QUALITY_ALPHANUMERIC
Constant for #setPasswordQuality : the user must have entered a password containing at least both> numeric and alphabetic (or other symbol) characters.
intPASSWORD_QUALITY_COMPLEX
Constant for #setPasswordQuality : the user must have entered a password containing at least a letter, a numerical digit and a special symbol, by default.
intRESET_PASSWORD_REQUIRE_ENTRY
Flag for #resetPasswordWithToken and #resetPassword : don't allow other admins to change the password again until the user has entered it.
intRESET_PASSWORD_DO_NOT_ASK_CREDENTIALS_ON_BOOT
Flag for #resetPasswordWithToken and #resetPassword : don't ask for user credentials on device boot.
intWIPE_EXTERNAL_STORAGE
Flag for #wipeData(int) : also erase the device's external storage (such as SD cards).
intWIPE_RESET_PROTECTION_DATA
Flag for #wipeData(int) : also erase the factory reset protection data.
intENCRYPTION_STATUS_UNSUPPORTED
Result code for #setStorageEncryption and #getStorageEncryptionStatus : indicating that encryption is not supported.
intENCRYPTION_STATUS_INACTIVE
Result code for #setStorageEncryption and #getStorageEncryptionStatus : indicating that encryption is supported, but is not currently active.
intENCRYPTION_STATUS_ACTIVATING
Result code for #getStorageEncryptionStatus : indicating that encryption is not currently active, but is currently being activated.
intENCRYPTION_STATUS_ACTIVE
Result code for #setStorageEncryption and #getStorageEncryptionStatus : indicating that encryption is active.
StringACTION_START_ENCRYPTION
Activity action: begin the process of encrypting data on the device.
intKEYGUARD_DISABLE_FEATURES_NONE
Widgets are enabled in keyguard
intSKIP_SETUP_WIZARD
Flag used by #createAndManageUser to skip setup wizard after creating a new user.

Method

ListgetActiveAdmins()
Return a list of all currently active device administrators' component names.
SetgetAffiliationIds(@NonNull ComponentName admin)
Returns the set of affiliation ids previously set via #setAffiliationIds , or an empty set if none have been set.
ListgetBindDeviceAdminTargetUsers(@NonNull ComponentName admin)
Returns the list of target users that the calling device or profile owner can use when calling #bindDeviceAdminServiceAsUser .
booleangetCameraDisabled(@Nullable ComponentName admin)
Determine whether or not the device's cameras have been disabled for this user, either by the calling admin, if specified, or all admins.
StringgetDeviceOwner()
Returns the device owner package name, only if it's running on the calling user.
intgetStorageEncryptionStatus()
Called by an application that is administering the device to determine the current encryption status of the device.
booleaninstallCaCert(@Nullable ComponentName admin, byte[] certBuffer)
Installs the given certificate as a user CA.
booleanisAdminActive(@NonNull ComponentName admin)
Return true if the given administrator component is currently active (enabled) in the system.
booleanisApplicationHidden(@NonNull ComponentName admin, String packageName)
Determine if a package is hidden.
booleanisDeviceOwnerApp(String packageName)
Used to determine if a particular package has been registered as a Device Owner app.
booleanisManagedProfile(@NonNull ComponentName admin)
Return if this user is a managed profile of another user.
booleanisProfileOwnerApp(String packageName)
Used to determine if a particular package is registered as the profile owner for the user.
booleanisProvisioningAllowed(@NonNull String action)
Returns whether it is possible for the caller to initiate provisioning of a managed profile or device, setting itself as the device or profile owner.
voidlockNow()
Make the device lock immediately, as if the lock screen timeout has expired at the point of this call.
voidremoveActiveAdmin(@NonNull ComponentName admin)
Remove a current administration component.
booleanresetPassword(String password, int flags)
Force a new password for device unlock (the password needed to access the entire device) or the work profile challenge on the current user.
voidsetActiveAdmin(@NonNull ComponentName policyReceiver, boolean refreshing, int userHandle)
voidsetAffiliationIds(@NonNull ComponentName admin, @NonNull Set ids)
Indicates the entity that controls the device or profile owner.
booleansetApplicationHidden(@NonNull ComponentName admin, String packageName, boolean hidden)
Hide or unhide packages.
voidsetApplicationRestrictions(@Nullable ComponentName admin, String packageName, Bundle settings)
Sets the application restrictions for a given target application running in the calling user.
voidsetCameraDisabled(@NonNull ComponentName admin, boolean disabled)
Called by an application that is administering the device to disable all cameras on the device, for this user.
voidsetOrganizationColorForUser(@ColorInt int color, @UserIdInt int userId)
voidsetProfileEnabled(@NonNull ComponentName admin)
Sets the enabled state of the profile.
voidsetProfileName(@NonNull ComponentName admin, String profileName)
Sets the name of the profile.
booleansetProfileOwner(@NonNull ComponentName admin, @Deprecated String ownerName, int userHandle)
voidwipeData(int flags)
Ask that all user data be wiped.