Total Complexity | 4 |
Total Lines | 36 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
9 | class XmlConvertibleObject implements XmlConvertibleInterface |
||
10 | { |
||
11 | use XmlConvertible { |
||
12 | getXmlProperties as protected traitXmlProperties; |
||
13 | } |
||
14 | |||
15 | private array $xmlProperties = []; |
||
16 | |||
17 | /** |
||
18 | * XmlConvertibleObject constructor. |
||
19 | * @param string $xmlElementName |
||
20 | * @param array $xmlChildren |
||
21 | */ |
||
22 | public function __construct(?string $xmlElementName = null, array $xmlChildren = null) |
||
26 | } |
||
27 | 19 | ||
28 | /** |
||
29 | 19 | * @param array|null $properties |
|
30 | 19 | * @return array |
|
31 | 19 | */ |
|
32 | public function getXmlProperties(?array $properties = null): array |
||
35 | } |
||
36 | |||
37 | 14 | public function __get(string $name) |
|
38 | { |
||
39 | 14 | return $this->xmlProperties[$name] ?? null; |
|
40 | } |
||
41 | |||
42 | public function __set(string $name, $value): void |
||
45 | } |
||
46 | } |
||
47 |