class RegisterMappingsPass implements CompilerPassInterface
Base class for the doctrine bundles to provide a compiler pass class that helps to register doctrine mappings.
The compiler pass is meant to register the mappings with the metadata chain driver corresponding to one of the object managers.
For concrete implementations that are easy to use, see the RegisterXyMappingsPass classes in the DoctrineBundle resp. DoctrineMongodbBundle, DoctrineCouchdbBundle and DoctrinePhpcrBundle.
Methods
__construct(Definition|Reference $driver, array $namespaces, array $managerParameters, string $driverPattern, string|false $enabledParameter = false, string $configurationPattern = '', string $registerAliasMethodName = '', array $aliasMap = array()) Constructor. | ||
process(ContainerBuilder $container) Register mappings and alias with the metadata drivers. |
Details
__construct(Definition|Reference $driver, array $namespaces, array $managerParameters, string $driverPattern, string|false $enabledParameter = false, string $configurationPattern = '', string $registerAliasMethodName = '', array $aliasMap = array())
Constructor.
The $managerParameters is an ordered list of container parameters that could provide the name of the manager to register these namespaces and alias on. The first non-empty name is used, the others skipped.
The $aliasMap parameter can be used to define bundle namespace shortcuts like the DoctrineBundle provides automatically for objects in the default Entity/Document folder.
process(ContainerBuilder $container)
Register mappings and alias with the metadata drivers.
Please login to continue.