Completed
Branch 0.4-dev (f2f961)
by Evgenij
02:48
created

NullIoHandler::handleOperation()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 7
ccs 2
cts 2
cp 1
rs 9.4285
cc 1
eloc 4
nc 1
nop 3
crap 1
1
<?php
2
/**
3
 * Async sockets
4
 *
5
 * @copyright Copyright (c) 2015-2016, Efimov Evgenij <[email protected]>
6
 *
7
 * This source file is subject to the MIT license that is bundled
8
 * with this source code in the file LICENSE.
9
 */
10
namespace AsyncSockets\RequestExecutor\Pipeline;
11
12
use AsyncSockets\Operation\NullOperation;
13
use AsyncSockets\Operation\OperationInterface;
14
use AsyncSockets\RequestExecutor\EventHandlerInterface;
15
use AsyncSockets\RequestExecutor\Metadata\RequestDescriptor;
16
use AsyncSockets\RequestExecutor\RequestExecutorInterface;
17
18
/**
19
 * Class NullIoHandler
20
 */
21
class NullIoHandler extends AbstractOobHandler
22
{
23
    /**
24
     * @inheritDoc
25
     */
26 1
    public function supports(OperationInterface $operation)
27
    {
28 1
        return $operation instanceof NullOperation;
29
    }
30
31
    /**
32
     * @inheritDoc
33
     */
34 1
    protected function handleOperation(
35
        RequestDescriptor $descriptor,
36
        RequestExecutorInterface $executor,
37
        EventHandlerInterface $eventHandler
38
    ) {
39
        // empty body
40 1
    }
41
}
42