Completed
Pull Request — master (#13)
by Jhao
03:24
created

Tariff   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
eloc 7
c 1
b 0
f 0
dl 0
loc 30
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getVat() 0 3 1
A __construct() 0 4 1
A getCost() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Appwilio\RussianPostSDK\Dispatching\Endpoints\Services\Responses;
6
7
use JMS\Serializer\Annotation AS JMS;
8
9
final class Tariff
10
{
11
    /**
12
     * @JMS\SerializedName("rate")
13
     * @JMS\Type("int")
14
     * @var int
15
     */
16
    private $cost;
17
18
    /**
19
     * @JMS\SerializedName("vat")
20
     * @JMS\Type("int")
21
     * @var int
22
     */
23
    private $vat;
24
25
    public function __construct(int $cost, int $vat)
26
    {
27
        $this->cost = $cost;
28
        $this->vat = $vat;
29
    }
30
31
    public function getCost(): int
32
    {
33
        return $this->cost;
34
    }
35
36
    public function getVat(): int
37
    {
38
        return $this->vat;
39
    }
40
}
41