| Total Complexity | 3 |
| Total Lines | 30 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 21 | trait ValidatorFacadeTrait |
||
| 22 | { |
||
| 23 | /** |
||
| 24 | * @var ValidatorInterface |
||
| 25 | */ |
||
| 26 | protected ValidatorInterface $validator; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * @return void |
||
| 30 | */ |
||
| 31 | private function bootValidatorFacadeTrait(): void |
||
| 32 | { |
||
| 33 | $this->validator = new Factory(); |
||
| 34 | } |
||
| 35 | |||
| 36 | /** |
||
| 37 | * @return ValidatorInterface |
||
| 38 | */ |
||
| 39 | public function getValidator(): ValidatorInterface |
||
| 40 | { |
||
| 41 | return $this->validator; |
||
| 42 | } |
||
| 43 | |||
| 44 | /** |
||
| 45 | * @param DefinitionInterface $definition |
||
| 46 | * @return void |
||
| 47 | */ |
||
| 48 | public function assertValid(DefinitionInterface $definition): void |
||
| 51 | } |
||
| 52 | } |
||
| 53 |