Conditions | 3 |
Paths | 3 |
Total Lines | 10 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
36 | public function create(ContainerInterface $container, string $id, array $argument): ArgumentParserInterface |
||
37 | { |
||
38 | // exit |
||
39 | switch ($argument['type']) { |
||
40 | case 'service': |
||
41 | return new Service($container, $id, $argument); |
||
42 | case 'value': |
||
43 | return new Value($argument); |
||
44 | default: |
||
45 | throw new Exception(sprintf('Unknown argument type "%s"', $argument['type'])); |
||
46 | } |
||
49 |