Метод |
Описание |
|
__construct ( PolicySet $policySet = null ) |
Init the object, possibly with an optional policy set |
|
allows ( string $policyName, object $subject, array $addl = [] ) : boolean |
Locate a policy by key name and determine if the subject is allowed
by matching against its properties |
|
denies ( string $policyName, object $subject, array $addl = [] ) : boolean |
Locate a policy by name and evaluate if the subject is denied
by matching against its properties |
|
evaluate ( object $subject, Policy $policy, array $addl = [] ) : boolean |
Given a subject and a policy, evaluate the pass/fail result of the matching |
|
executeTests ( array $tests, string $type, string $propertyValue, array $addl ) : boolean |
Execute the tests on the policy to ensure they match/pass |
|
getPropertyValue ( string $type, object $subject ) : mixed |
Type a few options to get the property value for evaluation |
|
instance ( PolicySet $policySet = null ) : Enforcer |
Static method to get a new instance of the Enforcer object |
|
setPolicySet ( PolicySet $policySet ) : Enforcer |
Set the current policy set (overrides, not appends) |
|