Conditions | 2 |
Paths | 2 |
Total Lines | 13 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 8 |
CRAP Score | 2 |
Changes | 6 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
21 | 25 | public function __call($method, $parameters = []) |
|
22 | { |
||
23 | 25 | if (isset($this->customServices[$method])) { |
|
24 | 13 | return $this->customServices[$method]; |
|
25 | } |
||
26 | |||
27 | 25 | $docBlockResolver = DocBlockResolver::fromCaller($this); |
|
28 | 25 | $resolvable = $docBlockResolver->getDocBlockResolvable($method); |
|
29 | |||
30 | 23 | $this->customServices[$method] = (new DocBlockServiceResolver($resolvable->resolvableType())) |
|
31 | 23 | ->resolve($resolvable->className()); |
|
32 | |||
33 | 23 | return $this->customServices[$method]; |
|
34 | } |
||
36 |