Total Complexity | 5 |
Total Lines | 39 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
11 | class Translation implements Resource |
||
12 | { |
||
13 | use Makeable; |
||
14 | |||
15 | protected $keys = []; |
||
16 | |||
17 | protected $translations = []; |
||
18 | |||
19 | public function getKeys(): array |
||
20 | { |
||
21 | return $this->keys; |
||
22 | } |
||
23 | |||
24 | public function keys(string $target, array $keys): Resource |
||
25 | { |
||
26 | $values = $this->keys[$target] ?? []; |
||
27 | |||
28 | $this->keys[$target] = $this->merge($values, $keys); |
||
29 | |||
30 | return $this; |
||
31 | } |
||
32 | |||
33 | public function translation(string $locale, string $target, array $translations): Resource |
||
40 | } |
||
41 | |||
42 | public function getTranslations(): array |
||
45 | } |
||
46 | |||
47 | protected function merge(array ...$arrays): array |
||
50 | } |
||
51 | } |
||
52 |