Conditions | 4 |
Paths | 4 |
Total Lines | 15 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
44 | public function matches($criteria) |
||
45 | { |
||
46 | $result = true; |
||
47 | |||
48 | foreach ($criteria as $name => $value) { |
||
49 | if (!array_key_exists($name, $this->fields)) { |
||
50 | $result = false; |
||
51 | break; |
||
52 | } |
||
53 | |||
54 | $result = $result && $this->fields[$name]->matches($value); |
||
55 | } |
||
56 | |||
57 | return $result; |
||
58 | } |
||
59 | } |
||
60 |
This check compares the return type specified in the
@return
annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.