Passed
Pull Request — master (#14)
by Carlos C
02:00
created

Impuesto::traslado()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 3
ccs 2
cts 2
cp 1
crap 1
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
namespace PhpCfdi\SatCatalogos\CFDI40;
6
7
use PhpCfdi\SatCatalogos\Common\AbstractEntryIdentifiable;
8
9
class Impuesto extends AbstractEntryIdentifiable
10
{
11
    /** @var bool */
12
    private $retencion;
13
14
    /** @var bool */
15
    private $traslado;
16
17
    /** @var string */
18
    private $ambito;
19
20 6
    public function __construct(
21
        string $id,
22
        string $texto,
23
        bool $retencion,
24
        bool $traslado,
25
        string $ambito,
26
        int $vigenteDesde,
27
        int $vigenteHasta
28
    ) {
29 6
        parent::__construct($id, $texto, $vigenteDesde, $vigenteHasta);
30 6
        $this->retencion = $retencion;
31 6
        $this->traslado = $traslado;
32 6
        $this->ambito = $ambito;
33
    }
34
35 3
    public function retencion(): bool
36
    {
37 3
        return $this->retencion;
38
    }
39
40 3
    public function traslado(): bool
41
    {
42 3
        return $this->traslado;
43
    }
44
45 1
    public function ambito(): string
46
    {
47 1
        return $this->ambito;
48
    }
49
}
50