TaxRate   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 35
Duplicated Lines 0 %

Importance

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

4 Methods

Rating   Name   Duplication   Size   Complexity  
A setRate() 0 3 1
A getRate() 0 3 1
A setName() 0 3 1
A getName() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace InvoiceNinjaModule\Model;
6
7
use InvoiceNinjaModule\Model\Interfaces\TaxRateInterface;
8
9
/**
10
 * Class TaxRate
11
 * @codeCoverageIgnore
12
 */
13
final class TaxRate extends Base implements TaxRateInterface
14
{
15
    private string $name = '';
16
    private float $rate = 0;
17
18
    /**
19
     * @return string
20
     */
21
    public function getName(): string
22
    {
23
        return $this->name;
24
    }
25
26
    /**
27
     * @param string $name
28
     */
29
    public function setName(string $name): void
30
    {
31
        $this->name = $name;
32
    }
33
34
    /**
35
     * @return float|int
36
     */
37
    public function getRate(): float|int
38
    {
39
        return $this->rate;
40
    }
41
42
    /**
43
     * @param float|int $rate
44
     */
45
    public function setRate(float|int $rate): void
46
    {
47
        $this->rate = $rate;
48
    }
49
}
50