Interface ResolverInterface
Policy resolver interface.
Namespace: Authorization\Policy
Method Summary
-
getPolicy() public
Resolves the policy object based on the authorization resource.
Method Detail
getPolicy() ΒΆ public
getPolicy(mixed $resource): mixed
Resolves the policy object based on the authorization resource.
The resolver MUST throw the \Authorization\Policy\Exception\MissingPolicyException
exception if a policy cannot be resolved for a given resource.
Parameters
-
mixed
$resource A resource that the access is checked against.
Returns
mixed
Throws
Authorization\Policy\Exception\MissingPolicyException
If a policy cannot be resolved.