1 | <?php declare(strict_types = 1); |
||
5 | class Result |
||
6 | { |
||
7 | /** |
||
8 | * The file property. |
||
9 | * @var string |
||
10 | */ |
||
11 | private $file; |
||
12 | |||
13 | /** |
||
14 | * The commits property. |
||
15 | * @var integer |
||
16 | */ |
||
17 | private $commits; |
||
18 | |||
19 | /** |
||
20 | * The complexity property. |
||
21 | * @var integer |
||
22 | */ |
||
23 | private $complexity; |
||
24 | |||
25 | /** |
||
26 | * Class constructor. |
||
27 | * @param array $data Data to store in the object. |
||
28 | */ |
||
29 | public function __construct(array $data) |
||
35 | |||
36 | /** |
||
37 | * Get the file property. |
||
38 | * @return string |
||
39 | */ |
||
40 | public function getFile(): string |
||
44 | |||
45 | /** |
||
46 | * Get the file property. |
||
47 | * @return integer |
||
48 | */ |
||
49 | public function getCommits(): int |
||
53 | |||
54 | /** |
||
55 | * Get the file property. |
||
56 | * @return integer |
||
57 | */ |
||
58 | public function getComplexity(): int |
||
62 | |||
63 | /** |
||
64 | * Calculate the score. |
||
65 | * @return integer |
||
66 | */ |
||
67 | public function getScore(): int |
||
71 | |||
72 | /** |
||
73 | * Output results to an array. |
||
74 | * @return array |
||
75 | */ |
||
76 | public function toArray(): array |
||
85 | } |
||
86 |