HydrationCompleteHandler
in package
FinalYes
Class, which can handle completion of hydration cycle and produce some of tasks.
In current implementation triggers deferred postLoad event.
Table of Contents
Properties
- $deferredPostLoadInvocations : array<string|int, array<string|int, mixed>>
- $em : EntityManagerInterface
- $listenersInvoker : ListenersInvoker
Methods
- __construct() : mixed
- Constructor for this object
- deferPostLoadInvoking() : void
- Method schedules invoking of postLoad entity to the very end of current hydration cycle.
- hydrationComplete() : void
- This method should be called after any hydration cycle completed.
Properties
$deferredPostLoadInvocations
private
array<string|int, array<string|int, mixed>>
$deferredPostLoadInvocations
= []
$em
private
EntityManagerInterface
$em
$listenersInvoker
private
ListenersInvoker
$listenersInvoker
Methods
__construct()
Constructor for this object
public
__construct(ListenersInvoker $listenersInvoker, EntityManagerInterface $em) : mixed
Parameters
- $listenersInvoker : ListenersInvoker
- $em : EntityManagerInterface
deferPostLoadInvoking()
Method schedules invoking of postLoad entity to the very end of current hydration cycle.
public
deferPostLoadInvoking(ClassMetadata $class, object $entity) : void
Parameters
- $class : ClassMetadata
- $entity : object
hydrationComplete()
This method should be called after any hydration cycle completed.
public
hydrationComplete() : void
Method fires all deferred invocations of postLoad events