Total Complexity | 5 |
Total Lines | 54 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
7 | class SubThemeDescriptor implements ThemeDescriptorInterface, \JsonSerializable |
||
8 | { |
||
9 | /** |
||
10 | * @var mixed[] |
||
11 | */ |
||
12 | private $additionalContext; |
||
13 | /** |
||
14 | * @var ThemeDescriptorInterface |
||
15 | */ |
||
16 | private $themeDescriptor; |
||
17 | |||
18 | /** |
||
19 | * @param mixed[] $additionalContext |
||
20 | */ |
||
21 | public function __construct(ThemeDescriptorInterface $themeDescriptor, array $additionalContext) |
||
22 | { |
||
23 | $this->additionalContext = $additionalContext; |
||
24 | $this->themeDescriptor = $themeDescriptor; |
||
25 | } |
||
26 | |||
27 | /** |
||
28 | * @return ThemeDescriptorInterface |
||
29 | */ |
||
30 | public function getThemeDescriptor(): ThemeDescriptorInterface |
||
31 | { |
||
32 | return $this->themeDescriptor; |
||
33 | } |
||
34 | |||
35 | /** |
||
36 | * @return mixed[] |
||
37 | */ |
||
38 | public function getAdditionalContext(): array |
||
41 | } |
||
42 | |||
43 | public function jsonSerialize() |
||
49 | ]; |
||
50 | } |
||
51 | |||
52 | /** |
||
53 | * Returns the path of the theme. |
||
54 | * This does not have to be an absolute path (it is relative to the theme directory) |
||
55 | * |
||
56 | * @return string|null |
||
57 | */ |
||
58 | public function getPath(): ?string |
||
63 |