1 | <?php |
||
19 | class ConfigManager implements ConfigManagerInterface |
||
20 | { |
||
21 | /** |
||
22 | * @var string |
||
23 | */ |
||
24 | private $defaultConfig; |
||
25 | |||
26 | /** |
||
27 | * @var array |
||
28 | */ |
||
29 | private $configs = []; |
||
30 | |||
31 | /** |
||
32 | * @param array $configs |
||
33 | * @param string|null $defaultConfig |
||
34 | */ |
||
35 | public function __construct(array $configs = [], $defaultConfig = null) |
||
43 | |||
44 | /** |
||
45 | * {@inheritdoc} |
||
46 | */ |
||
47 | public function getDefaultConfig() |
||
51 | |||
52 | /** |
||
53 | * {@inheritdoc} |
||
54 | */ |
||
55 | public function setDefaultConfig($defaultConfig) |
||
63 | |||
64 | /** |
||
65 | * {@inheritdoc} |
||
66 | */ |
||
67 | public function hasConfigs() |
||
71 | |||
72 | /** |
||
73 | * {@inheritdoc} |
||
74 | */ |
||
75 | public function getConfigs() |
||
79 | |||
80 | /** |
||
81 | * {@inheritdoc} |
||
82 | */ |
||
83 | public function setConfigs(array $configs) |
||
89 | |||
90 | /** |
||
91 | * {@inheritdoc} |
||
92 | */ |
||
93 | public function hasConfig($name) |
||
97 | |||
98 | /** |
||
99 | * {@inheritdoc} |
||
100 | */ |
||
101 | public function getConfig($name) |
||
109 | |||
110 | /** |
||
111 | * {@inheritdoc} |
||
112 | */ |
||
113 | public function setConfig($name, array $config) |
||
117 | |||
118 | /** |
||
119 | * {@inheritdoc} |
||
120 | */ |
||
121 | public function mergeConfig($name, array $config) |
||
125 | } |
||
126 |