PermissionInfoCompat

Added in 1.1.0

class PermissionInfoCompat


Helper for accessing features in PermissionInfo.

Summary

Public functions

java-static Int
getProtection(permissionInfo: PermissionInfo)

Return the base permission type of a PermissionInfo.

java-static Int

Return the additional protection flags of a PermissionInfo.

Public functions

getProtection

Added in 1.1.0
java-static fun getProtection(permissionInfo: PermissionInfo): Int

Return the base permission type of a PermissionInfo.

Value is one of the following:

  • PermissionInfo.PROTECTION_NORMAL
  • PermissionInfo.PROTECTION_DANGEROUS
  • PermissionInfo.PROTECTION_SIGNATURE
  • PermissionInfo.PROTECTION_SIGNATURE_OR_SYSTEM

getProtectionFlags

Added in 1.1.0
java-static fun getProtectionFlags(permissionInfo: PermissionInfo): Int

Return the additional protection flags of a PermissionInfo.

Value is either 0 or a combination of the following:

  • PermissionInfo.PROTECTION_FLAG_PRIVILEGED
  • PermissionInfo.PROTECTION_FLAG_SYSTEM
  • PermissionInfo.PROTECTION_FLAG_DEVELOPMENT
  • PermissionInfo.PROTECTION_FLAG_APPOP
  • PermissionInfo.PROTECTION_FLAG_PRE23
  • PermissionInfo.PROTECTION_FLAG_INSTALLER
  • PermissionInfo.PROTECTION_FLAG_VERIFIER
  • PermissionInfo.PROTECTION_FLAG_PREINSTALLED
  • PermissionInfo.PROTECTION_FLAG_SETUP
  • PermissionInfo.PROTECTION_FLAG_INSTANT
  • PermissionInfo.PROTECTION_FLAG_RUNTIME_ONLY