1: | <?php |
2: | |
3: | |
4: | |
5: | namespace Worldline\Acquiring\Sdk\V1\Domain; |
6: | |
7: | use UnexpectedValueException; |
8: | use Worldline\Acquiring\Sdk\Domain\DataObject; |
9: | |
10: | |
11: | |
12: | |
13: | class ThreeDSecure extends DataObject |
14: | { |
15: | |
16: | |
17: | |
18: | public $authenticationValue = null; |
19: | |
20: | |
21: | |
22: | |
23: | public $directoryServerTransactionId = null; |
24: | |
25: | |
26: | |
27: | |
28: | public $eci = null; |
29: | |
30: | |
31: | |
32: | |
33: | public $threeDSecureType = null; |
34: | |
35: | |
36: | |
37: | |
38: | public $version = null; |
39: | |
40: | |
41: | |
42: | |
43: | public function toObject() |
44: | { |
45: | $object = parent::toObject(); |
46: | if (!is_null($this->authenticationValue)) { |
47: | $object->authenticationValue = $this->authenticationValue; |
48: | } |
49: | if (!is_null($this->directoryServerTransactionId)) { |
50: | $object->directoryServerTransactionId = $this->directoryServerTransactionId; |
51: | } |
52: | if (!is_null($this->eci)) { |
53: | $object->eci = $this->eci; |
54: | } |
55: | if (!is_null($this->threeDSecureType)) { |
56: | $object->threeDSecureType = $this->threeDSecureType; |
57: | } |
58: | if (!is_null($this->version)) { |
59: | $object->version = $this->version; |
60: | } |
61: | return $object; |
62: | } |
63: | |
64: | |
65: | |
66: | |
67: | |
68: | |
69: | public function fromObject($object) |
70: | { |
71: | parent::fromObject($object); |
72: | if (property_exists($object, 'authenticationValue')) { |
73: | $this->authenticationValue = $object->authenticationValue; |
74: | } |
75: | if (property_exists($object, 'directoryServerTransactionId')) { |
76: | $this->directoryServerTransactionId = $object->directoryServerTransactionId; |
77: | } |
78: | if (property_exists($object, 'eci')) { |
79: | $this->eci = $object->eci; |
80: | } |
81: | if (property_exists($object, 'threeDSecureType')) { |
82: | $this->threeDSecureType = $object->threeDSecureType; |
83: | } |
84: | if (property_exists($object, 'version')) { |
85: | $this->version = $object->version; |
86: | } |
87: | return $this; |
88: | } |
89: | } |
90: | |