| @@ 26-32 (lines=7) @@ | ||
| 23 | * @param object $object |
|
| 24 | * @param mixed $value |
|
| 25 | */ |
|
| 26 | public function setValue($object, $value) |
|
| 27 | { |
|
| 28 | $reflectionProperty = new \ReflectionProperty(get_class($object), $this->property); |
|
| 29 | $reflectionProperty->setAccessible(true); |
|
| 30 | ||
| 31 | $reflectionProperty->setValue($object, $value); |
|
| 32 | } |
|
| 33 | ||
| 34 | /** |
|
| 35 | * @param object $object |
|
| @@ 39-45 (lines=7) @@ | ||
| 36 | * |
|
| 37 | * @return mixed |
|
| 38 | */ |
|
| 39 | public function getValue($object) |
|
| 40 | { |
|
| 41 | $reflectionProperty = new \ReflectionProperty(get_class($object), $this->property); |
|
| 42 | $reflectionProperty->setAccessible(true); |
|
| 43 | ||
| 44 | return $reflectionProperty->getValue($object); |
|
| 45 | } |
|
| 46 | } |
|
| 47 | ||