ItemFactory::make()   A
last analyzed

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 1
Bugs 0 Features 1
Metric Value
eloc 1
c 1
b 0
f 1
dl 0
loc 3
ccs 2
cts 2
cp 1
rs 10
cc 1
nc 1
nop 2
crap 1
1
<?php
2
3
4
namespace Hexogen\KDTree;
5
6
use Hexogen\KDTree\Interfaces\ItemFactoryInterface;
7
use Hexogen\KDTree\Interfaces\ItemInterface;
8
9
class ItemFactory implements ItemFactoryInterface
10
{
11
    /**
12
     * @api
13
     * @param int $id
14
     * @param array $dValues
15
     * @return ItemInterface
16
     */
17 18
    public function make(int $id, array $dValues) : ItemInterface
18
    {
19 18
        return new Item($id, $dValues);
20
    }
21
}
22