RefundContainer::setInvoicing()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
c 1
b 0
f 0
nc 1
nop 1
dl 0
loc 5
rs 10
1
<?php
2
3
/**
4
 * MIT License
5
 * Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file.
6
 */
7
8
namespace SprykerEco\Zed\Payone\Business\Api\Request\Container;
9
10
use SprykerEco\Shared\Payone\PayoneApiConstants;
11
use SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer;
12
use SprykerEco\Zed\Payone\Business\Api\Request\Container\Refund\PaymentMethod\BankAccountContainer;
13
14
class RefundContainer extends AbstractRequestContainer implements RefundContainerInterface
15
{
16
    /**
17
     * @var string
18
     */
19
    protected $request = PayoneApiConstants::REQUEST_TYPE_REFUND;
20
21
    /**
22
     * @var int
23
     */
24
    protected $txid;
25
26
    /**
27
     * @var int
28
     */
29
    protected $sequencenumber;
30
31
    /**
32
     * @var int
33
     */
34
    protected $amount;
35
36
    /**
37
     * @var string
38
     */
39
    protected $currency;
40
41
    /**
42
     * @var string
43
     */
44
    protected $narrative_text;
45
46
    /**
47
     * @var string
48
     */
49
    protected $use_customerdata;
50
51
    /**
52
     * @var \SprykerEco\Zed\Payone\Business\Api\Request\Container\Refund\PaymentMethod\BankAccountContainer
53
     */
54
    protected $paymentMethod;
55
56
    /**
57
     * @var \SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer
58
     */
59
    protected $invoicing;
60
61
    /**
62
     * @var string
63
     */
64
    protected $bankcountry;
65
66
    /**
67
     * @var string
68
     */
69
    protected $bankaccount;
70
71
    /**
72
     * @var string
73
     */
74
    protected $bankcode;
75
76
    /**
77
     * @var string
78
     */
79
    protected $bankbranchcode;
80
81
    /**
82
     * @var string
83
     */
84
    protected $bankcheckdigit;
85
86
    /**
87
     * @var string
88
     */
89
    protected $iban;
90
91
    /**
92
     * @var string
93
     */
94
    protected $bic;
95
96
    /**
97
     * @param int $amount
98
     *   Amount of refund (in smallest currency unit! e.g.
99
     *   cent). The amount must be less than or equal to
100
     *   the amount of the corresponding booking.
101
     *   (Always provide a negative amount)
102
     *
103
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
104
     */
105
    public function setAmount(int $amount): RefundContainerInterface
106
    {
107
        $this->amount = $amount;
108
109
        return $this;
110
    }
111
112
    /**
113
     * @return int
114
     */
115
    public function getAmount(): int
116
    {
117
        return $this->amount;
118
    }
119
120
    /**
121
     * @param string|null $currency
122
     *
123
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
124
     */
125
    public function setCurrency(?string $currency): RefundContainerInterface
126
    {
127
        $this->currency = $currency;
128
129
        return $this;
130
    }
131
132
    /**
133
     * @return string|null
134
     */
135
    public function getCurrency(): ?string
136
    {
137
        return $this->currency;
138
    }
139
140
    /**
141
     * @param string|null $narrative_text
142
     *
143
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
144
     */
145
    public function setNarrativeText(?string $narrative_text): RefundContainerInterface
146
    {
147
        $this->narrative_text = $narrative_text;
148
149
        return $this;
150
    }
151
152
    /**
153
     * @return string|null
154
     */
155
    public function getNarrativeText(): ?string
156
    {
157
        return $this->narrative_text;
158
    }
159
160
    /**
161
     * @param \SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer $invoicing
162
     *
163
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
164
     */
165
    public function setInvoicing(TransactionContainer $invoicing): RefundContainerInterface
166
    {
167
        $this->invoicing = $invoicing;
168
169
        return $this;
170
    }
171
172
    /**
173
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer
174
     */
175
    public function getInvoicing(): TransactionContainer
176
    {
177
        return $this->invoicing;
178
    }
179
180
    /**
181
     * @param \SprykerEco\Zed\Payone\Business\Api\Request\Container\Refund\PaymentMethod\BankAccountContainer $paymentMethod
182
     *
183
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
184
     */
185
    public function setPaymentMethod(BankAccountContainer $paymentMethod): RefundContainerInterface
186
    {
187
        $this->paymentMethod = $paymentMethod;
188
189
        return $this;
190
    }
191
192
    /**
193
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\Refund\PaymentMethod\BankAccountContainer
194
     */
195
    public function getPaymentMethod(): BankAccountContainer
196
    {
197
        return $this->paymentMethod;
198
    }
199
200
    /**
201
     * @param int|null $sequencenumber
202
     *
203
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
204
     */
205
    public function setSequenceNumber(?int $sequencenumber): RefundContainerInterface
206
    {
207
        $this->sequencenumber = $sequencenumber;
208
209
        return $this;
210
    }
211
212
    /**
213
     * @return int|null
214
     */
215
    public function getSequenceNumber(): ?int
216
    {
217
        return $this->sequencenumber;
218
    }
219
220
    /**
221
     * @param int $txid
222
     *
223
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
224
     */
225
    public function setTxid($txid): RefundContainerInterface
226
    {
227
        $this->txid = $txid;
228
229
        return $this;
230
    }
231
232
    /**
233
     * @return int
234
     */
235
    public function getTxid(): int
236
    {
237
        return $this->txid;
238
    }
239
240
    /**
241
     * @param string $use_customerdata
242
     *
243
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
244
     */
245
    public function setUseCustomerData(string $use_customerdata): RefundContainerInterface
246
    {
247
        $this->use_customerdata = $use_customerdata;
248
249
        return $this;
250
    }
251
252
    /**
253
     * @return string
254
     */
255
    public function getUseCustomerData(): string
256
    {
257
        return $this->use_customerdata;
258
    }
259
260
    /**
261
     * @return string
262
     */
263
    public function getBankcountry(): string
264
    {
265
        return $this->bankcountry;
266
    }
267
268
    /**
269
     * @param string|null $bankcountry
270
     *
271
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
272
     */
273
    public function setBankcountry(?string $bankcountry): RefundContainerInterface
274
    {
275
        $this->bankcountry = $bankcountry;
276
277
        return $this;
278
    }
279
280
    /**
281
     * @return string|null
282
     */
283
    public function getBankaccount(): ?string
284
    {
285
        return $this->bankaccount;
286
    }
287
288
    /**
289
     * @param string|null $bankaccount
290
     *
291
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
292
     */
293
    public function setBankaccount(?string $bankaccount): RefundContainerInterface
294
    {
295
        $this->bankaccount = $bankaccount;
296
297
        return $this;
298
    }
299
300
    /**
301
     * @return string|null
302
     */
303
    public function getBankcode(): ?string
304
    {
305
        return $this->bankcode;
306
    }
307
308
    /**
309
     * @param string|null $bankcode
310
     *
311
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
312
     */
313
    public function setBankcode(?string $bankcode): RefundContainerInterface
314
    {
315
        $this->bankcode = $bankcode;
316
317
        return $this;
318
    }
319
320
    /**
321
     * @return string|null
322
     */
323
    public function getBankbranchcode(): ?string
324
    {
325
        return $this->bankbranchcode;
326
    }
327
328
    /**
329
     * @param string|null $bankbranchcode
330
     *
331
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
332
     */
333
    public function setBankbranchcode(?string $bankbranchcode): RefundContainerInterface
334
    {
335
        $this->bankbranchcode = $bankbranchcode;
336
337
        return $this;
338
    }
339
340
    /**
341
     * @return string|null
342
     */
343
    public function getBankcheckdigit(): ?string
344
    {
345
        return $this->bankcheckdigit;
346
    }
347
348
    /**
349
     * @param string|null $bankcheckdigit
350
     *
351
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
352
     */
353
    public function setBankcheckdigit(?string $bankcheckdigit): RefundContainerInterface
354
    {
355
        $this->bankcheckdigit = $bankcheckdigit;
356
357
        return $this;
358
    }
359
360
    /**
361
     * @return string|null
362
     */
363
    public function getIban(): ?string
364
    {
365
        return $this->iban;
366
    }
367
368
    /**
369
     * @param string|null $iban
370
     *
371
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
372
     */
373
    public function setIban(?string $iban): RefundContainerInterface
374
    {
375
        $this->iban = $iban;
376
377
        return $this;
378
    }
379
380
    /**
381
     * @return string|null
382
     */
383
    public function getBic(): ?string
384
    {
385
        return $this->bic;
386
    }
387
388
    /**
389
     * @param string|null $bic
390
     *
391
     * @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\RefundContainerInterface
392
     */
393
    public function setBic(?string $bic): RefundContainerInterface
394
    {
395
        $this->bic = $bic;
396
397
        return $this;
398
    }
399
}
400