| Total Complexity | 6 |
| Total Lines | 33 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | final class Locale |
||
| 17 | { |
||
| 18 | public const LOCALE = ['fr']; |
||
| 19 | |||
| 20 | private string $locale; |
||
| 21 | |||
| 22 | public function __construct(string $locale) |
||
| 25 | } |
||
| 26 | |||
| 27 | public static function fromString(string $locale): self |
||
| 30 | } |
||
| 31 | |||
| 32 | public static function fromLocale(self $locale): string |
||
| 35 | } |
||
| 36 | |||
| 37 | public function toString(): string |
||
| 38 | { |
||
| 39 | return $this->locale; |
||
| 40 | } |
||
| 41 | |||
| 42 | private static function isLocale(string $locale): string |
||
| 49 | } |
||
| 50 | } |
||
| 51 |