| Conditions | 3 |
| Paths | 3 |
| Total Lines | 10 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 70 | public function exchangeArray(array $data) |
||
| 71 | { |
||
| 72 | $reflection = new ReflectionClass($this); |
||
| 73 | $properties = $reflection->getProperties(); |
||
| 74 | |||
| 75 | foreach ($properties as $property) { |
||
| 76 | $propertyName = $property->getName(); |
||
| 77 | |||
| 78 | if (isset($data[$propertyName])) { |
||
| 79 | $this->{$propertyName} = $data[$propertyName]; |
||
| 80 | } |
||
| 84 |