Passed
Push — main ( 5b7f1c...98c11d )
by Vasil
03:17
created

FindComplexRequest   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 50
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
eloc 10
dl 0
loc 50
ccs 11
cts 11
cp 1
rs 10
c 0
b 0
f 0
wmc 5

5 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getName() 0 3 1
A setSiteId() 0 3 1
A getSiteId() 0 3 1
A setName() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace VasilDakov\Speedy\Service\Location\Complex;
6
7
use VasilDakov\Speedy\ToArray;
8
9
/**
10
 * Class FindComplexRequest
11
 *
12
 * @author Vasil Dakov <[email protected]>
13
 * @copyright 2009-2022 Neutrino.bg
14
 * @version 1.0
15
 */
16
class FindComplexRequest
17
{
18
    use ToArray;
19
20
    /**
21
     * @var int
22
     */
23
    private int $siteId;
24
25
    /**
26
     * @var string
27
     */
28
    private string $name;
29
30 3
    public function __construct(int $siteId, string $name)
31
    {
32 3
        $this->setSiteId($siteId);
33 3
        $this->setName($name);
34
    }
35
36
    /**
37
     * @param int $siteId
38
     */
39 3
    public function setSiteId(int $siteId): void
40
    {
41 3
        $this->siteId = $siteId;
42
    }
43
44
    /**
45
     * @return int
46
     */
47 1
    public function getSiteId(): int
48
    {
49 1
        return $this->siteId;
50
    }
51
52
    /**
53
     * @param string $name
54
     */
55 3
    public function setName(string $name): void
56
    {
57 3
        $this->name = $name;
58
    }
59
60
    /**
61
     * @return string
62
     */
63 1
    public function getName(): string
64
    {
65 1
        return $this->name;
66
    }
67
}
68