Inject::__construct()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0
cc 2
eloc 2
nc 2
nop 1
crap 2
1
<?php
2
namespace Acelaya\ZsmAnnotatedServices\Annotation;
3
4
use Doctrine\Common\Annotations\Annotation;
5
6
/**
7
 * Class Inject
8
 * @author
9
 * @link
10
 * @Annotation
11
 * @Target({"METHOD"})
12
 */
13
class Inject
14
{
15
    /**
16
     * @var array
17
     */
18
    private $services;
19
20
    /**
21
     * Inject constructor.
22
     * @param array $values
23
     */
24 5
    public function __construct(array $values)
25
    {
26 5
        $this->services = isset($values['value']) ? $values['value'] : [];
27 5
    }
28
29
    /**
30
     * @return array
31
     */
32 7
    public function getServices()
33
    {
34 7
        return $this->services;
35
    }
36
}
37