Total Complexity | 6 |
Total Lines | 40 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
25 | class MethodsBuilder |
||
26 | { |
||
27 | /** @param \PhpParser\Node\Stmt\Class_|\PhpParser\Node\Stmt\Interface_ $definition */ |
||
28 | public function build($definition): array |
||
33 | } |
||
34 | |||
35 | public function buildMethod(ClassMethod $method): array |
||
36 | { |
||
37 | return [ |
||
38 | $method->name, |
||
39 | $this->resolveVisibility($method), |
||
40 | $this->buildParameters($method->params), |
||
41 | $method->getDocComment(), |
||
42 | ]; |
||
43 | } |
||
44 | |||
45 | private function resolveVisibility(ClassMethod $statement): string |
||
54 | } |
||
55 | } |
||
56 | |||
57 | private function buildParameters(array $parameters): array |
||
67 |