Completed
Push — master ( d10f54...00ced4 )
by
unknown
05:32
created

ConstantReference   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 0
dl 0
loc 23
rs 10
c 0
b 0
f 0
ccs 5
cts 5
cp 1

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getValue() 0 4 1
1
<?php declare(strict_types = 1);
2
/**
3
 * Created by PhpStorm.
4
 * User: root
5
 * Date: 02.08.16
6
 * Time: 0:46.
7
 */
8
namespace samsonframework\container\definition\reference;
9
10
/**
11
 * Class ConstantReference
12
 *
13
 * @author Ruslan Molodyko <[email protected]>
14
 */
15
class ConstantReference implements ReferenceInterface
16
{
17
    /** @var string Value of reference */
18
    protected $value;
19
20
    /**
21
     * StringReference constructor.
22
     *
23
     * @param string $value
24
     */
25 6
    public function __construct(string $value)
26
    {
27 6
        $this->value = $value;
28 6
    }
29
30
    /**
31
     * @return string
32
     */
33 2
    public function getValue(): string
34
    {
35 2
        return $this->value;
36
    }
37
}
38