Completed
Push — Lonja/albertg ( 67863a...bda4e5 )
by Albert
07:39 queued 05:26
created

LoadLine::product()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
3
namespace Kata\Lonja\Domain\Model;
4
5
final class LoadLine
6
{
7
    /** @var Product */
8
    private $product;
9
    private $kilograms;
10
11 1
    public function __construct(Product $a_product, int $a_kilograms)
12
    {
13 1
        $this->product   = $a_product;
14 1
        $this->kilograms = $a_kilograms;
15 1
    }
16
17 4
    public function product(): Product
18
    {
19 4
        return $this->product;
20
    }
21
22 4
    public function kilograms(): int
23
    {
24 4
        return $this->kilograms;
25
    }
26
}