Delegate::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 4
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 5
ccs 4
cts 4
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
crap 1
1
<?php declare(strict_types=1);
2
3
namespace Phact\Container\Delegate;
4
5
use Psr\Container\ContainerInterface;
6
7
class Delegate
8
{
9
    /**
10
     * @var ContainerInterface
11
     */
12
    private $container;
13
    /**
14
     * @var bool
15
     */
16
    private $applyInflection;
17
18 2
    public function __construct(ContainerInterface $container, bool $applyInflection)
19
    {
20 2
        $this->container = $container;
21 2
        $this->applyInflection = $applyInflection;
22 2
    }
23
24
    /**
25
     * @return ContainerInterface
26
     */
27 2
    public function getContainer(): ContainerInterface
28
    {
29 2
        return $this->container;
30
    }
31
32
    /**
33
     * @return bool
34
     */
35 1
    public function isApplyInflection(): bool
36
    {
37 1
        return $this->applyInflection;
38
    }
39
}
40