Total Complexity | 5 |
Total Lines | 28 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
6 | final class Path implements PathInterface |
||
7 | { |
||
8 | |||
9 | private $elements; |
||
10 | |||
11 | 9 | public function __construct(...$elements) |
|
12 | { |
||
13 | 9 | $this->elements = $elements; |
|
14 | 9 | } |
|
15 | |||
16 | 2 | public function copyWithElement(int $index): PathInterface |
|
17 | { |
||
18 | 2 | return new self(...$this->elements, ...[$index]); |
|
19 | } |
||
20 | |||
21 | 2 | public function copyWithProperty(string $name): PathInterface |
|
24 | } |
||
25 | |||
26 | 7 | public function getElements(): array |
|
29 | } |
||
30 | |||
31 | 4 | public function equals(PathInterface $path): bool |
|
34 | } |
||
35 | } |
||
36 |