RegistryInterface
interface RegistryInterface implements ManagerRegistry
References Doctrine connections and entity managers.
Methods
Gets the default entity manager name.
Gets a named entity manager.
Gets an array of all registered entity managers.
Resets a named entity manager.
Resolves a registered namespace alias to the full namespace.
Gets all connection names.
Gets the entity manager associated with a given class.
Details
at line line 29
string
getDefaultEntityManagerName()
Gets the default entity manager name.
at line line 38
EntityManager
getEntityManager(string $name = null)
Gets a named entity manager.
at line line 45
array
getEntityManagers()
Gets an array of all registered entity managers.
at line line 64
EntityManager
resetEntityManager(string $name = null)
Resets a named entity manager.
This method is useful when an entity manager has been closed because of a rollbacked transaction AND when you think that it makes sense to get a new one to replace the closed one.
Be warned that you will get a brand new entity manager as the existing one is not useable anymore. This means that any other object with a dependency on this entity manager will hold an obsolete reference. You can inject the registry instead to avoid this problem.
at line line 77
string
getEntityNamespace(string $alias)
Resolves a registered namespace alias to the full namespace.
This method looks for the alias in all registered entity managers.
at line line 84
array
getEntityManagerNames()
Gets all connection names.
at line line 93
EntityManager|null
getEntityManagerForClass(string $class)
Gets the entity manager associated with a given class.