Passed
Push — master ( 1a17c3...faad8c )
by
unknown
01:09
created

DataContainerFactory::create()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
ccs 2
cts 2
cp 1
crap 1
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * Copyright MediaCT. All rights reserved.
4
 * https://www.mediact.nl
5
 */
6
7
namespace Mediact\DataContainer;
8
9
/**
10
 * Creates data containers.
11
 */
12
class DataContainerFactory implements DataContainerFactoryInterface
13
{
14
    /**
15
     * Create a data container.
16
     *
17
     * @param array $data
18
     *
19
     * @return DataContainerInterface
20
     */
21 1
    public function create(array $data = []): DataContainerInterface
22
    {
23 1
        return new DataContainer($data);
24
    }
25
}
26