class ObjectValidationAndDeDuplicationListener (View source)

An onFlush listener for Flow's Doctrine PersistenceManager.

Used to de-duplicate value objects and validate new and updated objects during flush.

Properties

protected ValidatorResolver $validatorResolver
protected ReflectionService $reflectionService
protected PersistenceManager $persistenceManager
protected EntityManagerInterface $entityManager

Methods

void
onFlush(OnFlushEventArgs $eventArgs)

An onFlush event listener used to act upon persistence.

Details

void onFlush(OnFlushEventArgs $eventArgs)

An onFlush event listener used to act upon persistence.

Parameters

OnFlushEventArgs $eventArgs

Return Value

void

Exceptions

ObjectValidationFailedException