Payment::getToken()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace CultureKings\Afterpay\Model\Merchant;
4
5
use CultureKings\Afterpay\Model\Money;
6
7
/**
8
 * Class Payment
9
 * @package CultureKings\Afterpay\Model\Merchant
10
 */
11
class Payment
12
{
13
    /**
14
     * @var string
15
     */
16
    protected $id;
17
    /**
18
     * @var string
19
     */
20
    protected $token;
21
    /**
22
     * @var string
23
     */
24
    protected $status;
25
    /**
26
     * @var \DateTime
27
     */
28
    protected $created;
29
    /**
30
     * @var Money
31
     */
32
    protected $totalAmount;
33
    /**
34
     * @var string
35
     */
36
    protected $merchantReference;
37
    /**
38
     * @var PaymentEvent[]
39
     */
40
    protected $events = [ ];
41
    /**
42
     * @var Refund[]
43
     */
44
    protected $refunds = [ ];
45
    /**
46
     * @var OrderDetails
47
     */
48
    protected $orderDetails;
49
50
    /**
51
     * @return int
52
     */
53
    public function getId()
54
    {
55
        return $this->id;
56
    }
57
58
    /**
59
     * @param string $id
60
     * @return $this
61
     */
62
    public function setId($id)
63
    {
64
        $this->id = $id;
65
66
        return $this;
67
    }
68
69
    /**
70
     * @return string
71
     */
72
    public function getToken()
73
    {
74
        return $this->token;
75
    }
76
77
    /**
78
     * @param string $token
79
     * @return $this
80
     */
81
    public function setToken($token)
82
    {
83
        $this->token = $token;
84
85
        return $this;
86
    }
87
88
    /**
89
     * @return string
90
     */
91
    public function getStatus()
92
    {
93
        return $this->status;
94
    }
95
96
    /**
97
     * @param string $status
98
     * @return $this
99
     */
100
    public function setStatus($status)
101
    {
102
        $this->status = $status;
103
104
        return $this;
105
    }
106
107
    /**
108
     * @return \DateTime
109
     */
110
    public function getCreated()
111
    {
112
        return $this->created;
113
    }
114
115
    /**
116
     * @param \DateTime $created
117
     * @return $this
118
     */
119
    public function setCreated(\DateTime $created)
120
    {
121
        $this->created = $created;
122
123
        return $this;
124
    }
125
126
    /**
127
     * @return Money
128
     */
129
    public function getTotalAmount()
130
    {
131
        return $this->totalAmount;
132
    }
133
134
    /**
135
     * @param Money $totalAmount
136
     * @return $this
137
     */
138
    public function setTotalAmount(Money $totalAmount)
139
    {
140
        $this->totalAmount = $totalAmount;
141
142
        return $this;
143
    }
144
145
    /**
146
     * @return string
147
     */
148
    public function getMerchantReference()
149
    {
150
        return $this->merchantReference;
151
    }
152
153
    /**
154
     * @param string $merchantReference
155
     * @return $this
156
     */
157
    public function setMerchantReference($merchantReference)
158
    {
159
        $this->merchantReference = $merchantReference;
160
161
        return $this;
162
    }
163
164
    /**
165
     * @return PaymentEvent[]
166
     */
167
    public function getEvents()
168
    {
169
        return $this->events;
170
    }
171
172
    /**
173
     * @param PaymentEvent[] $events
174
     * @return $this
175
     */
176
    public function setEvents(array $events)
177
    {
178
        $this->events = $events;
179
180
        return $this;
181
    }
182
183
    /**
184
     * @return Refund[]
185
     */
186
    public function getRefunds()
187
    {
188
        return $this->refunds;
189
    }
190
191
    /**
192
     * @param Refund[] $refunds
193
     * @return $this
194
     */
195
    public function setRefunds(array $refunds)
196
    {
197
        $this->refunds = $refunds;
198
199
        return $this;
200
    }
201
202
    /**
203
     * @return OrderDetails
204
     */
205
    public function getOrderDetails()
206
    {
207
        return $this->orderDetails;
208
    }
209
210
    /**
211
     * @param OrderDetails $orderDetails
212
     * @return $this
213
     */
214
    public function setOrderDetails(OrderDetails $orderDetails)
215
    {
216
        $this->orderDetails = $orderDetails;
217
218
        return $this;
219
    }
220
}
221