1 | <?php |
||
5 | class ConfigCollection implements ConfigCollectionInterface |
||
6 | { |
||
7 | |||
8 | /** |
||
9 | * Stores a list of key/value config. |
||
10 | * |
||
11 | * @var array |
||
12 | */ |
||
13 | protected $config = []; |
||
14 | |||
15 | /** |
||
16 | * @var array |
||
17 | */ |
||
18 | protected $metadata = []; |
||
19 | |||
20 | /** |
||
21 | * @var array |
||
22 | */ |
||
23 | protected $history = []; |
||
24 | |||
25 | /** |
||
26 | * @var boolean |
||
27 | */ |
||
28 | protected $trackMetadata = false; |
||
29 | |||
30 | 24 | public function __construct($trackMetadata = false) |
|
34 | |||
35 | /** |
||
36 | * {@inheritdoc} |
||
37 | */ |
||
38 | 21 | public function set($key, $value, $metadata = []) |
|
57 | |||
58 | /** |
||
59 | * {@inheritdoc} |
||
60 | */ |
||
61 | 21 | public function get($key) |
|
69 | |||
70 | /** |
||
71 | * {@inheritdoc} |
||
72 | */ |
||
73 | 22 | public function exists($key) |
|
77 | |||
78 | /** |
||
79 | * {@inheritdoc} |
||
80 | */ |
||
81 | 1 | public function delete($key) |
|
87 | |||
88 | /** |
||
89 | * {@inheritdoc} |
||
90 | */ |
||
91 | 1 | public function deleteAll() |
|
97 | |||
98 | /** |
||
99 | * {@inheritdoc} |
||
100 | */ |
||
101 | 2 | public function getMetadata() |
|
109 | |||
110 | /** |
||
111 | * {@inheritdoc} |
||
112 | */ |
||
113 | 2 | public function getHistory() |
|
121 | } |
||
122 |