Total Complexity | 3 |
Total Lines | 31 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
17 | trait ClassLikeTrait |
||
18 | { |
||
19 | /** |
||
20 | * @var FunctionModelInterface[]|Collection $functions Class functions. |
||
21 | */ |
||
22 | protected $functions; |
||
23 | |||
24 | /** |
||
25 | * @param FunctionModelInterface $function The function to add on this parent. |
||
26 | */ |
||
27 | public function addFunction(FunctionModelInterface $function): void |
||
28 | { |
||
29 | $this->functions->add($function); |
||
30 | } |
||
31 | |||
32 | /** |
||
33 | * @return FunctionModelInterface[]|Collection All the functions contained in this parent. |
||
34 | */ |
||
35 | public function getFunctions(): Collection |
||
36 | { |
||
37 | return $this->functions; |
||
38 | } |
||
39 | |||
40 | /** |
||
41 | * @return int The number of testable (not abstract) function in this parent. |
||
42 | */ |
||
43 | public function countNotAbstractFunctions(): int |
||
48 | } |
||
49 | } |
||
50 |