Conditions | 2 |
Paths | 2 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 8 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
24 | 7 | public function getConditions(ReflectionClass $class, Reader $reader, array $contracts = []) |
|
25 | { |
||
26 | 7 | $parentClass = $class->getParentClass(); |
|
27 | |||
28 | 7 | if (!$parentClass) { |
|
29 | 7 | return $contracts; |
|
30 | } |
||
31 | |||
32 | 4 | $annotations = $reader->getClassAnnotations($parentClass); |
|
33 | 4 | $contractAnnotations = $this->getContractAnnotations($annotations); |
|
34 | 4 | $contracts = array_merge($contracts, $contractAnnotations); |
|
35 | |||
36 | 4 | return $this->getConditions($parentClass, $reader, $contracts); |
|
37 | } |
||
38 | } |
||
39 |