Passed
Push — master ( 559900...ef8c69 )
by Alexey
10:10
created

ContainerProxy   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 34
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
dl 0
loc 34
ccs 0
cts 12
cp 0
rs 10
c 0
b 0
f 0
wmc 3
lcom 0
cbo 1

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A get() 0 4 1
A has() 0 4 1
1
<?php declare(strict_types = 1);
2
3
namespace Venta\Container;
4
5
use Venta\Contracts\Container\Container as ContainerContract;
6
use Venta\Contracts\Container\MutableContainer as MutableContainerContract;
7
8
/**
9
 * Class ContainerProxy
10
 *
11
 * @package Venta\Container
12
 */
13
final class ContainerProxy implements ContainerContract
14
{
15
    /**
16
     * @var MutableContainerContract
17
     */
18
    private $container;
19
20
    /**
21
     * ContainerProxy constructor.
22
     *
23
     * @param MutableContainerContract $container
24
     */
25
    public function __construct(MutableContainerContract $container)
26
    {
27
        $this->container = $container;
28
    }
29
30
    /**
31
     * @inheritDoc
32
     */
33
    public function get($id, array $arguments = [])
34
    {
35
        return $this->container->get($id, $arguments);
36
    }
37
38
    /**
39
     * @inheritDoc
40
     */
41
    public function has($id)
42
    {
43
        return $this->container->has($id);
44
    }
45
46
}