Total Complexity | 5 |
Total Lines | 37 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
15 | class Digraph implements HasDotRepresentation |
||
16 | { |
||
17 | /** @var HasDotRepresentation[] */ |
||
18 | private $dotElements; |
||
19 | |||
20 | public function __construct() |
||
21 | { |
||
22 | $this->dotElements = []; |
||
23 | } |
||
24 | 42 | ||
25 | /** @param HasDotRepresentation[] */ |
||
26 | public function add(array $definitions): void |
||
27 | { |
||
28 | 42 | $this->dotElements = array_merge($this->dotElements, $definitions); |
|
29 | 42 | } |
|
30 | 42 | ||
31 | 42 | public function toDotLanguage(): string |
|
38 | 6 | } |
|
39 | 24 | ||
40 | private function elementsToDotLanguage(): string |
||
47 | 24 | } |
|
48 | |||
49 | 6 | private function graphId(): string |
|
54 |