Completed
Push — master ( 2cee6a...9d457f )
by Jesse
03:27
created

ArrayHydrator   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 13
rs 10
c 0
b 0
f 0
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A fromArray() 0 3 1
A create() 0 3 1
A currentInstance() 0 1 1
1
<?php
2
3
declare(strict_types = 1);
4
5
namespace Stratadox\Hydration\Hydrator;
6
7
use Stratadox\Hydration\Hydrates;
8
9
/**
10
 * Hydrates an array. Since the input is already array, do nothing, really.
11
 *
12
 * @package Stratadox\Hydrate
13
 * @author Stratadox
14
 */
15
final class ArrayHydrator implements Hydrates
16
{
17
    public static function create() : Hydrates
18
    {
19
        return new ArrayHydrator;
20
    }
21
22
    public function fromArray(array $input)
23
    {
24
        return $input;
25
    }
26
27
    public function currentInstance() {}
28
}
29