Object2ArrayContext   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 3
dl 0
loc 30
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getReader() 0 4 1
A setReader() 0 6 1
1
<?php
2
3
/*
4
 * This file is part of the rafrsr/lib-array2object package.
5
 *
6
 * (c) Rafael SR <https://github.com/rafrsr>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
namespace Rafrsr\LibArray2Object;
12
13
use Rafrsr\LibArray2Object\Reader\PropertyReaderInterface;
14
use Rafrsr\LibArray2Object\Traits\IgnoreNullsTrait;
15
use Rafrsr\LibArray2Object\Traits\NamingStrategyAwareTrait;
16
17
class Object2ArrayContext extends AbstractContext
18
{
19
    use NamingStrategyAwareTrait;
20
    use IgnoreNullsTrait;
21
22
    /**
23
     * @var PropertyReaderInterface
24
     */
25
    private $reader;
26
27
    /**
28
     * @return PropertyReaderInterface
29
     */
30
    public function getReader()
31
    {
32
        return $this->reader;
33
    }
34
35
    /**
36
     * @param PropertyReaderInterface $reader
37
     *
38
     * @return $this
39
     */
40
    public function setReader($reader)
41
    {
42
        $this->reader = $reader;
43
44
        return $this;
45
    }
46
}
47