Passed
Push — master ( 69b252...c02560 )
by
unknown
56s queued 11s
created

FacadeDocBodyResponse::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 17

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 9
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 17
ccs 9
cts 9
cp 1
rs 9.7
c 0
b 0
f 0
cc 1
nc 1
nop 7
crap 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Lamoda\IsmpClient\V4\Dto;
6
7
use Lamoda\IsmpClient\V4\Dto\FacadeDocBodyResponse\Body;
8
use Symfony\Component\Serializer\Annotation\SerializedName;
9
10
final class FacadeDocBodyResponse
11
{
12
    public const STATUS_IN_PROGRESS = 'IN_PROGRESS';
13
    public const STATUS_CHECKED_NOT_OK = 'CHECKED_NOT_OK';
14
    public const STATUS_PROCESSING_ERROR = 'PROCESSING_ERROR';
15
    public const STATUS_CHECKED_OK = 'CHECKED_OK';
16
    public const STATUS_UNDEFINED = 'UNDEFINED';
17
    public const STATUS_CANCELLED = 'CANCELLED';
18
    public const STATUS_ACCEPTED = 'ACCEPTED';
19
    public const STATUS_WAIT_ACCEPTANCE = 'WAIT_ACCEPTANCE';
20
    public const STATUS_WAIT_PARTICIPANT_REGISTRATION = 'WAIT_PARTICIPANT_REGISTRATION';
21
22
    /**
23
     * @var string
24
     */
25
    private $number;
26
    /**
27
     * @var string
28
     *
29
     * @SerializedName("docDate")
30
     */
31
    private $docDate;
32
    /**
33
     * @var string
34
     */
35
    private $type;
36
    /**
37
     * @var string
38
     */
39
    private $status;
40
    /**
41
     * @var string|null
42
     *
43
     * @SerializedName("senderName")
44
     */
45
    private $senderName;
46
    /**
47
     * @var string|null
48
     */
49
    private $content;
50
    /**
51
     * @var Body|null
52
     */
53
    private $body;
54
    /**
55
     * @var array|null
56
     */
57
    private $errors;
58
    /**
59
     * @var string|null
60
     */
61
    private $receiverName;
62
    /**
63
     * @var string|null
64
     */
65
    private $downloadStatus;
66
    /**
67
     * @var string|null
68
     */
69
    private $downloadDesc;
70
    /**
71
     * @var string|null
72
     */
73
    private $cisTotal;
74
75 6
    public function __construct(
76
        string $number,
77
        string $docDate,
78
        string $type,
79
        string $status,
80
        ?string $senderName = null,
81
        ?string $content = null,
82
        ?Body $body = null
83
    ) {
84 6
        $this->number = $number;
85 6
        $this->docDate = $docDate;
86 6
        $this->type = $type;
87 6
        $this->status = $status;
88 6
        $this->senderName = $senderName;
89 6
        $this->content = $content;
90 6
        $this->body = $body;
91 6
    }
92
93
    public function getNumber(): string
94
    {
95
        return $this->number;
96
    }
97
98
    public function getDocDate(): string
99
    {
100
        return $this->docDate;
101
    }
102
103
    public function getType(): string
104
    {
105
        return $this->type;
106
    }
107
108
    public function getStatus(): string
109
    {
110
        return $this->status;
111
    }
112
113
    public function getSenderName(): ?string
114
    {
115
        return $this->senderName;
116
    }
117
118
    public function getContent(): ?string
119
    {
120
        return $this->content;
121
    }
122
123
    public function getBody(): ?Body
124
    {
125
        return $this->body;
126
    }
127
128
    public function getErrors(): ?array
129
    {
130
        return $this->errors;
131
    }
132
133
    public function setErrors(?array $errors): self
134
    {
135
        $this->errors = $errors;
136
137
        return $this;
138
    }
139
140
    public function getReceiverName(): ?string
141
    {
142
        return $this->receiverName;
143
    }
144
145
    public function setReceiverName(?string $receiverName): self
146
    {
147
        $this->receiverName = $receiverName;
148
149
        return $this;
150
    }
151
152
    public function getDownloadStatus(): ?string
153
    {
154
        return $this->downloadStatus;
155
    }
156
157
    public function setDownloadStatus(?string $downloadStatus): self
158
    {
159
        $this->downloadStatus = $downloadStatus;
160
161
        return $this;
162
    }
163
164
    public function getDownloadDesc(): ?string
165
    {
166
        return $this->downloadDesc;
167
    }
168
169
    public function setDownloadDesc(?string $downloadDesc): self
170
    {
171
        $this->downloadDesc = $downloadDesc;
172
173
        return $this;
174
    }
175
176
    public function getCisTotal(): ?string
177
    {
178
        return $this->cisTotal;
179
    }
180
181 6
    public function setCisTotal(?string $cisTotal): self
182
    {
183 6
        $this->cisTotal = $cisTotal;
184
185 6
        return $this;
186
    }
187
}
188