Total Complexity | 7 |
Total Lines | 52 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
5 | class Tool |
||
6 | { |
||
7 | private string $name; |
||
8 | private string $summary; |
||
9 | private string $website; |
||
10 | private Command $command; |
||
11 | private Command $testCommand; |
||
12 | private array $tags; |
||
13 | |||
14 | 44 | public function __construct(string $name, string $summary, string $website, array $tags, Command $command, Command $testCommand) |
|
15 | { |
||
16 | 44 | $this->name = $name; |
|
17 | 44 | $this->summary = $summary; |
|
18 | 44 | $this->website = $website; |
|
19 | 44 | $this->tags = \array_map(function (string $tag) { |
|
20 | 17 | return $tag; |
|
21 | 44 | }, $tags); |
|
22 | 43 | $this->command = $command; |
|
23 | 43 | $this->testCommand = $testCommand; |
|
24 | } |
||
25 | |||
26 | 7 | public function name(): string |
|
29 | } |
||
30 | |||
31 | 5 | public function summary(): string |
|
32 | { |
||
33 | 5 | return $this->summary; |
|
34 | } |
||
35 | |||
36 | 5 | public function website(): string |
|
37 | { |
||
38 | 5 | return $this->website; |
|
39 | } |
||
40 | |||
41 | 24 | public function command(): Command |
|
42 | { |
||
43 | 24 | return $this->command; |
|
44 | } |
||
45 | |||
46 | 3 | public function testCommand(): Command |
|
47 | { |
||
48 | 3 | return $this->testCommand; |
|
49 | } |
||
50 | |||
51 | /** |
||
52 | * @return array|string[] |
||
53 | */ |
||
54 | 30 | public function tags(): array |
|
57 | } |
||
58 | } |
||
59 |