Can
class Can implements Rule, ValidatorAwareRule
Properties
| protected Validator|null | $validator | The current validator instance. |
Methods
__construct(string $ability, array $arguments = [])
Create a new can validation rule.
bool
passes(string $attribute, mixed $value)
Determine if the validation rule passes.
array|string
message()
Get the validation error message.
Details
at line 22
__construct(string $ability, array $arguments = [])
Create a new can validation rule.
at line 31
bool
passes(string $attribute, mixed $value)
Determine if the validation rule passes.
at line 43
array|string
message()
Get the validation error message.
at line 55
ValidatorAwareRule
setValidator(Validator $validator)
Set the current validator.