SystemPermissionChecker
public protocol SystemPermissionChecker : AnyObject
The interface for the component that will check that required permissions are granted.
Implementations must be safe to call from any thread.
-
Undocumented
Declaration
Swift
var delegate: SystemPermissionCheckerDelegate? { get set }
-
Must return
true
only if all the permissions are authorisedDeclaration
Swift
func isAuthorised(for permissions: Set<SystemPermissionConstraint>) -> Bool
-
Must return the status of the permission.
Declaration
Swift
func status(of permission: SystemPermissionConstraint) -> SystemPermissionStatus
-
Must ask the user to grant the given permission
Declaration
Swift
func requestAuthorization(for permission: SystemPermissionConstraint, completion: @escaping (_ permission: SystemPermissionConstraint, _ status: SystemPermissionStatus) -> Void)