Ejemplo n.º 1
0
 /**
  * @param ContainerBuilder $container
  */
 private function addRegisterMappingsPass(ContainerBuilder $container)
 {
     $mappings = [realpath(__DIR__ . '/Resources/config/doctrine/model') => 'FDevs\\CatalogBundle\\Model'];
     if (class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, ['f_devs_catalog.model_manager_name'], 'f_devs_catalog.backend_type_mongodb'));
     }
 }
 private function addRegisterMappingPass(ContainerBuilder $container)
 {
     $mappings = array(realpath(__DIR__ . '/Resources/config/doctrine/model') => 'Solilokiam\\SummernoteBundle\\Model');
     $ormCompilerClass = 'Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass';
     if (class_exists($ormCompilerClass)) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, array('doctrine.orm.entity_manager'), 'fos_user.backend_type_orm'));
     }
     $mongoCompilerClass = 'Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass';
     if (class_exists($mongoCompilerClass)) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array('doctrine.odm.mongodb.document_manager'), 'fos_user.backend_type_mongodb'));
     }
 }
Ejemplo n.º 3
0
 /**
  * @param ContainerBuilder $container
  */
 private function addRegisterMappingsPass(ContainerBuilder $container)
 {
     $mappings = [realpath(__DIR__ . '/Resources/config/doctrine') => 'HMLB\\DDD'];
     if (class_exists('Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass')) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, ['fos_user.model_manager_name'], 'fos_user.backend_type_orm'));
     }
     if (class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, ['fos_user.model_manager_name'], 'fos_user.backend_type_mongodb'));
     }
     if (class_exists('Doctrine\\Bundle\\CouchDBBundle\\DependencyInjection\\Compiler\\DoctrineCouchDBMappingsPass')) {
         $container->addCompilerPass(DoctrineCouchDBMappingsPass::createXmlMappingDriver($mappings, ['fos_user.model_manager_name'], 'fos_user.backend_type_couchdb'));
     }
 }
 private function addRegisterMappingsPass(ContainerBuilder $container)
 {
     $mappings = array(realpath(__DIR__ . '/Resources/config/model') => 'Bazinga\\OAuthServerBundle\\Model');
     if (class_exists('Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass')) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, array('bazinga.oauth.model_manager_name'), 'bazinga.oauth.backend_type_orm'));
     }
     if (class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array('bazinga.oauth.model_manager_name'), 'bazinga.oauth.backend_type_mongodb'));
     }
     if (class_exists('Doctrine\\Bundle\\CouchDBBundle\\DependencyInjection\\Compiler\\DoctrineCouchDBMappingsPass')) {
         $container->addCompilerPass(DoctrineCouchDBMappingsPass::createXmlMappingDriver($mappings, array('bazinga.oauth.model_manager_name'), 'bazinga.oauth.backend_type_couchdb'));
     }
 }
 /**
  * @param ContainerBuilder $container
  */
 private function addRegisterMappingsPass(ContainerBuilder $container)
 {
     if (false === class_exists('Symfony\\Bridge\\Doctrine\\DependencyInjection\\CompilerPass\\RegisterMappingsPass')) {
         throw new \LogicException('Missing RegisterMappingsPass available since symfony 2.3');
     }
     $mappings = array(realpath(__DIR__ . '/Resources/config/doctrine-mapping') => 'AerialShip\\SamlSPBundle\\Model');
     if (class_exists('Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass')) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, array('aerial_ship_saml_sp.model_manager_name'), 'aerial_ship_saml_sp.backend_type_orm'));
     }
     if (class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array('aerial_ship_saml_sp.model_manager_name'), 'aerial_ship_saml_sp.backend_type_mongodb'));
     }
 }
 public function build(ContainerBuilder $container)
 {
     $container->addCompilerPass(new ValidationPass());
     $symfonyVersion = class_exists('Symfony\\Bridge\\Doctrine\\DependencyInjection\\CompilerPass\\RegisterMappingsPass');
     $mappings = array(realpath(__DIR__ . '/Resources/config/doctrine-mapping') => 'Tanna\\ProductBundle\\Model');
     //Doctrine ORM
     if ($symfonyVersion && class_exists('Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass')) {
         //$container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings));
     }
     if ($symfonyVersion && class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array(), null, array("Tanna\\ProductBundle" => "")));
     }
 }
