| Total Complexity | 5 |
| Total Lines | 39 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 26 | class Translation implements Resource |
||
| 27 | { |
||
| 28 | use Makeable; |
||
| 29 | |||
| 30 | protected $keys = []; |
||
| 31 | |||
| 32 | protected $translations = []; |
||
| 33 | |||
| 34 | public function getKeys(): array |
||
| 35 | { |
||
| 36 | return $this->keys; |
||
| 37 | } |
||
| 38 | |||
| 39 | public function keys(string $target, array $keys): Resource |
||
| 40 | { |
||
| 41 | $values = $this->keys[$target] ?? []; |
||
| 42 | |||
| 43 | $this->keys[$target] = $this->merge($values, $keys); |
||
| 44 | |||
| 45 | return $this; |
||
| 46 | } |
||
| 47 | |||
| 48 | public function translation(string $locale, string $target, array $translations): Resource |
||
| 55 | } |
||
| 56 | |||
| 57 | public function getTranslations(): array |
||
| 60 | } |
||
| 61 | |||
| 62 | protected function merge(array ...$arrays): array |
||
| 65 | } |
||
| 66 | } |
||
| 67 |