|
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\Authorization; |
|
9
|
|
|
|
|
10
|
|
|
use SprykerEco\Zed\Payone\Business\Api\Request\Container\AbstractRequestContainer; |
|
11
|
|
|
use SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\PaymentMethod\AbstractPaymentMethodContainer; |
|
12
|
|
|
use SprykerEco\Zed\Payone\Business\Api\Request\Container\AuthorizationContainerInterface; |
|
13
|
|
|
use SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer; |
|
14
|
|
|
|
|
15
|
|
|
abstract class AbstractAuthorizationContainer extends AbstractRequestContainer implements AuthorizationContainerInterface |
|
16
|
|
|
{ |
|
17
|
|
|
/** |
|
18
|
|
|
* Sub account ID |
|
19
|
|
|
* |
|
20
|
|
|
* @var string|null |
|
21
|
|
|
*/ |
|
22
|
|
|
protected $aid; |
|
23
|
|
|
|
|
24
|
|
|
/** |
|
25
|
|
|
* @var string|null |
|
26
|
|
|
*/ |
|
27
|
|
|
protected $clearingtype; |
|
28
|
|
|
|
|
29
|
|
|
/** |
|
30
|
|
|
* @var string |
|
31
|
|
|
*/ |
|
32
|
|
|
protected $clearingSubType; |
|
33
|
|
|
|
|
34
|
|
|
/** |
|
35
|
|
|
* Merchant reference number for the payment process. (Permitted symbols: 0-9, a-z, A-Z, .,-,_,/) |
|
36
|
|
|
* |
|
37
|
|
|
* @var string|null |
|
38
|
|
|
*/ |
|
39
|
|
|
protected $reference; |
|
40
|
|
|
|
|
41
|
|
|
/** |
|
42
|
|
|
* Total amount (in smallest currency unit! e.g. cent) |
|
43
|
|
|
* |
|
44
|
|
|
* @var int|null |
|
45
|
|
|
*/ |
|
46
|
|
|
protected $amount; |
|
47
|
|
|
|
|
48
|
|
|
/** |
|
49
|
|
|
* Currency (ISO-4217) |
|
50
|
|
|
* |
|
51
|
|
|
* @var string|null |
|
52
|
|
|
*/ |
|
53
|
|
|
protected $currency; |
|
54
|
|
|
|
|
55
|
|
|
/** |
|
56
|
|
|
* Individual parameter |
|
57
|
|
|
* |
|
58
|
|
|
* @var string|null |
|
59
|
|
|
*/ |
|
60
|
|
|
protected $param; |
|
61
|
|
|
|
|
62
|
|
|
/** |
|
63
|
|
|
* dynamic text for debit and creditcard payments |
|
64
|
|
|
* |
|
65
|
|
|
* @var string|null |
|
66
|
|
|
*/ |
|
67
|
|
|
protected $narrative_text; |
|
68
|
|
|
|
|
69
|
|
|
/** |
|
70
|
|
|
* @var \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\PersonalContainer |
|
71
|
|
|
*/ |
|
72
|
|
|
protected $personalData; |
|
73
|
|
|
|
|
74
|
|
|
/** |
|
75
|
|
|
* @var \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\ShippingContainer|null |
|
76
|
|
|
*/ |
|
77
|
|
|
protected $shippingData; |
|
78
|
|
|
|
|
79
|
|
|
/** |
|
80
|
|
|
* @var \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\PaymentMethod\AbstractPaymentMethodContainer|null |
|
81
|
|
|
*/ |
|
82
|
|
|
protected $paymentMethod; |
|
83
|
|
|
|
|
84
|
|
|
/** |
|
85
|
|
|
* @var \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\ThreeDSecureContainer|null |
|
86
|
|
|
*/ |
|
87
|
|
|
protected $threeDSecure; |
|
88
|
|
|
|
|
89
|
|
|
/** |
|
90
|
|
|
* @var \SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer|null |
|
91
|
|
|
*/ |
|
92
|
|
|
protected $invoicing; |
|
93
|
|
|
|
|
94
|
|
|
/** |
|
95
|
|
|
* @var string|null |
|
96
|
|
|
*/ |
|
97
|
|
|
protected $onlinebanktransfertype; |
|
98
|
|
|
|
|
99
|
|
|
/** |
|
100
|
|
|
* @var string |
|
101
|
|
|
*/ |
|
102
|
|
|
protected $bankcountry; |
|
103
|
|
|
|
|
104
|
|
|
/** |
|
105
|
|
|
* @var string|null |
|
106
|
|
|
*/ |
|
107
|
|
|
protected $businessRelation; |
|
108
|
|
|
|
|
109
|
|
|
/** |
|
110
|
|
|
* @return string|null |
|
111
|
|
|
*/ |
|
112
|
|
|
public function getBusinessRelation(): ?string |
|
113
|
|
|
{ |
|
114
|
|
|
return $this->businessRelation; |
|
115
|
|
|
} |
|
116
|
|
|
|
|
117
|
|
|
/** |
|
118
|
|
|
* @param string $businessRelation |
|
119
|
|
|
* |
|
120
|
|
|
* @return void |
|
121
|
|
|
*/ |
|
122
|
|
|
public function setBusinessRelation(string $businessRelation): void |
|
123
|
|
|
{ |
|
124
|
|
|
$this->businessRelation = $businessRelation; |
|
125
|
|
|
} |
|
126
|
|
|
|
|
127
|
|
|
/** |
|
128
|
|
|
* @param int|null $amount |
|
129
|
|
|
* |
|
130
|
|
|
* @return void |
|
131
|
|
|
*/ |
|
132
|
|
|
public function setAmount(?int $amount = null): void |
|
133
|
|
|
{ |
|
134
|
|
|
$this->amount = $amount; |
|
135
|
|
|
} |
|
136
|
|
|
|
|
137
|
|
|
/** |
|
138
|
|
|
* @return int|null |
|
139
|
|
|
*/ |
|
140
|
|
|
public function getAmount(): ?int |
|
141
|
|
|
{ |
|
142
|
|
|
return $this->amount; |
|
143
|
|
|
} |
|
144
|
|
|
|
|
145
|
|
|
/** |
|
146
|
|
|
* @param string $clearingType |
|
147
|
|
|
* |
|
148
|
|
|
* @return void |
|
149
|
|
|
*/ |
|
150
|
|
|
public function setClearingType(string $clearingType): void |
|
151
|
|
|
{ |
|
152
|
|
|
$this->clearingtype = $clearingType; |
|
153
|
|
|
} |
|
154
|
|
|
|
|
155
|
|
|
/** |
|
156
|
|
|
* @return string|null |
|
157
|
|
|
*/ |
|
158
|
|
|
public function getClearingType(): ?string |
|
159
|
|
|
{ |
|
160
|
|
|
return $this->clearingtype; |
|
161
|
|
|
} |
|
162
|
|
|
|
|
163
|
|
|
/** |
|
164
|
|
|
* @param string $currency |
|
165
|
|
|
* |
|
166
|
|
|
* @return void |
|
167
|
|
|
*/ |
|
168
|
|
|
public function setCurrency(string $currency): void |
|
169
|
|
|
{ |
|
170
|
|
|
$this->currency = $currency; |
|
171
|
|
|
} |
|
172
|
|
|
|
|
173
|
|
|
/** |
|
174
|
|
|
* @return string|null |
|
175
|
|
|
*/ |
|
176
|
|
|
public function getCurrency(): ?string |
|
177
|
|
|
{ |
|
178
|
|
|
return $this->currency; |
|
179
|
|
|
} |
|
180
|
|
|
|
|
181
|
|
|
/** |
|
182
|
|
|
* @param string $narrativeText |
|
183
|
|
|
* |
|
184
|
|
|
* @return void |
|
185
|
|
|
*/ |
|
186
|
|
|
public function setNarrativeText(string $narrativeText): void |
|
187
|
|
|
{ |
|
188
|
|
|
$this->narrative_text = $narrativeText; |
|
189
|
|
|
} |
|
190
|
|
|
|
|
191
|
|
|
/** |
|
192
|
|
|
* @return string|null |
|
193
|
|
|
*/ |
|
194
|
|
|
public function getNarrativeText(): ?string |
|
195
|
|
|
{ |
|
196
|
|
|
return $this->narrative_text; |
|
197
|
|
|
} |
|
198
|
|
|
|
|
199
|
|
|
/** |
|
200
|
|
|
* @param string $param |
|
201
|
|
|
* |
|
202
|
|
|
* @return void |
|
203
|
|
|
*/ |
|
204
|
|
|
public function setParam(string $param): void |
|
205
|
|
|
{ |
|
206
|
|
|
$this->param = $param; |
|
207
|
|
|
} |
|
208
|
|
|
|
|
209
|
|
|
/** |
|
210
|
|
|
* @return string|null |
|
211
|
|
|
*/ |
|
212
|
|
|
public function getParam(): ?string |
|
213
|
|
|
{ |
|
214
|
|
|
return $this->param; |
|
215
|
|
|
} |
|
216
|
|
|
|
|
217
|
|
|
/** |
|
218
|
|
|
* @param string $reference |
|
219
|
|
|
* |
|
220
|
|
|
* @return void |
|
221
|
|
|
*/ |
|
222
|
|
|
public function setReference(string $reference): void |
|
223
|
|
|
{ |
|
224
|
|
|
$this->reference = $reference; |
|
225
|
|
|
} |
|
226
|
|
|
|
|
227
|
|
|
/** |
|
228
|
|
|
* @return string|null |
|
229
|
|
|
*/ |
|
230
|
|
|
public function getReference(): ?string |
|
231
|
|
|
{ |
|
232
|
|
|
return $this->reference; |
|
233
|
|
|
} |
|
234
|
|
|
|
|
235
|
|
|
/** |
|
236
|
|
|
* @param \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\PersonalContainer $personalData |
|
237
|
|
|
* |
|
238
|
|
|
* @return void |
|
239
|
|
|
*/ |
|
240
|
|
|
public function setPersonalData(PersonalContainer $personalData): void |
|
241
|
|
|
{ |
|
242
|
|
|
$this->personalData = $personalData; |
|
243
|
|
|
} |
|
244
|
|
|
|
|
245
|
|
|
/** |
|
246
|
|
|
* @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\PersonalContainer|null |
|
247
|
|
|
*/ |
|
248
|
|
|
public function getPersonalData(): ?PersonalContainer |
|
249
|
|
|
{ |
|
250
|
|
|
return $this->personalData; |
|
251
|
|
|
} |
|
252
|
|
|
|
|
253
|
|
|
/** |
|
254
|
|
|
* @param \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\ShippingContainer $delivery |
|
255
|
|
|
* |
|
256
|
|
|
* @return void |
|
257
|
|
|
*/ |
|
258
|
|
|
public function setShippingData(ShippingContainer $delivery): void |
|
259
|
|
|
{ |
|
260
|
|
|
$this->shippingData = $delivery; |
|
261
|
|
|
} |
|
262
|
|
|
|
|
263
|
|
|
/** |
|
264
|
|
|
* @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\ShippingContainer|null |
|
265
|
|
|
*/ |
|
266
|
|
|
public function getShippingData(): ?ShippingContainer |
|
267
|
|
|
{ |
|
268
|
|
|
return $this->shippingData; |
|
269
|
|
|
} |
|
270
|
|
|
|
|
271
|
|
|
/** |
|
272
|
|
|
* @param \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\PaymentMethod\AbstractPaymentMethodContainer $paymentMethod |
|
273
|
|
|
* |
|
274
|
|
|
* @return void |
|
275
|
|
|
*/ |
|
276
|
|
|
public function setPaymentMethod(AbstractPaymentMethodContainer $paymentMethod): void |
|
277
|
|
|
{ |
|
278
|
|
|
$this->paymentMethod = $paymentMethod; |
|
279
|
|
|
} |
|
280
|
|
|
|
|
281
|
|
|
/** |
|
282
|
|
|
* @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\PaymentMethod\AbstractPaymentMethodContainer|null |
|
283
|
|
|
*/ |
|
284
|
|
|
public function getPaymentMethod(): ?AbstractPaymentMethodContainer |
|
285
|
|
|
{ |
|
286
|
|
|
return $this->paymentMethod; |
|
287
|
|
|
} |
|
288
|
|
|
|
|
289
|
|
|
/** |
|
290
|
|
|
* @param \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\ThreeDSecureContainer $secure |
|
291
|
|
|
* |
|
292
|
|
|
* @return void |
|
293
|
|
|
*/ |
|
294
|
|
|
public function set3dsecure(ThreeDSecureContainer $secure): void |
|
295
|
|
|
{ |
|
296
|
|
|
$this->threeDSecure = $secure; |
|
297
|
|
|
} |
|
298
|
|
|
|
|
299
|
|
|
/** |
|
300
|
|
|
* @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\Authorization\ThreeDSecureContainer|null |
|
301
|
|
|
*/ |
|
302
|
|
|
public function get3dsecure(): ?ThreeDSecureContainer |
|
303
|
|
|
{ |
|
304
|
|
|
return $this->threeDSecure; |
|
305
|
|
|
} |
|
306
|
|
|
|
|
307
|
|
|
/** |
|
308
|
|
|
* @param \SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer $invoicing |
|
309
|
|
|
* |
|
310
|
|
|
* @return void |
|
311
|
|
|
*/ |
|
312
|
|
|
public function setInvoicing(TransactionContainer $invoicing): void |
|
313
|
|
|
{ |
|
314
|
|
|
$this->invoicing = $invoicing; |
|
315
|
|
|
} |
|
316
|
|
|
|
|
317
|
|
|
/** |
|
318
|
|
|
* @return \SprykerEco\Zed\Payone\Business\Api\Request\Container\Invoicing\TransactionContainer|null |
|
319
|
|
|
*/ |
|
320
|
|
|
public function getInvoicing(): ?TransactionContainer |
|
321
|
|
|
{ |
|
322
|
|
|
return $this->invoicing; |
|
323
|
|
|
} |
|
324
|
|
|
|
|
325
|
|
|
/** |
|
326
|
|
|
* @return string|null |
|
327
|
|
|
*/ |
|
328
|
|
|
public function getOnlinebanktransfertype(): ?string |
|
329
|
|
|
{ |
|
330
|
|
|
return $this->onlinebanktransfertype; |
|
331
|
|
|
} |
|
332
|
|
|
|
|
333
|
|
|
/** |
|
334
|
|
|
* @param string $onlinebanktransfertype |
|
335
|
|
|
* |
|
336
|
|
|
* @return void |
|
337
|
|
|
*/ |
|
338
|
|
|
public function setOnlinebanktransfertype(string $onlinebanktransfertype): void |
|
339
|
|
|
{ |
|
340
|
|
|
$this->onlinebanktransfertype = $onlinebanktransfertype; |
|
341
|
|
|
} |
|
342
|
|
|
|
|
343
|
|
|
/** |
|
344
|
|
|
* @return string |
|
345
|
|
|
*/ |
|
346
|
|
|
public function getClearingSubType(): string |
|
347
|
|
|
{ |
|
348
|
|
|
return $this->clearingSubType; |
|
349
|
|
|
} |
|
350
|
|
|
|
|
351
|
|
|
/** |
|
352
|
|
|
* @param string $clearingSubType |
|
353
|
|
|
* |
|
354
|
|
|
* @return void |
|
355
|
|
|
*/ |
|
356
|
|
|
public function setClearingSubType(string $clearingSubType): void |
|
357
|
|
|
{ |
|
358
|
|
|
$this->clearingSubType = $clearingSubType; |
|
359
|
|
|
} |
|
360
|
|
|
} |
|
361
|
|
|
|