PSPDFApplicationPolicy

@protocol PSPDFApplicationPolicy

The security auditor protocol allows to define a custom set of overrides for various security related tasks.

  • Returns YES when the PSPDFPolicyEvent is allowed. isUserAction is a hint that indicates if we’re in a user action or an automated test. If it’s a user action, it is appropriate to present an alert explaining the lack of permissions.

    Declaration

    Objective-C

    - (BOOL)hasPermissionForEvent:(nonnull NSString *)event
                     isUserAction:(BOOL)isUserAction;

    Swift

    func hasPermission(forEvent event: String, isUserAction: Bool) -> Bool