1 | <?php |
||
7 | class Metadata implements MetadataInterface |
||
8 | { |
||
9 | /** |
||
10 | * @var array |
||
11 | */ |
||
12 | private $metadata = []; |
||
13 | |||
14 | /** |
||
15 | * @param array $metadata |
||
16 | */ |
||
17 | 106 | public function __construct(array $metadata = []) |
|
23 | |||
24 | /** |
||
25 | * @param string $key |
||
26 | * @param string $value |
||
27 | */ |
||
28 | 15 | public function set($key, $value) |
|
32 | |||
33 | /** |
||
34 | * @param string $key |
||
35 | * @return mixed|null |
||
36 | */ |
||
37 | 6 | public function get($key) |
|
41 | |||
42 | /** |
||
43 | * @param string $key |
||
44 | * @return bool |
||
45 | */ |
||
46 | 6 | public function has($key) |
|
50 | |||
51 | /** |
||
52 | * @param $key |
||
53 | */ |
||
54 | 2 | public function remove($key) |
|
60 | |||
61 | /** |
||
62 | * @return array |
||
63 | */ |
||
64 | 44 | public function all() |
|
68 | |||
69 | /** |
||
70 | * {@inheritdoc} |
||
71 | */ |
||
72 | 1 | public function getIterator() |
|
76 | |||
77 | /** |
||
78 | * {@inheritdoc} |
||
79 | */ |
||
80 | 1 | public function count() |
|
84 | } |
||
85 |