Passed
Push — main ( 7189b9...23cbe4 )
by Vasil
03:17
created

ShipmentPriceAmount   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 63
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
eloc 10
dl 0
loc 63
ccs 12
cts 12
cp 1
rs 10
c 0
b 0
f 0
wmc 6

6 Methods

Rating   Name   Duplication   Size   Complexity  
A getPercent() 0 3 1
A getAmount() 0 3 1
A setAmount() 0 3 1
A setPercent() 0 3 1
A setVatPercent() 0 3 1
A getVatPercent() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace VasilDakov\Speedy\Service\Shipment;
6
7
/**
8
 * Class ShipmentPriceAmount
9
 *
10
 * @author Vasil Dakov <[email protected]>
11
 * @copyright 2009-2022 Neutrino.bg
12
 * @version 1.0
13
 */
14
class ShipmentPriceAmount
15
{
16
    /**
17
     * @var float
18
     */
19
    private float $amount;
20
21
    /**
22
     * @var float|null
23
     */
24
    private ?float $percent = null;
25
26
    /**
27
     * @var float
28
     */
29
    private float $vatPercent;
30
31
    /**
32
     * @return float
33
     */
34 1
    public function getAmount(): float
35
    {
36 1
        return $this->amount;
37
    }
38
39
    /**
40
     * @param float $amount
41
     */
42 1
    public function setAmount(float $amount): void
43
    {
44 1
        $this->amount = $amount;
45
    }
46
47
    /**
48
     * @return float|null
49
     */
50 1
    public function getPercent(): ?float
51
    {
52 1
        return $this->percent;
53
    }
54
55
    /**
56
     * @param float|null $percent
57
     */
58 1
    public function setPercent(?float $percent): void
59
    {
60 1
        $this->percent = $percent;
61
    }
62
63
    /**
64
     * @return float
65
     */
66 1
    public function getVatPercent(): float
67
    {
68 1
        return $this->vatPercent;
69
    }
70
71
    /**
72
     * @param float $vatPercent
73
     */
74 1
    public function setVatPercent(float $vatPercent): void
75
    {
76 1
        $this->vatPercent = $vatPercent;
77
    }
78
}
79