2017 © Pedro Peláez
 

library doctrine-manager-registry-silex-provider

image

cranberyxl/doctrine-manager-registry-silex-provider

  • Monday, February 11, 2013
  • by cranberyxl
  • Repository
  • 1 Watchers
  • 0 Stars
  • 92 Installations
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Doctrine MangagerRegistry Silex Service Provider

Provides the ability to build 1 or more Doctrine ManafgerRegistries for use in your Silex project., (*1)

Composer

{
    "require": {
        "cranberyxl/doctrine-manager-registry-provider": "*"
    }
}

Register

``` php <?php, (*2)

use Silex\Provider\DoctrineManagerRegistryServiceProvider;, (*3)

$app = new Silex\Application();, (*4)

$app->register(new DoctrineManagerRegistryServiceProvider(), array( 'doctrine.common.manager_registry.definitions' => array( 'mongodb' => array( 'connections' => array('default' => 'doctrine.mongodb.connection'), 'managers' => array('default' => 'doctrine.mongodb.dm'), 'default_connection' => 'default', 'default_manager' => 'default', 'proxy_interface_name' => 'Doctrine\ODM\MongoDB\Proxy\Proxy' // Defaults to Doctrine\Common\Proxy ) ), ));, (*5)


## Use ```php $app['form.document_type'] = $app->share(function(Application $app) { return new DocumentType($app['doctrine.common.manager_registry.map']['mongodb']); });

The Versions

11/02 2013

dev-master

9999999-dev

  Sources   Download

MIT

The Requires

 

The Development Requires

by Andy Stanberry

silex doctrine manager registry