| 1 | <?php |
||
| 8 | class DoormanRule implements Rule |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * @var \Clarkeash\Doorman\Doorman |
||
| 12 | */ |
||
| 13 | private $doorman; |
||
| 14 | |||
| 15 | /** |
||
| 16 | * @var string|null |
||
| 17 | */ |
||
| 18 | private $email; |
||
| 19 | |||
| 20 | 3 | public function __construct($email = null) |
|
| 25 | |||
| 26 | /** |
||
| 27 | * Determine if the validation rule passes. |
||
| 28 | * |
||
| 29 | * @param string $attribute |
||
| 30 | * @param mixed $value |
||
| 31 | * @return bool |
||
| 32 | */ |
||
| 33 | 3 | public function passes($attribute, $value) |
|
| 37 | |||
| 38 | /** |
||
| 39 | * Get the validation error message. |
||
| 40 | * |
||
| 41 | * @return string|array |
||
| 42 | */ |
||
| 43 | 1 | public function message() |
|
| 47 | } |