Completed
Pull Request — master (#29)
by
unknown
06:43
created

Item   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Test Coverage

Coverage 60%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 3
dl 0
loc 16
ccs 3
cts 5
cp 0.6
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A __get() 0 4 1
1
<?php
2
3
namespace Softonic\GraphQL\Query;
4
5
use Softonic\GraphQL\Traits\GqlIterator;
6
use Softonic\GraphQL\Traits\JsonPathAccessor;
7
use Softonic\GraphQL\Traits\JsonSerializer;
8
9
class Item implements ReadObject, \JsonSerializable, \Iterator
10
{
11
    use GqlIterator, JsonPathAccessor, JsonSerializer;
12
13
    private $arguments;
14
15 58
    public function __construct(array $arguments = [])
16
    {
17 58
        $this->arguments = $arguments;
18 58
    }
19
20
    public function __get($key)
21
    {
22
        return $this->arguments[$key];
23
    }
24
}
25