Total Complexity | 5 |
Total Lines | 38 |
Duplicated Lines | 0 % |
Coverage | 83.33% |
Changes | 0 |
1 | <?php |
||
13 | class Entity |
||
14 | { |
||
15 | /** @var IFileFormat|null */ |
||
16 | protected $formatClass = null; |
||
17 | /** @var string[] */ |
||
18 | protected $storage = []; |
||
19 | |||
20 | 1 | public function __construct(IFileFormat $formatClass) |
|
21 | { |
||
22 | 1 | $this->formatClass = $formatClass; |
|
23 | 1 | } |
|
24 | |||
25 | /** |
||
26 | * @codeCoverageIgnore why someone would run that?! |
||
27 | */ |
||
28 | private function __clone() |
||
29 | { |
||
30 | } |
||
31 | |||
32 | /** |
||
33 | * @return string[] |
||
34 | */ |
||
35 | 1 | public function get(): array |
|
36 | { |
||
37 | 1 | return $this->storage; |
|
38 | } |
||
39 | |||
40 | /** |
||
41 | * @param string[] $content |
||
42 | */ |
||
43 | 1 | public function set(array $content): void |
|
46 | 1 | } |
|
47 | |||
48 | 1 | public function getFormat(): ?IFileFormat |
|
51 | } |
||
52 | } |
||
53 |