1 | <?php |
||
21 | final class HydrationContext implements HydrationContextInterface |
||
22 | { |
||
23 | |||
24 | /** |
||
25 | * @var object |
||
26 | */ |
||
27 | private $entity; |
||
28 | |||
29 | /** |
||
30 | * @var string |
||
31 | */ |
||
32 | private $entityClass; |
||
33 | |||
34 | /** |
||
35 | * @var array<string, mixed> |
||
36 | */ |
||
37 | private $registeredValues = array(); |
||
38 | |||
39 | /** |
||
40 | * @var array<int, mixed> |
||
41 | */ |
||
42 | private $hydrationStack = array(); |
||
43 | |||
44 | /** |
||
45 | * @var EntityManagerInterface |
||
46 | */ |
||
47 | private $entityManager; |
||
48 | |||
49 | /** |
||
50 | * @param object $entity |
||
51 | */ |
||
52 | 14 | public function __construct($entity, EntityManagerInterface $entityManager) |
|
65 | |||
66 | 1 | public function getEntity() |
|
70 | |||
71 | 2 | public function getEntityClass(): string |
|
75 | |||
76 | 1 | public function registerValue(string $id, $value): void |
|
80 | |||
81 | 1 | public function hasRegisteredValue(string $id): bool |
|
85 | |||
86 | 2 | public function getRegisteredValue(string $id) |
|
97 | |||
98 | 1 | public function getObjectHydrationStack(): array |
|
102 | |||
103 | 2 | public function pushOnObjectHydrationStack($value): void |
|
107 | |||
108 | 3 | public function popFromObjectHydrationStack() |
|
114 | |||
115 | 2 | public function getEntityManager(): EntityManagerInterface |
|
119 | |||
120 | } |
||
121 |