DailyActivityAR::__construct()   B
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 24
Code Lines 22

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 24
ccs 0
cts 24
cp 0
rs 8.9713
c 0
b 0
f 0
cc 1
eloc 22
nc 1
nop 21
crap 2

How to fix   Many Parameters   

Many Parameters

Methods with many parameters are not only hard to understand, but their parameters also often become inconsistent when you need more, or different data.

There are several approaches to avoid long parameter lists:

1
<?php
2
3
namespace Gueststream\PMS\IQWare\API;
4
5
class DailyActivityAR
6
{
7
8
    /**
9
     * @var int $ID_Account
10
     */
11
    protected $ID_Account = null;
12
13
    /**
14
     * @var int $AccountNo
15
     */
16
    protected $AccountNo = null;
17
18
    /**
19
     * @var int $OOE
20
     */
21
    protected $OOE = null;
22
23
    /**
24
     * @var int $OOR
25
     */
26
    protected $OOR = null;
27
28
    /**
29
     * @var int $OOO
30
     */
31
    protected $OOO = null;
32
33
    /**
34
     * @var \DateTime $AccountDate
35
     */
36
    protected $AccountDate = null;
37
38
    /**
39
     * @var float $TotRoomRev
40
     */
41
    protected $TotRoomRev = null;
42
43
    /**
44
     * @var float $TotComm
45
     */
46
    protected $TotComm = null;
47
48
    /**
49
     * @var float $TotTax1
50
     */
51
    protected $TotTax1 = null;
52
53
    /**
54
     * @var float $TotTax2
55
     */
56
    protected $TotTax2 = null;
57
58
    /**
59
     * @var float $TotTax3
60
     */
61
    protected $TotTax3 = null;
62
63
    /**
64
     * @var float $TotOtherCB
65
     */
66
    protected $TotOtherCB = null;
67
68
    /**
69
     * @var float $TotReferal
70
     */
71
    protected $TotReferal = null;
72
73
    /**
74
     * @var float $TotCommCC
75
     */
76
    protected $TotCommCC = null;
77
78
    /**
79
     * @var float $DailyPct
80
     */
81
    protected $DailyPct = null;
82
83
    /**
84
     * @var int $BookingType
85
     */
86
    protected $BookingType = null;
87
88
    /**
89
     * @var int $SeqNo
90
     */
91
    protected $SeqNo = null;
92
93
    /**
94
     * @var \DateTime $ArrivalDate
95
     */
96
    protected $ArrivalDate = null;
97
98
    /**
99
     * @var \DateTime $DepartureDate
100
     */
101
    protected $DepartureDate = null;
102
103
    /**
104
     * @var int $ArStatus
105
     */
106
    protected $ArStatus = null;
107
108
    /**
109
     * @var \DateTime $DateArStatus
110
     */
111
    protected $DateArStatus = null;
112
113
    /**
114
     * @param int $ID_Account
115
     * @param int $AccountNo
116
     * @param int $OOE
117
     * @param int $OOR
118
     * @param int $OOO
119
     * @param \DateTime $AccountDate
120
     * @param float $TotRoomRev
121
     * @param float $TotComm
122
     * @param float $TotTax1
123
     * @param float $TotTax2
124
     * @param float $TotTax3
125
     * @param float $TotOtherCB
126
     * @param float $TotReferal
127
     * @param float $TotCommCC
128
     * @param float $DailyPct
129
     * @param int $BookingType
130
     * @param int $SeqNo
131
     * @param \DateTime $ArrivalDate
132
     * @param \DateTime $DepartureDate
133
     * @param int $ArStatus
134
     * @param \DateTime $DateArStatus
135
     */
136
    public function __construct($ID_Account, $AccountNo, $OOE, $OOR, $OOO, \DateTime $AccountDate, $TotRoomRev, $TotComm, $TotTax1, $TotTax2, $TotTax3, $TotOtherCB, $TotReferal, $TotCommCC, $DailyPct, $BookingType, $SeqNo, \DateTime $ArrivalDate, \DateTime $DepartureDate, $ArStatus, \DateTime $DateArStatus)
137
    {
138
        $this->ID_Account = $ID_Account;
139
        $this->AccountNo = $AccountNo;
140
        $this->OOE = $OOE;
141
        $this->OOR = $OOR;
142
        $this->OOO = $OOO;
143
        $this->AccountDate = $AccountDate->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $AccountDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $AccountDate.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
144
        $this->TotRoomRev = $TotRoomRev;
145
        $this->TotComm = $TotComm;
146
        $this->TotTax1 = $TotTax1;
147
        $this->TotTax2 = $TotTax2;
148
        $this->TotTax3 = $TotTax3;
149
        $this->TotOtherCB = $TotOtherCB;
150
        $this->TotReferal = $TotReferal;
151
        $this->TotCommCC = $TotCommCC;
152
        $this->DailyPct = $DailyPct;
153
        $this->BookingType = $BookingType;
154
        $this->SeqNo = $SeqNo;
155
        $this->ArrivalDate = $ArrivalDate->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $ArrivalDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $ArrivalDate.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
156
        $this->DepartureDate = $DepartureDate->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $DepartureDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $DepartureDate.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
157
        $this->ArStatus = $ArStatus;
158
        $this->DateArStatus = $DateArStatus->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $DateArStatus->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $DateArStatus.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
159
    }
160
161
    /**
162
     * @return int
163
     */
164
    public function getID_Account()
165
    {
166
        return $this->ID_Account;
167
    }
168
169
    /**
170
     * @param int $ID_Account
171
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
172
     */
173
    public function setID_Account($ID_Account)
174
    {
175
        $this->ID_Account = $ID_Account;
176
        return $this;
177
    }
178
179
    /**
180
     * @return int
181
     */
182
    public function getAccountNo()
183
    {
184
        return $this->AccountNo;
185
    }
186
187
    /**
188
     * @param int $AccountNo
189
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
190
     */
191
    public function setAccountNo($AccountNo)
192
    {
193
        $this->AccountNo = $AccountNo;
194
        return $this;
195
    }
196
197
    /**
198
     * @return int
199
     */
200
    public function getOOE()
201
    {
202
        return $this->OOE;
203
    }
204
205
    /**
206
     * @param int $OOE
207
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
208
     */
209
    public function setOOE($OOE)
210
    {
211
        $this->OOE = $OOE;
212
        return $this;
213
    }
214
215
    /**
216
     * @return int
217
     */
218
    public function getOOR()
219
    {
220
        return $this->OOR;
221
    }
222
223
    /**
224
     * @param int $OOR
225
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
226
     */
227
    public function setOOR($OOR)
228
    {
229
        $this->OOR = $OOR;
230
        return $this;
231
    }
232
233
    /**
234
     * @return int
235
     */
236
    public function getOOO()
237
    {
238
        return $this->OOO;
239
    }
240
241
    /**
242
     * @param int $OOO
243
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
244
     */
245
    public function setOOO($OOO)
246
    {
247
        $this->OOO = $OOO;
248
        return $this;
249
    }
250
251
    /**
252
     * @return \DateTime
253
     */
254
    public function getAccountDate()
255
    {
256
        if ($this->AccountDate == null) {
257
            return null;
258
        } else {
259
            try {
260
                return new \DateTime($this->AccountDate);
261
            } catch (\Exception $e) {
262
                return false;
263
            }
264
        }
265
    }
266
267
    /**
268
     * @param \DateTime $AccountDate
269
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
270
     */
271
    public function setAccountDate(\DateTime $AccountDate)
272
    {
273
        $this->AccountDate = $AccountDate->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $AccountDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $AccountDate.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
274
        return $this;
275
    }
276
277
    /**
278
     * @return float
279
     */
280
    public function getTotRoomRev()
281
    {
282
        return $this->TotRoomRev;
283
    }
284
285
    /**
286
     * @param float $TotRoomRev
287
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
288
     */
289
    public function setTotRoomRev($TotRoomRev)
290
    {
291
        $this->TotRoomRev = $TotRoomRev;
292
        return $this;
293
    }
294
295
    /**
296
     * @return float
297
     */
298
    public function getTotComm()
299
    {
300
        return $this->TotComm;
301
    }
302
303
    /**
304
     * @param float $TotComm
305
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
306
     */
307
    public function setTotComm($TotComm)
308
    {
309
        $this->TotComm = $TotComm;
310
        return $this;
311
    }
312
313
    /**
314
     * @return float
315
     */
316
    public function getTotTax1()
317
    {
318
        return $this->TotTax1;
319
    }
320
321
    /**
322
     * @param float $TotTax1
323
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
324
     */
325
    public function setTotTax1($TotTax1)
326
    {
327
        $this->TotTax1 = $TotTax1;
328
        return $this;
329
    }
330
331
    /**
332
     * @return float
333
     */
334
    public function getTotTax2()
335
    {
336
        return $this->TotTax2;
337
    }
338
339
    /**
340
     * @param float $TotTax2
341
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
342
     */
343
    public function setTotTax2($TotTax2)
344
    {
345
        $this->TotTax2 = $TotTax2;
346
        return $this;
347
    }
348
349
    /**
350
     * @return float
351
     */
352
    public function getTotTax3()
353
    {
354
        return $this->TotTax3;
355
    }
356
357
    /**
358
     * @param float $TotTax3
359
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
360
     */
361
    public function setTotTax3($TotTax3)
362
    {
363
        $this->TotTax3 = $TotTax3;
364
        return $this;
365
    }
366
367
    /**
368
     * @return float
369
     */
370
    public function getTotOtherCB()
371
    {
372
        return $this->TotOtherCB;
373
    }
374
375
    /**
376
     * @param float $TotOtherCB
377
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
378
     */
379
    public function setTotOtherCB($TotOtherCB)
380
    {
381
        $this->TotOtherCB = $TotOtherCB;
382
        return $this;
383
    }
384
385
    /**
386
     * @return float
387
     */
388
    public function getTotReferal()
389
    {
390
        return $this->TotReferal;
391
    }
392
393
    /**
394
     * @param float $TotReferal
395
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
396
     */
397
    public function setTotReferal($TotReferal)
398
    {
399
        $this->TotReferal = $TotReferal;
400
        return $this;
401
    }
402
403
    /**
404
     * @return float
405
     */
406
    public function getTotCommCC()
407
    {
408
        return $this->TotCommCC;
409
    }
410
411
    /**
412
     * @param float $TotCommCC
413
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
414
     */
415
    public function setTotCommCC($TotCommCC)
416
    {
417
        $this->TotCommCC = $TotCommCC;
418
        return $this;
419
    }
420
421
    /**
422
     * @return float
423
     */
424
    public function getDailyPct()
425
    {
426
        return $this->DailyPct;
427
    }
428
429
    /**
430
     * @param float $DailyPct
431
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
432
     */
433
    public function setDailyPct($DailyPct)
434
    {
435
        $this->DailyPct = $DailyPct;
436
        return $this;
437
    }
438
439
    /**
440
     * @return int
441
     */
442
    public function getBookingType()
443
    {
444
        return $this->BookingType;
445
    }
446
447
    /**
448
     * @param int $BookingType
449
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
450
     */
451
    public function setBookingType($BookingType)
452
    {
453
        $this->BookingType = $BookingType;
454
        return $this;
455
    }
456
457
    /**
458
     * @return int
459
     */
460
    public function getSeqNo()
461
    {
462
        return $this->SeqNo;
463
    }
464
465
    /**
466
     * @param int $SeqNo
467
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
468
     */
469
    public function setSeqNo($SeqNo)
470
    {
471
        $this->SeqNo = $SeqNo;
472
        return $this;
473
    }
474
475
    /**
476
     * @return \DateTime
477
     */
478
    public function getArrivalDate()
479
    {
480
        if ($this->ArrivalDate == null) {
481
            return null;
482
        } else {
483
            try {
484
                return new \DateTime($this->ArrivalDate);
485
            } catch (\Exception $e) {
486
                return false;
487
            }
488
        }
489
    }
490
491
    /**
492
     * @param \DateTime $ArrivalDate
493
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
494
     */
495
    public function setArrivalDate(\DateTime $ArrivalDate)
496
    {
497
        $this->ArrivalDate = $ArrivalDate->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $ArrivalDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $ArrivalDate.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
498
        return $this;
499
    }
500
501
    /**
502
     * @return \DateTime
503
     */
504
    public function getDepartureDate()
505
    {
506
        if ($this->DepartureDate == null) {
507
            return null;
508
        } else {
509
            try {
510
                return new \DateTime($this->DepartureDate);
511
            } catch (\Exception $e) {
512
                return false;
513
            }
514
        }
515
    }
516
517
    /**
518
     * @param \DateTime $DepartureDate
519
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
520
     */
521
    public function setDepartureDate(\DateTime $DepartureDate)
522
    {
523
        $this->DepartureDate = $DepartureDate->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $DepartureDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $DepartureDate.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
524
        return $this;
525
    }
526
527
    /**
528
     * @return int
529
     */
530
    public function getArStatus()
531
    {
532
        return $this->ArStatus;
533
    }
534
535
    /**
536
     * @param int $ArStatus
537
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
538
     */
539
    public function setArStatus($ArStatus)
540
    {
541
        $this->ArStatus = $ArStatus;
542
        return $this;
543
    }
544
545
    /**
546
     * @return \DateTime
547
     */
548
    public function getDateArStatus()
549
    {
550
        if ($this->DateArStatus == null) {
551
            return null;
552
        } else {
553
            try {
554
                return new \DateTime($this->DateArStatus);
555
            } catch (\Exception $e) {
556
                return false;
557
            }
558
        }
559
    }
560
561
    /**
562
     * @param \DateTime $DateArStatus
563
     * @return \Gueststream\PMS\IQWare\API\DailyActivityAR
564
     */
565
    public function setDateArStatus(\DateTime $DateArStatus)
566
    {
567
        $this->DateArStatus = $DateArStatus->format(\DateTime::ATOM);
0 ignored issues
show
Documentation Bug introduced by
It seems like $DateArStatus->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $DateArStatus.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
568
        return $this;
569
    }
570
}
571