class EntityManagerFactory (View source)

EntityManager factory for Doctrine integration

Properties

protected ObjectManagerInterface $objectManager
protected ReflectionService $reflectionService
protected Environment $environment
protected array $settings

Methods

void
injectSettings(array $settings)

Injects the Flow settings, the persistence part is kept for further use.

EntityManager
create()

Factory method which creates an EntityManager.

emitBeforeDoctrineEntityManagerCreation(Connection $connection, Configuration $config, EventManager $eventManager)

No description

emitAfterDoctrineEntityManagerCreation(Configuration $config, EntityManager $entityManager)

No description

Configuration
enableSqlLogger(string $configuredSqlLogger, Configuration $doctrineConfiguration)

The logger middleware needs to be set on the configuration applied to the Driver and Connection

Details

void injectSettings(array $settings)

Injects the Flow settings, the persistence part is kept for further use.

Parameters

array $settings

Return Value

void

Exceptions

InvalidConfigurationException

EntityManager create()

Factory method which creates an EntityManager.

Return Value

EntityManager

Exceptions

InvalidConfigurationException

emitBeforeDoctrineEntityManagerCreation(Connection $connection, Configuration $config, EventManager $eventManager)

No description

Parameters

Connection $connection
Configuration $config
EventManager $eventManager

emitAfterDoctrineEntityManagerCreation(Configuration $config, EntityManager $entityManager)

No description

Parameters

Configuration $config
EntityManager $entityManager

protected Configuration enableSqlLogger(string $configuredSqlLogger, Configuration $doctrineConfiguration)

The logger middleware needs to be set on the configuration applied to the Driver and Connection

Parameters

string $configuredSqlLogger
Configuration $doctrineConfiguration

Return Value

Configuration

Exceptions

InvalidConfigurationException