| Total Complexity | 6 |
| Total Lines | 26 |
| Duplicated Lines | 0 % |
| Coverage | 91.67% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 11 | class CallableDefinition implements DefinitionInterface |
||
| 12 | { |
||
| 13 | private $method; |
||
| 14 | |||
| 15 | 2 | public function __construct($method) |
|
| 18 | 2 | } |
|
| 19 | |||
| 20 | 2 | public function resolve(ContainerInterface $container) |
|
| 21 | { |
||
| 22 | 2 | $callable = $this->prepareCallable($this->method, $container); |
|
| 23 | |||
| 24 | 2 | return $container->get(Injector::class)->invoke($callable); |
|
| 25 | } |
||
| 26 | |||
| 27 | 2 | private function prepareCallable($callable, ContainerInterface $container): callable |
|
| 37 | } |
||
| 38 | } |
||
| 39 |