Conditions | 3 |
Paths | 3 |
Total Lines | 23 |
Code Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Tests | 15 |
CRAP Score | 3.0021 |
Changes | 0 |
1 | <?php |
||
32 | 1 | public function methods($service) |
|
33 | { |
||
34 | 1 | $resolution = $this->construcrtorResolver->resolve($service); |
|
35 | |||
36 | 1 | foreach ($service->getMethods() as $methodName => $value) { |
|
37 | 1 | $argument = Objects\Argument::fromString($value); |
|
38 | |||
39 | 1 | if ($argument->isService()) { |
|
40 | 1 | $collabortor = Objects\Service::box(array( |
|
41 | 1 | 'name' => $argument->getServiceName(), |
|
42 | 1 | 'services' => $service->getServicesConfiguration(), |
|
43 | 1 | )); |
|
44 | |||
45 | 1 | $resolution->$methodName( |
|
46 | 1 | $this->construcrtorResolver->resolve($collabortor) |
|
47 | 1 | ); |
|
48 | 1 | } else { |
|
49 | $resolution->$methodName($value); |
||
50 | } |
||
51 | 1 | } |
|
52 | |||
53 | 1 | return $resolution; |
|
54 | } |
||
55 | } |
||
56 |