Total Complexity | 14 |
Total Lines | 57 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
8 | class Namespace_ extends Base |
||
9 | { |
||
10 | /** |
||
11 | * @param string $elementName |
||
12 | * @inheritDoc |
||
13 | */ |
||
14 | public function __construct(string $elementName) |
||
20 | } |
||
21 | |||
22 | public function getType(): string |
||
23 | { |
||
24 | return FullyQualifiedStructuralElementName::TYPE_NAMESPACE; |
||
25 | } |
||
26 | |||
27 | public function include(Base $that): bool |
||
46 | } |
||
47 | |||
48 | public function isNamespace(): bool |
||
49 | { |
||
50 | return true; |
||
51 | } |
||
52 | |||
53 | public function getFullyQualifiedNamespaceNameAsArray(): array |
||
54 | { |
||
55 | if ($this->toString() === '\\') { |
||
56 | return []; |
||
57 | } |
||
58 | |||
59 | return explode('\\', trim($this->toString(), '\\')); |
||
60 | } |
||
61 | |||
62 | public function getFullyQualifiedClassNameAsArray(): ?array |
||
65 | } |
||
66 | } |
||
67 |