Interface BeforeScopeInterface
This interface should be implemented if a policy class needs to perform a pre-authorization check before the scope is applied to the resource.
Namespace: Authorization\Policy
Method Summary
-
beforeScope() public
Defines a pre-scope check.
Method Detail
beforeScope() ΒΆ public
beforeScope(Authorization\IdentityInterface|null $identity, mixed $resource, string $action): mixed
Defines a pre-scope check.
If a non-null value is returned, the scope application will be skipped and the un-scoped resource
will be returned. In case of null
, the scope will be applied.
Parameters
-
Authorization\IdentityInterface|null
$identity Identity object.
-
mixed
$resource The resource being operated on.
-
string
$action The action/operation being performed.
Returns
mixed