Static Readonly BASE_Allows the given users or rules to perform the operation
this permission object
Rest ...userOrRole: TrustedEntity[]The users or roles to allow
Copies permissions from another permission object
The permission to copy from
Deletes any allow/deny rules for the given users or roles
this permission object
Rest ...userOrRole: TrustedEntity[]The users or roles to delete rules for
Denies the given users or rules to perform the operation
this permission object
Rest ...userOrRole: TrustedEntity[]The users or roles to deny
Returns the actual rule of the given user or role.
The actual access rule or undefined if no rule was found
The user or role to check for
Checks whenever the user or role is explicit allowed to perform the operation.
true If the given user or role is allowed
The user or role to check for
Checks whenever the user or role is explicit denied to perform the operation.
true If the given user or role is denied
The user or role to check for
Gets whenever all users and roles have the permission to perform the operation
Public access is expressed explicitly by the wildcard allow rule
({'*': 'allow'}). For backwards compatibility an empty rule set (no
allow rules at all) is still treated as public, matching object/file
instance ACLs and pre-migration server payloads. A wildcard deny rule
({'*': 'deny'}) or any specific allow rule means access is not public.
true If public access is allowed
Private refResolves user and role references and validate given references
The resolved and validated reference
The user, role or reference
Revokes public access by removing the wildcard allow rule.
This is the inverse of setPublicAllowed. Only the public wildcard
allow rule ({'*': 'allow'}) is removed; a wildcard deny rule
({'*': 'deny'}) and all user/role specific rules are left untouched. If no
allow rules remain afterwards the permission serializes as omitted, so the
server applies its default unless access is granted to specific users/roles.
Sets whenever all users and roles should have the permission to perform the operation
Public access is represented explicitly as a wildcard allow rule
({'*': 'allow'}) so it can be distinguished from an unconfigured
permission (empty rules) over the wire. Any other allow rules become
redundant and are removed; existing deny rules are kept.
Static fromJSONCreates a permission from the given rules.
The permission.
The rules.
Generated using TypeDoc
An aggregation of access rules for given object metadata.