Completed
Push — master ( 44a00f...9727c6 )
by Arne
02:20
created

OperationListItem::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 5
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
1
<?php
2
3
namespace Storeman;
4
5
use Storeman\Index\IndexObject;
6
use Storeman\Operation\OperationInterface;
7
8
class OperationListItem
9
{
10
    /**
11
     * @var OperationInterface
12
     */
13
    protected $operation;
14
15
    /**
16
     * @var IndexObject
17
     */
18
    protected $indexObject;
19
20
    public function __construct(OperationInterface $operation, ?IndexObject $indexObject = null)
21
    {
22
        $this->operation = $operation;
23
        $this->indexObject = $indexObject;
24
    }
25
26
    public function getOperation(): OperationInterface
27
    {
28
        return $this->operation;
29
    }
30
31
    public function getIndexObject(): ?IndexObject
32
    {
33
        return $this->indexObject;
34
    }
35
}
36