RulePolicy
in package
Class PolicyManager.
Table of Contents
Properties
- $rules : array<string, string>
Methods
- addRule() : void
- check() : bool
- getRuleFor() : mixed
Properties
$rules
private
array<string, string>
$rules
= []
Methods
addRule()
public
addRule(string $model, string $handler) : void
Parameters
- $model : string
- $handler : string
check()
public
check(string $type, string $ability, array<string|int, mixed> $arguments) : bool
Parameters
- $type : string
- $ability : string
- $arguments : array<string|int, mixed>
Return values
boolgetRuleFor()
public
getRuleFor(string $ability) : mixed
Parameters
- $ability : string