| Total Complexity | 3 |
| Total Lines | 40 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 21 | class LangException extends \Exception |
||
| 22 | { |
||
| 23 | /** |
||
| 24 | * Misconfigured lang config |
||
| 25 | */ |
||
| 26 | const MISCONFIGURED_LANG_CONFIG = 'Misconfigured lang config'; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Translations not found |
||
| 30 | */ |
||
| 31 | const TRANSLATION_FILES_NOT_FOUND = 'Translations for language `{%1}` not found'; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * Misconfigured default lang config |
||
| 35 | */ |
||
| 36 | const MISCONFIGURED_LANG_DEFAULT_CONFIG = 'Misconfigured default lang config'; |
||
| 37 | |||
| 38 | /** |
||
| 39 | * @return \Quantum\Exceptions\LangException |
||
| 40 | */ |
||
| 41 | public static function misconfiguredConfig(): LangException |
||
| 42 | { |
||
| 43 | return new static(self::MISCONFIGURED_LANG_CONFIG, E_WARNING); |
||
| 44 | } |
||
| 45 | |||
| 46 | /** |
||
| 47 | * @param string $name |
||
| 48 | * @return \Quantum\Exceptions\LangException |
||
| 49 | */ |
||
| 50 | public static function translationsNotFound(string $name): LangException |
||
| 53 | } |
||
| 54 | |||
| 55 | /** |
||
| 56 | * @return \Quantum\Exceptions\LangException |
||
| 57 | */ |
||
| 58 | public static function misconfiguredDefaultConfig(): LangException |
||
| 63 |