src/Entity/Factory/EntityFactory.php
private function addListenerToEntityIfRequired(EntityInterface $entity): void
    {
        if (!$entity instanceof NotifyPropertyChanged) {
            return;
        }
        $listener = $this->entityManager->getUnitOfWork();
        $entity->addPropertyChangedListener($listener);
    }
private function addListenerToEntityIfRequired(EntityInterface $entity): void
    {
        if (!$entity instanceof NotifyPropertyChanged) {
            return;
        }
        $listener = $this->entityManager->getUnitOfWork();
        $entity->addPropertyChangedListener($listener);
    }
private function addListenerToEntityIfRequired ( EntityInterface $ entity ) : void { if ( ! $ entity instanceof NotifyPropertyChanged ) { return ; } $ listener = $ this -> entityManager -> getUnitOfWork ( ) ; $ entity -> addPropertyChangedListener ( $ listener ) ; }
Generally DSM Entities are using the Notify change tracking policy.
This ensures that they are fully set up for that

@param EntityInterface $entity
Generally DSM Entities are using the Notify change tracking policy . This ensures that they are fully set up for that