sergiors / doctrine-orm-service-provider
Doctrine ORM for Pimple
1.0.0
2017-12-11 01:35 UTC
Requires
- php: ^7.0
- doctrine/orm: ~2.5
- pimple/pimple: ^3.0
- sergiors/doctrine-cache-service-provider: ^3
Requires (Dev)
- pdepend/pdepend: ~2.0
- phing/phing: ~2.10
- phploc/phploc: ^4
- phpmd/phpmd: ~2.2
- phpunit/phpunit: ^6
- sebastian/phpcpd: ~2.0
- silex/silex: ^2.2
- squizlabs/php_codesniffer: ~2.1
This package is not auto-updated.
Last update: 2024-11-08 15:18:08 UTC
README
Install
composer require sergiors/doctrine-orm-service-provider "dev-master"
How to use
Something like this
use Silex\Provider\DoctrineServiceProvider; use Sergiors\Pimple\Provider\DoctrineOrmServiceProvider; use Sergiors\Pimple\Provider\DoctrineCacheServiceProvider; $app->register(new DoctrineServiceProvider(), [ // your db config ]); $app->register(new DoctrineCacheServiceProvider()); $app->register(new DoctrineOrmServiceProvider(), [ 'orm.proxy_dir' => '', 'orm.proxy_namespace' => '' ]); $app['orm']->getRepository('Namespace\Entity\User')->findAll();
License
MIT