Completed
Pull Request — develop (#9)
by
unknown
03:41
created

SmartIdStatusResult::setSurname()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 4
Ratio 100 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 0
Metric Value
dl 4
loc 4
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
crap 1
1
<?php
2
namespace Isign\Login;
3
4
use Isign\StatusResultInterface;
5
6
/**
7
 * Result object for smart ID login status response.
8
 */
9 View Code Duplication
class SmartIdStatusResult extends AbstractStatusResult
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
10
{
11
    /** @var string user's login certificate */
12
    private $certificate;
13
    
14
    /** @var string personal code */
15
    private $code;
16
    
17
    /** @var string Country code */
18
    private $country;
19
    
20
    /** @var string name */
21
    private $name;
22
    
23
    /** @var string surname */
24
    private $surname;
25
    
26
    /**
27
     * Fields expected in response
28
     * @return array
29
     */
30 12
    public function getFields()
31
    {
32
        return [
33 12
            'status',
34 12
            'certificate',
35 12
            'code',
36 12
            'country',
37 12
            'name',
38 12
            'surname',    
39 12
        ];
40
    }
41
    
42
    /**
43
     * @return string
44
     */
45 2
    public function getStatus()
46
    {
47 2
        return $this->status;
48
    }
49
    
50
    /**
51
     * @return string
52
     */
53 2
    public function getCode()
54
    {
55 2
        return $this->code;
56
    }
57
    
58
    /**
59
     * @return string
60
     */
61 2
    public function getCountry()
62
    {
63 2
        return $this->country;
64
    }
65
    
66
    /**
67
     * @return string
68
     */
69 2
    public function getName()
70
    {
71 2
        return $this->name;
72
    }
73
    
74
    /**
75
     * @return string
76
     */
77 2
    public function getSurname()
78
    {
79 2
        return $this->surname;
80
    }
81
    
82
    /**
83
     * Set status
84
     * @param string $status
85
     * @return void
86
     */
87 2
    public function setStatus($status)
88
    {
89 2
        $this->status = $status;
90 2
    }
91
    
92
    /**
93
     * Set code
94
     * @param string $code
95
     * @return void
96
     */
97 2
    public function setCode($code)
98
    {
99 2
        $this->code = $code;
100 2
    }
101
    
102
    /**
103
     * Set country
104
     * @param string $country
105
     * @return void
106
     */
107 2
    public function setCountry($country)
108
    {
109 2
        $this->country = $country;
110 2
    }
111
    
112
    /**
113
     * Set name
114
     * @param string $name
115
     * @return void
116
     */
117 2
    public function setName($name)
118
    {
119 2
        $this->name = $name;
120 2
    }
121
    
122
    /**
123
     * Set surname
124
     * @param string $surname
125
     * @return void
126
     */
127 2
    public function setSurname($surname)
128
    {
129 2
        $this->surname = $surname;
130 2
    }
131
    
132
    /**
133
     * @return string
134
     */
135 2
    public function getCertificate()
136
    {
137 2
        return $this->certificate;
138
    }
139
140
    /**
141
     * @param string $certificate
142
     */
143 2
    public function setCertificate($certificate)
144
    {
145 2
        $this->certificate = $certificate;
146 2
    }
147
}
148