1 | <?php |
||
5 | class Config |
||
6 | { |
||
7 | private $config; |
||
8 | |||
9 | 90 | public function __construct(array $config = []) |
|
14 | |||
15 | /** |
||
16 | * Build a config array. Merge user defined config with our default config. |
||
17 | * |
||
18 | * @param array $config User defined config |
||
19 | * @return array New configuration array |
||
20 | */ |
||
21 | 90 | private function buildConfig(array $config = []) |
|
38 | |||
39 | /** |
||
40 | * Get the config variable. |
||
41 | * |
||
42 | * @param string $val Variable name |
||
43 | * @return array|string Variable value |
||
44 | */ |
||
45 | 78 | public function get($val) |
|
56 | |||
57 | /** |
||
58 | * Return all configurations. |
||
59 | * |
||
60 | * @return array |
||
61 | */ |
||
62 | public function all() |
||
66 | |||
67 | /** |
||
68 | * Set/get custom translation |
||
69 | * |
||
70 | * @param string $id Translation ID |
||
71 | * @return array|void |
||
72 | */ |
||
73 | 90 | public function customTranslations($id = null) |
|
93 | } |
||
94 |