Completed
Push — master ( d0abf8...741647 )
by Michael
10s
created

BasicManager   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 1
c 1
b 0
f 1
lcom 0
cbo 1
dl 0
loc 21
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
1
<?php
2
namespace Michaels\Manager;
3
4
use Interop\Container\ContainerInterface;
5
use Michaels\Manager\Contracts\ManagesItemsInterface;
6
use Michaels\Manager\Traits\ManagesItemsTrait;
7
8
/**
9
 * Manages deeply nested, complex data.
10
 *
11
 * A basic manager class with no pizazz. Simply manages complex data.
12
 * NOTE: this is not arrayable.
13
 *
14
 * @package Michaels\Manager
15
 */
16
class BasicManager implements
17
    ManagesItemsInterface,
18
    ContainerInterface
19
{
20
    use ManagesItemsTrait;
21
22
    /**
23
     * The items stored in the manager
24
     * @var array $items Items governed by manager
25
     */
26
    protected $items;
27
28
    /**
29
     * Build a new manager instance
30
     * @param array $items
31
     */
32
    public function __construct($items = [])
33
    {
34
        $this->initManager($items);
35
    }
36
}
37