Ejemplo n.º 7
0
 public function build(ContainerBuilder $container)
 {
     parent::build($container);
     $container->addCompilerPass(new ValidationPass());
     $container->addCompilerPass(new DbPass());
     $mappings = array(realpath(__DIR__ . '/Resources/config/doctrine-mapping') => 'NyroDev\\NyroCmsBundle\\Model');
     if (class_exists('Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass')) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, array('nyrocms.model_manager_name')));
     }
     if (class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array('nyrocms.model_manager_name')));
     }
 }
 public function build(ContainerBuilder $container)
 {
     parent::build($container);
     $modelDir = realpath(__DIR__ . '/Resources/config/doctrine/model');
     $mappings = [$modelDir => 'Ivoaz\\Bundle\\ContentEditableBundle\\Model'];
     $ormCompilerClass = 'Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass';
     if (class_exists($ormCompilerClass)) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, ['ivoaz_content_editable.model_manager_name'], 'ivoaz_content_editable.model_type_orm', ['IvoazContentEditableBundle' => 'Symfony\\Cmf\\RoutingBundle\\Model']));
     }
     $mongoCompilerClass = 'Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass';
     if (class_exists($mongoCompilerClass)) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, ['ivoaz_content_editable.model_manager_name'], 'ivoaz_content_editable.model_type_mongodb', ['IvoazContentEditableBundle' => 'Symfony\\Cmf\\RoutingBundle\\Model']));
     }
 }
 public function build(ContainerBuilder $container)
 {
     parent::build($container);
     // ...
     $modelDir = realpath(__DIR__ . '/Resources/config/doctrine');
     $mappings = array($modelDir => 'TxTony\\ArrowDBConnectorBundle\\Model');
     $ormCompilerClass = 'Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass';
     if (class_exists($ormCompilerClass)) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, array('tx_tony_arrow_db_connector.model_manager_name'), 'tx_tony_arrow_db_connector.backend_type_orm'));
     }
     $mongoCompilerClass = 'Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass';
     if (class_exists($mongoCompilerClass)) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array('tx_tony_arrow_db_connector.model_manager_name'), 'tx_tony_arrow_db_connector.backend_type_mongodb'));
     }
 }
Ejemplo n.º 10
0
 /**
  * @param ContainerBuilder $container
  */
 private function addRegisterMappingsPass(ContainerBuilder $container)
 {
     // the base class is only available since symfony 2.3
     $symfonyVersion = class_exists('Symfony\\Bridge\\Doctrine\\DependencyInjection\\CompilerPass\\RegisterMappingsPass');
     $mappings = array(realpath(__DIR__ . '/Resources/config/doctrine/model') => 'TwoMartens\\Bundle\\CoreBundle\\Model');
     if ($symfonyVersion && class_exists('Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass')) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, array(), 'twomartens.core.backend_type_orm', array('TwoMartensCoreBundle' => 'TwoMartens\\Bundle\\CoreBundle\\Model')));
     }
     if ($symfonyVersion && class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array(), 'twomartens.core.backend_type_mongodb', array('TwoMartensCoreBundle' => 'TwoMartens\\Bundle\\CoreBundle\\Model')));
     }
     if ($symfonyVersion && class_exists('Doctrine\\Bundle\\CouchDBBundle\\DependencyInjection\\Compiler\\DoctrineCouchDBMappingsPass')) {
         $container->addCompilerPass(DoctrineCouchDBMappingsPass::createXmlMappingDriver($mappings, array(), 'twomartens.core.backend_type_couchdb', array('TwoMartensCoreBundle' => 'TwoMartens\\Bundle\\CoreBundle\\Model')));
     }
 }
Ejemplo n.º 11
0
 /**
  * @param ContainerBuilder $container
  */
 private function addRegisterMappingsPass(ContainerBuilder $container)
 {
     // the base class is only available since symfony 2.3
     $symfonyVersion = class_exists('Symfony\\Bridge\\Doctrine\\DependencyInjection\\CompilerPass\\RegisterMappingsPass');
     $mappings = array(realpath(__DIR__ . '/Resources/config/doctrine/model') => 'Leaphly\\Cart\\Model');
     if ($symfonyVersion && class_exists('Doctrine\\Bundle\\DoctrineBundle\\DependencyInjection\\Compiler\\DoctrineOrmMappingsPass')) {
         $container->addCompilerPass(DoctrineOrmMappingsPass::createXmlMappingDriver($mappings, array('leaphly_cart.model_manager_name'), 'leaphly_cart.backend_type_orm'));
     } else {
         $container->addCompilerPass(RegisterMappingsPass::createOrmMappingDriver($mappings));
     }
     if ($symfonyVersion && class_exists('Doctrine\\Bundle\\MongoDBBundle\\DependencyInjection\\Compiler\\DoctrineMongoDBMappingsPass')) {
         $container->addCompilerPass(DoctrineMongoDBMappingsPass::createXmlMappingDriver($mappings, array('leaphly_cart.model_manager_name'), 'leaphly_cart.backend_type_mongodb'));
     } else {
         $container->addCompilerPass(RegisterMappingsPass::createMongoDBMappingDriver($mappings));
     }
 }