| Conditions | 3 |
| Paths | 3 |
| Total Lines | 12 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 12 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 14 | public function __construct( |
||
| 15 | ContainerInterface $container = null, |
||
| 16 | array $definitions = [], |
||
| 17 | bool $validate = true |
||
| 18 | ) { |
||
| 19 | $this->dependencyResolver = new DependencyResolver($container); |
||
| 20 | |||
| 21 | foreach ($definitions as $id => $definition) { |
||
| 22 | if ($validate) { |
||
| 23 | DefinitionValidator::validate($definition, $id); |
||
| 24 | } |
||
| 25 | $this->dependencyResolver->set($id, $definition); |
||
|
|
|||
| 26 | } |
||
| 39 |