PHPackages                             weew/container-doctrine-integration - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. weew/container-doctrine-integration

ActiveLibrary

weew/container-doctrine-integration
===================================

Make doctrine repositories injectable in the weew/container.

v1.0.1(9y ago)0972MITPHP

Since Jan 15Pushed 9y ago1 watchersCompare

[ Source](https://github.com/weew/container-doctrine-integration)[ Packagist](https://packagist.org/packages/weew/container-doctrine-integration)[ RSS](/packages/weew-container-doctrine-integration/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (4)Versions (3)Used By (2)

Integration of doctrine repositories
====================================

[](#integration-of-doctrine-repositories)

[![Build Status](https://camo.githubusercontent.com/7227f5c5a5adfa3c7d5c20f3069a6ec92c0fe579778f8ea748f9f44784594d04/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f776565772f636f6e7461696e65722d646f637472696e652d696e746567726174696f6e2e737667)](https://travis-ci.org/weew/container-doctrine-integration)[![Code Quality](https://camo.githubusercontent.com/5eaeea2a570c91dc75f2cd4c885c34e4849646eb03ab07bbc9e0378dcf3343af/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f776565772f636f6e7461696e65722d646f637472696e652d696e746567726174696f6e2e737667)](https://scrutinizer-ci.com/g/weew/container-doctrine-integration)[![Test Coverage](https://camo.githubusercontent.com/18555c33963bb6bafd896eaaf165f400734643b3e9283bd2bb5431c8e8f3fb4f/68747470733a2f2f696d672e736869656c64732e696f2f636f766572616c6c732f776565772f636f6e7461696e65722d646f637472696e652d696e746567726174696f6e2e737667)](https://coveralls.io/github/weew/container-doctrine-integration)[![Version](https://camo.githubusercontent.com/c731abfc6e6eb0b98d909f0f3135b2387fb10ed773a66984db9cc865d0ba8ff3/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f776565772f636f6e7461696e65722d646f637472696e652d696e746567726174696f6e2e737667)](https://packagist.org/packages/weew/container-doctrine-integration)[![Licence](https://camo.githubusercontent.com/1b4a38df3cbb3ba0fb8df621e66cfaea1eb5bdbaf614aed1bc9f568cd994d3d5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f776565772f636f6e7461696e65722d646f637472696e652d696e746567726174696f6e2e737667)](https://packagist.org/packages/weew/container-doctrine-integration)

Table of contents
-----------------

[](#table-of-contents)

- [Installation](#installation)
- [Introduction](#introduction)
- [Conventions](#conventions)
- [Usage](#usage)

Installation
------------

[](#installation)

`composer require weew/container-doctrine-integration`

Introduction
------------

[](#introduction)

Doctrine repositories are not injectable on their own since they are not easily instantiable. To make it work you'll have to work with factories do some argument parsing and so on. This is exactly what this package does, it makes doctrine repositories injectable trough the [weew/container](https://github.com/weew/container) container.

Conventions
-----------

[](#conventions)

There are certain conventions that you must follow to be able to inject doctrine repositories. Repositories loader does this kind of repository name to entity name conversion: `Vendor\Package\Repositories\FooRepository` should map to this entity `Vendor\Package\Entities\Foo`.

If this name matching strategy is not sufficient for you, you may provide your own implementation of the `IRepositoryNameParser` interface.

Usage
-----

[](#usage)

To make repositories injectable simply create a new instance of `IDoctrineRepositoriesLoader`, pass in an instance of `IContainer` and an instance `ObjectManager` and enable it.

```
$loader = new DoctrineRepositoriesLoader($container, $om);
$loader->enable();
```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity64

Established project with proven stability

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~187 days

Total

2

Last Release

3580d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/10b2b854b5829dd13a15967c000ed2119b5faef67aca24d94c653c8ac550d85e?d=identicon)[weew](/maintainers/weew)

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/weew-container-doctrine-integration/health.svg)

```
[![Health](https://phpackages.com/badges/weew-container-doctrine-integration/health.svg)](https://phpackages.com/packages/weew-container-doctrine-integration)
```

###  Alternatives

[sonata-project/entity-audit-bundle

Audit for Doctrine Entities

644989.8k1](/packages/sonata-project-entity-audit-bundle)[neos/flow

Flow Application Framework

862.0M451](/packages/neos-flow)[api-platform/doctrine-orm

Doctrine ORM bridge

243.1M39](/packages/api-platform-doctrine-orm)[neos/flow-development-collection

Flow packages in a joined repository for pull requests.

144179.3k3](/packages/neos-flow-development-collection)[pixelfederation/doctrine-resettable-em-bundle

Symfony bundle for decorating default entity managers using a resettable decorator.

20113.5k](/packages/pixelfederation-doctrine-resettable-em-bundle)[leapt/core-bundle

Symfony LeaptCoreBundle

2529.1k4](/packages/leapt-core-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
