1
|
|
|
<?php |
2
|
|
|
|
3
|
|
|
namespace MauroMoreno\DataFactory\Entity; |
4
|
|
|
|
5
|
|
|
/** |
6
|
|
|
* Class Incidence |
7
|
|
|
* |
8
|
|
|
* @package MauroMoreno\DataFactory\Entity |
9
|
|
|
*/ |
10
|
|
|
class Incidence |
11
|
|
|
{ |
12
|
|
|
|
13
|
|
|
/** |
14
|
|
|
* @var int |
15
|
|
|
*/ |
16
|
|
|
private $id; |
17
|
|
|
|
18
|
|
|
/** |
19
|
|
|
* @var string |
20
|
|
|
*/ |
21
|
|
|
private $description; |
22
|
|
|
|
23
|
|
|
/** |
24
|
|
|
* @var string |
25
|
|
|
*/ |
26
|
|
|
private $extra_code; |
27
|
|
|
|
28
|
|
|
/** |
29
|
|
|
* @var int |
30
|
|
|
*/ |
31
|
|
|
private $incidence_id; |
32
|
|
|
|
33
|
|
|
/** |
34
|
|
|
* @var IncidenceKey |
35
|
|
|
*/ |
36
|
|
|
private $key; |
37
|
|
|
|
38
|
|
|
/** |
39
|
|
|
* @var int |
40
|
|
|
*/ |
41
|
|
|
private $minute; |
42
|
|
|
|
43
|
|
|
/** |
44
|
|
|
* @var IncidencePlayer |
45
|
|
|
*/ |
46
|
|
|
private $player; |
47
|
|
|
|
48
|
|
|
/** |
49
|
|
|
* @var IncidencePlayer |
50
|
|
|
*/ |
51
|
|
|
private $player_in; |
52
|
|
|
|
53
|
|
|
/** |
54
|
|
|
* @var IncidencePlayer |
55
|
|
|
*/ |
56
|
|
|
private $player_out; |
57
|
|
|
|
58
|
|
|
/** |
59
|
|
|
* @var int |
60
|
|
|
*/ |
61
|
|
|
private $second; |
62
|
|
|
|
63
|
|
|
/** |
64
|
|
|
* @var string |
65
|
|
|
*/ |
66
|
|
|
private $subtype; |
67
|
|
|
|
68
|
|
|
/** |
69
|
|
|
* @var int |
70
|
|
|
*/ |
71
|
|
|
private $order; |
72
|
|
|
|
73
|
|
|
/** |
74
|
|
|
* @var string |
75
|
|
|
*/ |
76
|
|
|
private $team_short_name; |
77
|
|
|
|
78
|
|
|
/** |
79
|
|
|
* @var string |
80
|
|
|
*/ |
81
|
|
|
private $time; |
82
|
|
|
|
83
|
|
|
/** |
84
|
|
|
* @var string |
85
|
|
|
*/ |
86
|
|
|
private $type; |
87
|
|
|
|
88
|
|
|
/** |
89
|
|
|
* @return int |
90
|
|
|
*/ |
91
|
1 |
|
public function getId(): int |
92
|
|
|
{ |
93
|
1 |
|
return $this->id; |
94
|
|
|
} |
95
|
|
|
|
96
|
|
|
/** |
97
|
|
|
* @param int $id |
98
|
|
|
* |
99
|
|
|
* @return Incidence |
100
|
|
|
*/ |
101
|
2 |
|
public function setId(int $id): Incidence |
102
|
|
|
{ |
103
|
2 |
|
$this->id = $id; |
104
|
2 |
|
return $this; |
105
|
|
|
} |
106
|
|
|
|
107
|
|
|
/** |
108
|
|
|
* @return string |
109
|
|
|
*/ |
110
|
|
|
public function getDescription() |
111
|
|
|
{ |
112
|
|
|
return $this->description; |
113
|
|
|
} |
114
|
|
|
|
115
|
|
|
/** |
116
|
|
|
* @param string $description |
117
|
|
|
* |
118
|
|
|
* @return Incidence |
119
|
|
|
*/ |
120
|
1 |
|
public function setDescription($description) |
121
|
|
|
{ |
122
|
1 |
|
$this->description = $description; |
123
|
1 |
|
return $this; |
124
|
|
|
} |
125
|
|
|
|
126
|
|
|
/** |
127
|
|
|
* @return string |
128
|
|
|
*/ |
129
|
1 |
|
public function getExtraCode(): string |
130
|
|
|
{ |
131
|
1 |
|
return $this->extra_code; |
132
|
|
|
} |
133
|
|
|
|
134
|
|
|
/** |
135
|
|
|
* @param string $extra_code |
136
|
|
|
* |
137
|
|
|
* @return Incidence |
138
|
|
|
*/ |
139
|
2 |
|
public function setExtraCode(string $extra_code): Incidence |
140
|
|
|
{ |
141
|
2 |
|
$this->extra_code = $extra_code; |
142
|
2 |
|
return $this; |
143
|
|
|
} |
144
|
|
|
|
145
|
|
|
/** |
146
|
|
|
* @return int |
147
|
|
|
*/ |
148
|
1 |
|
public function getIncidenceId(): int |
149
|
|
|
{ |
150
|
1 |
|
return $this->incidence_id; |
151
|
|
|
} |
152
|
|
|
|
153
|
|
|
/** |
154
|
|
|
* @param int $incidence_id |
155
|
|
|
* |
156
|
|
|
* @return Incidence |
157
|
|
|
*/ |
158
|
2 |
|
public function setIncidenceId(int $incidence_id): Incidence |
159
|
|
|
{ |
160
|
2 |
|
$this->incidence_id = $incidence_id; |
161
|
2 |
|
return $this; |
162
|
|
|
} |
163
|
|
|
|
164
|
|
|
/** |
165
|
|
|
* @return IncidenceKey |
166
|
|
|
*/ |
167
|
1 |
|
public function getKey(): IncidenceKey |
168
|
|
|
{ |
169
|
1 |
|
return $this->key; |
170
|
|
|
} |
171
|
|
|
|
172
|
|
|
/** |
173
|
|
|
* @param IncidenceKey $key |
174
|
|
|
* |
175
|
|
|
* @return Incidence |
176
|
|
|
*/ |
177
|
2 |
|
public function setKey(IncidenceKey $key): Incidence |
178
|
|
|
{ |
179
|
2 |
|
$this->key = $key; |
180
|
2 |
|
return $this; |
181
|
|
|
} |
182
|
|
|
|
183
|
|
|
/** |
184
|
|
|
* @return int |
185
|
|
|
*/ |
186
|
1 |
|
public function getMinute(): int |
187
|
|
|
{ |
188
|
1 |
|
return $this->minute; |
189
|
|
|
} |
190
|
|
|
|
191
|
|
|
/** |
192
|
|
|
* @param int $minute |
193
|
|
|
* |
194
|
|
|
* @return Incidence |
195
|
|
|
*/ |
196
|
2 |
|
public function setMinute(int $minute): Incidence |
197
|
|
|
{ |
198
|
2 |
|
$this->minute = $minute; |
199
|
2 |
|
return $this; |
200
|
|
|
} |
201
|
|
|
|
202
|
|
|
/** |
203
|
|
|
* @return int |
204
|
|
|
*/ |
205
|
1 |
|
public function getOrder(): int |
206
|
|
|
{ |
207
|
1 |
|
return $this->order; |
208
|
|
|
} |
209
|
|
|
|
210
|
|
|
/** |
211
|
|
|
* @param int $order |
212
|
|
|
* |
213
|
|
|
* @return Incidence |
214
|
|
|
*/ |
215
|
2 |
|
public function setOrder(int $order): Incidence |
216
|
|
|
{ |
217
|
2 |
|
$this->order = $order; |
218
|
2 |
|
return $this; |
219
|
|
|
} |
220
|
|
|
|
221
|
|
|
/** |
222
|
|
|
* @return IncidencePlayer |
223
|
|
|
*/ |
224
|
1 |
|
public function getPlayer(): IncidencePlayer |
225
|
|
|
{ |
226
|
1 |
|
return $this->player; |
227
|
|
|
} |
228
|
|
|
|
229
|
|
|
/** |
230
|
|
|
* @param IncidencePlayer $player |
231
|
|
|
* |
232
|
|
|
* @return Incidence |
233
|
|
|
*/ |
234
|
2 |
|
public function setPlayer(IncidencePlayer $player): Incidence |
235
|
|
|
{ |
236
|
2 |
|
$this->player = $player; |
237
|
2 |
|
return $this; |
238
|
|
|
} |
239
|
|
|
|
240
|
|
|
/** |
241
|
|
|
* @return IncidencePlayer |
242
|
|
|
*/ |
243
|
1 |
|
public function getPlayerIn(): IncidencePlayer |
244
|
|
|
{ |
245
|
1 |
|
return $this->player_in; |
246
|
|
|
} |
247
|
|
|
|
248
|
|
|
/** |
249
|
|
|
* @param IncidencePlayer $player |
250
|
|
|
* |
251
|
|
|
* @return Incidence |
252
|
|
|
*/ |
253
|
2 |
|
public function setPlayerIn(IncidencePlayer $player): Incidence |
254
|
|
|
{ |
255
|
2 |
|
$this->player_in = $player; |
256
|
2 |
|
return $this; |
257
|
|
|
} |
258
|
|
|
|
259
|
|
|
/** |
260
|
|
|
* @return IncidencePlayer |
261
|
|
|
*/ |
262
|
1 |
|
public function getPlayerOut(): IncidencePlayer |
263
|
|
|
{ |
264
|
1 |
|
return $this->player_out; |
265
|
|
|
} |
266
|
|
|
|
267
|
|
|
/** |
268
|
|
|
* @param IncidencePlayer $player |
269
|
|
|
* |
270
|
|
|
* @return Incidence |
271
|
|
|
*/ |
272
|
2 |
|
public function setPlayerOut(IncidencePlayer $player): Incidence |
273
|
|
|
{ |
274
|
2 |
|
$this->player_out = $player; |
275
|
2 |
|
return $this; |
276
|
|
|
} |
277
|
|
|
|
278
|
|
|
/** |
279
|
|
|
* @return int |
280
|
|
|
*/ |
281
|
1 |
|
public function getSecond(): int |
282
|
|
|
{ |
283
|
1 |
|
return $this->second; |
284
|
|
|
} |
285
|
|
|
|
286
|
|
|
/** |
287
|
|
|
* @param int $second |
288
|
|
|
* |
289
|
|
|
* @return Incidence |
290
|
|
|
*/ |
291
|
2 |
|
public function setSecond(int $second): Incidence |
292
|
|
|
{ |
293
|
2 |
|
$this->second = $second; |
294
|
2 |
|
return $this; |
295
|
|
|
} |
296
|
|
|
|
297
|
|
|
/** |
298
|
|
|
* @return string |
299
|
|
|
*/ |
300
|
1 |
|
public function getSubtype(): string |
301
|
|
|
{ |
302
|
1 |
|
return $this->subtype; |
303
|
|
|
} |
304
|
|
|
|
305
|
|
|
/** |
306
|
|
|
* @param string $subtype |
307
|
|
|
* |
308
|
|
|
* @return Incidence |
309
|
|
|
*/ |
310
|
2 |
|
public function setSubtype(string $subtype): Incidence |
311
|
|
|
{ |
312
|
2 |
|
$this->subtype = $subtype; |
313
|
2 |
|
return $this; |
314
|
|
|
} |
315
|
|
|
|
316
|
|
|
/** |
317
|
|
|
* @return string |
318
|
|
|
*/ |
319
|
1 |
|
public function getTeamShortName(): string |
320
|
|
|
{ |
321
|
1 |
|
return $this->team_short_name; |
322
|
|
|
} |
323
|
|
|
|
324
|
|
|
/** |
325
|
|
|
* @param string $team_short_name |
326
|
|
|
* |
327
|
|
|
* @return Incidence |
328
|
|
|
*/ |
329
|
2 |
|
public function setTeamShortName(string $team_short_name): Incidence |
330
|
|
|
{ |
331
|
2 |
|
$this->team_short_name = $team_short_name; |
332
|
2 |
|
return $this; |
333
|
|
|
} |
334
|
|
|
|
335
|
|
|
/** |
336
|
|
|
* @return string |
337
|
|
|
*/ |
338
|
1 |
|
public function getTime(): string |
339
|
|
|
{ |
340
|
1 |
|
return $this->time; |
341
|
|
|
} |
342
|
|
|
|
343
|
|
|
/** |
344
|
|
|
* @param string $time |
345
|
|
|
* |
346
|
|
|
* @return Incidence |
347
|
|
|
*/ |
348
|
2 |
|
public function setTime(string $time): Incidence |
349
|
|
|
{ |
350
|
2 |
|
$this->time = $time; |
351
|
2 |
|
return $this; |
352
|
|
|
} |
353
|
|
|
|
354
|
|
|
/** |
355
|
|
|
* @return string |
356
|
|
|
*/ |
357
|
1 |
|
public function getType(): string |
358
|
|
|
{ |
359
|
1 |
|
return $this->type; |
360
|
|
|
} |
361
|
|
|
|
362
|
|
|
/** |
363
|
|
|
* @param string $type |
364
|
|
|
* |
365
|
|
|
* @return Incidence |
366
|
|
|
*/ |
367
|
2 |
|
public function setType(string $type): Incidence |
368
|
|
|
{ |
369
|
2 |
|
$this->type = $type; |
370
|
2 |
|
return $this; |
371
|
|
|
} |
372
|
|
|
|
373
|
|
|
} |
374
|
|
|
|