Row::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
c 1
b 0
f 0
nc 1
nop 1
dl 0
loc 3
rs 10
1
<?php
2
3
namespace kalanis\kw_connect\eloquent;
4
5
6
use ArrayIterator;
7
use kalanis\kw_connect\core\Interfaces\IRow;
8
9
10
/**
11
 * Class Row
12
 * @package kalanis\kw_connect\eloquent
13
 */
14
class Row implements IRow
15
{
16
    protected ArrayIterator $row;
17
18
    public function __construct(ArrayIterator $row)
19
    {
20
        $this->row = $row;
21
    }
22
23
    public function getValue($property)
24
    {
25
        return $this->row->offsetGet($property);
26
    }
27
28
    public function __isset($name)
29
    {
30
        return $this->row->offsetExists($name);
31
    }
32
}
33