Conditions | 4 |
Paths | 4 |
Total Lines | 10 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
33 | public function hydrate(array $options): void |
||
34 | { |
||
35 | $methods = get_class_methods($this); |
||
36 | foreach ($options as $key => $value) { |
||
37 | if (is_null($value)) { |
||
38 | continue; |
||
39 | } |
||
40 | $method = $this->getSetterMethod($key); |
||
41 | if (in_array($method, $methods)) { |
||
42 | $this->$method($value); |
||
43 | } |
||
57 |