1 | <?php |
||
14 | final class Denormalizer implements DenormalizerInterface |
||
15 | { |
||
16 | /** |
||
17 | * @var DenormalizerObjectMappingRegistryInterface |
||
18 | */ |
||
19 | private $denormalizerObjectMappingRegistry; |
||
20 | |||
21 | /** |
||
22 | * @var LoggerInterface |
||
23 | */ |
||
24 | private $logger; |
||
25 | |||
26 | /** |
||
27 | * @param DenormalizerObjectMappingRegistryInterface $denormalizerObjectMappingRegistry |
||
28 | * @param LoggerInterface|null $logger |
||
29 | */ |
||
30 | 9 | public function __construct( |
|
37 | |||
38 | /** |
||
39 | * @param object|string $object |
||
40 | * @param array $data |
||
41 | * @param DenormalizerContextInterface|null $context |
||
42 | * @param string $path |
||
43 | * |
||
44 | * @return object |
||
45 | * |
||
46 | * @throws DeserializerLogicException |
||
47 | * @throws DeserializerRuntimeException |
||
48 | */ |
||
49 | 9 | public function denormalize($object, array $data, DenormalizerContextInterface $context = null, string $path = '') |
|
80 | |||
81 | /** |
||
82 | * @param string $class |
||
83 | * |
||
84 | * @return DenormalizationObjectMappingInterface |
||
85 | * |
||
86 | * @throws DeserializerLogicException |
||
87 | */ |
||
88 | 9 | private function getObjectMapping(string $class): DenormalizationObjectMappingInterface |
|
98 | |||
99 | /** |
||
100 | * @param DenormalizerContextInterface $context |
||
101 | * @param DenormalizationFieldMappingInterface $denormalizationFieldMapping |
||
102 | * @param string $path |
||
103 | * @param array $data |
||
104 | * @param object $object |
||
105 | */ |
||
106 | 8 | private function denormalizeField( |
|
130 | |||
131 | /** |
||
132 | * @param string $path |
||
133 | * @param array $names |
||
134 | */ |
||
135 | 1 | private function handleNotAllowedAdditionalFields(string $path, array $names) |
|
145 | |||
146 | /** |
||
147 | * @param DenormalizerContextInterface $context |
||
148 | * @param DenormalizationFieldMappingInterface $fieldMapping |
||
149 | * |
||
150 | * @return bool |
||
151 | */ |
||
152 | 7 | private function isWithinGroup( |
|
168 | |||
169 | /** |
||
170 | * @param string $path |
||
171 | * @param string $name |
||
172 | * |
||
173 | * @return string |
||
174 | */ |
||
175 | 6 | private function getSubPathByName(string $path, string $name): string |
|
179 | |||
180 | /** |
||
181 | * @param string $path |
||
182 | * @param array $names |
||
183 | * |
||
184 | * @return array |
||
185 | */ |
||
186 | 1 | private function getSubPathsByNames(string $path, array $names): array |
|
195 | } |
||
196 |