Conditions | 3 |
Paths | 3 |
Total Lines | 16 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Tests | 9 |
CRAP Score | 3 |
Changes | 0 |
1 | <?php |
||
20 | 14 | public function __invoke(Method $method, Readable $arguments): StreamInterface |
|
21 | { |
||
22 | switch (true) { |
||
23 | 14 | case Methods::get('exchange.declare-ok')->equals($method): |
|
24 | 6 | $chunk = $this->declareOk(); |
|
25 | 6 | break; |
|
26 | |||
27 | 8 | case Methods::get('exchange.delete-ok')->equals($method): |
|
28 | 6 | $chunk = $this->deleteOk(); |
|
29 | 6 | break; |
|
30 | |||
31 | default: |
||
32 | 2 | throw new UnknownMethod($method); |
|
33 | } |
||
34 | |||
35 | 12 | return $chunk($arguments); |
|
36 | } |
||
48 |