NoopHydrator   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 0
dl 0
loc 13
ccs 0
cts 4
cp 0
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A hydrate() 0 4 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This software may be modified and distributed under the terms
7
 * of the MIT license. See the LICENSE file for details.
8
 */
9
10
namespace FAPI\PhraseApp\Hydrator;
11
12
use Psr\Http\Message\ResponseInterface;
13
14
/**
15
 * Do not hydrate to any object at all.
16
 *
17
 * @author Sascha-Oliver Prolic <[email protected]>
18
 */
19
final class NoopHydrator implements Hydrator
20
{
21
    /**
22
     * @param ResponseInterface $response
23
     * @param string            $class
24
     *
25
     * @throws \LogicException
26
     */
27
    public function hydrate(ResponseInterface $response, string $class)
28
    {
29
        throw new \LogicException('The Noop Hydrator should never be called');
30
    }
31
}
32