We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
| Total Complexity | 4 |
| Total Lines | 37 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | class LengthException extends ValidationException |
||
| 17 | { |
||
| 18 | const BOTH = 0; |
||
| 19 | const LOWER = 1; |
||
| 20 | const GREATER = 2; |
||
| 21 | const EXACT = 3; |
||
| 22 | |||
| 23 | public static $defaultTemplates = [ |
||
| 24 | self::MODE_DEFAULT => [ |
||
| 25 | self::BOTH => '{{name}} must have a length between {{minValue}} and {{maxValue}}', |
||
| 26 | self::LOWER => '{{name}} must have a length greater than {{minValue}}', |
||
| 27 | self::GREATER => '{{name}} must have a length lower than {{maxValue}}', |
||
| 28 | self::EXACT => '{{name}} must have a length of {{maxValue}}', |
||
| 29 | ], |
||
| 30 | self::MODE_NEGATIVE => [ |
||
| 31 | self::BOTH => '{{name}} must not have a length between {{minValue}} and {{maxValue}}', |
||
| 32 | self::LOWER => '{{name}} must not have a length greater than {{minValue}}', |
||
| 33 | self::GREATER => '{{name}} must not have a length lower than {{maxValue}}', |
||
| 34 | self::EXACT => '{{name}} must not have a length of {{maxValue}}', |
||
| 35 | ], |
||
| 36 | ]; |
||
| 37 | |||
| 38 | public function chooseTemplate() |
||
| 55 |