| Total Complexity | 6 |
| Total Lines | 56 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 5 | ||
| Bugs | 4 | Features | 2 |
| 1 | <?php |
||
| 13 | final class ReferenceOneFieldDenormalizer implements FieldDenormalizerInterface |
||
| 14 | { |
||
| 15 | /** |
||
| 16 | * @var callable |
||
| 17 | */ |
||
| 18 | private $repository; |
||
| 19 | |||
| 20 | /** |
||
| 21 | * @var AccessorInterface |
||
| 22 | */ |
||
| 23 | private $accessor; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @var bool |
||
| 27 | */ |
||
| 28 | private $emptyToNull; |
||
| 29 | |||
| 30 | public function __construct(callable $repository, AccessorInterface $accessor, bool $emptyToNull = false) |
||
| 31 | { |
||
| 32 | $this->repository = $repository; |
||
| 33 | $this->accessor = $accessor; |
||
| 34 | $this->emptyToNull = $emptyToNull; |
||
| 35 | 6 | } |
|
| 36 | |||
| 37 | 6 | /** |
|
| 38 | 6 | * @param object $object |
|
| 39 | 6 | * @param mixed $value |
|
| 40 | 6 | * |
|
| 41 | * @throws DeserializerRuntimeException |
||
| 42 | */ |
||
| 43 | public function denormalizeField( |
||
| 69 | } |
||
| 70 | } |
||
| 71 |