SendSmsResponse::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 29

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 29
rs 9.456
c 0
b 0
f 0
cc 1
nc 1
nop 26

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
4
namespace Epmnzava\Telerivet\Models;
5
6
7
class SendSmsResponse
8
{
9
10
    public $id;
11
    public $phone_id;
12
    public $contact_id;
13
    public $direction;
14
    public $status;
15
    public $message_type;
16
    public $source;
17
    public $time_created;
18
    public $time_sent;
19
    public $time_updated;
20
    public $from_number;
21
    public $to_number;
22
    public $content;
23
    public $starred;
24
    public $simulated;
25
    public $track_clicks;
26
    public $vars;
27
    public $external_id;
28
    public $label_ids;
29
    public $route_id;
30
    public $scheduled_id;
31
    public $broadcast_id;
32
    public $service_id;
33
    public $user_id;
34
    public $project_id;
35
    public $priority;
36
37
38
39
40
    /**
41
     * SendSmsResponse constructor.
42
     * @param $id
43
     * @param $phone_id
44
     * @param $contact_id
45
     * @param $direction
46
     * @param $status
47
     * @param $message_type
48
     * @param $source
49
     * @param $time_created
50
     * @param $time_sent
51
     * @param $time_updated
52
     * @param $from_number
53
     * @param $to_number
54
     * @param $content
55
     * @param $starred
56
     * @param $simulated
57
     * @param $track_clicks
58
     * @param $vars
59
     * @param $external_id
60
     * @param $label_ids
61
     * @param $route_id
62
     * @param $scheduled_id
63
     * @param $broadcast_id
64
     * @param $service_id
65
     * @param $user_id
66
     * @param $project_id
67
     * @param $priority
68
     */
69
    public function __construct($id, $phone_id, $contact_id, $direction, $status, $message_type, $source, $time_created, $time_sent, $time_updated, $from_number, $to_number, $content, $starred, $simulated, $track_clicks, $vars, $external_id, $label_ids, $route_id, $scheduled_id, $broadcast_id, $service_id, $user_id, $project_id, $priority)
70
    {
71
        $this->id = $id;
72
        $this->phone_id = $phone_id;
73
        $this->contact_id = $contact_id;
74
        $this->direction = $direction;
75
        $this->status = $status;
76
        $this->message_type = $message_type;
77
        $this->source = $source;
78
        $this->time_created = $time_created;
79
        $this->time_sent = $time_sent;
80
        $this->time_updated = $time_updated;
81
        $this->from_number = $from_number;
82
        $this->to_number = $to_number;
83
        $this->content = $content;
84
        $this->starred = $starred;
85
        $this->simulated = $simulated;
86
        $this->track_clicks = $track_clicks;
87
        $this->vars = $vars;
88
        $this->external_id = $external_id;
89
        $this->label_ids = $label_ids;
90
        $this->route_id = $route_id;
91
        $this->scheduled_id = $scheduled_id;
92
        $this->broadcast_id = $broadcast_id;
93
        $this->service_id = $service_id;
94
        $this->user_id = $user_id;
95
        $this->project_id = $project_id;
96
        $this->priority = $priority;
97
    }
98
99
    /**
100
     * @return mixed
101
     */
102
    public function getId()
103
    {
104
        return $this->id;
105
    }
106
107
    /**
108
     * @param mixed $id
109
     */
110
    public function setId($id): void
111
    {
112
        $this->id = $id;
113
    }
114
115
    /**
116
     * @return mixed
117
     */
118
    public function getPhoneId()
119
    {
120
        return $this->phone_id;
121
    }
122
123
    /**
124
     * @param mixed $phone_id
125
     */
126
    public function setPhoneId($phone_id): void
127
    {
128
        $this->phone_id = $phone_id;
129
    }
130
131
    /**
132
     * @return mixed
133
     */
134
    public function getContactId()
135
    {
136
        return $this->contact_id;
137
    }
138
139
    /**
140
     * @param mixed $contact_id
141
     */
142
    public function setContactId($contact_id): void
143
    {
144
        $this->contact_id = $contact_id;
145
    }
146
147
    /**
148
     * @return mixed
149
     */
150
    public function getDirection()
151
    {
152
        return $this->direction;
153
    }
154
155
    /**
156
     * @param mixed $direction
157
     */
158
    public function setDirection($direction): void
159
    {
160
        $this->direction = $direction;
161
    }
162
163
    /**
164
     * @return mixed
165
     */
166
    public function getStatus()
167
    {
168
        return $this->status;
169
    }
170
171
    /**
172
     * @param mixed $status
173
     */
174
    public function setStatus($status): void
175
    {
176
        $this->status = $status;
177
    }
178
179
    /**
180
     * @return mixed
181
     */
182
    public function getMessageType()
183
    {
184
        return $this->message_type;
185
    }
186
187
    /**
188
     * @param mixed $message_type
189
     */
190
    public function setMessageType($message_type): void
191
    {
192
        $this->message_type = $message_type;
193
    }
194
195
    /**
196
     * @return mixed
197
     */
198
    public function getSource()
199
    {
200
        return $this->source;
201
    }
202
203
    /**
204
     * @param mixed $source
205
     */
206
    public function setSource($source): void
207
    {
208
        $this->source = $source;
209
    }
210
211
    /**
212
     * @return mixed
213
     */
214
    public function getTimeCreated()
215
    {
216
        return $this->time_created;
217
    }
218
219
    /**
220
     * @param mixed $time_created
221
     */
222
    public function setTimeCreated($time_created): void
223
    {
224
        $this->time_created = $time_created;
225
    }
226
227
    /**
228
     * @return mixed
229
     */
230
    public function getTimeSent()
231
    {
232
        return $this->time_sent;
233
    }
234
235
    /**
236
     * @param mixed $time_sent
237
     */
238
    public function setTimeSent($time_sent): void
239
    {
240
        $this->time_sent = $time_sent;
241
    }
242
243
    /**
244
     * @return mixed
245
     */
246
    public function getTimeUpdated()
247
    {
248
        return $this->time_updated;
249
    }
250
251
    /**
252
     * @param mixed $time_updated
253
     */
254
    public function setTimeUpdated($time_updated): void
255
    {
256
        $this->time_updated = $time_updated;
257
    }
258
259
    /**
260
     * @return mixed
261
     */
262
    public function getFromNumber()
263
    {
264
        return $this->from_number;
265
    }
266
267
    /**
268
     * @param mixed $from_number
269
     */
270
    public function setFromNumber($from_number): void
271
    {
272
        $this->from_number = $from_number;
273
    }
274
275
    /**
276
     * @return mixed
277
     */
278
    public function getToNumber()
279
    {
280
        return $this->to_number;
281
    }
282
283
    /**
284
     * @param mixed $to_number
285
     */
286
    public function setToNumber($to_number): void
287
    {
288
        $this->to_number = $to_number;
289
    }
290
291
    /**
292
     * @return mixed
293
     */
294
    public function getContent()
295
    {
296
        return $this->content;
297
    }
298
299
    /**
300
     * @param mixed $content
301
     */
302
    public function setContent($content): void
303
    {
304
        $this->content = $content;
305
    }
306
307
    /**
308
     * @return mixed
309
     */
310
    public function getStarred()
311
    {
312
        return $this->starred;
313
    }
314
315
    /**
316
     * @param mixed $starred
317
     */
318
    public function setStarred($starred): void
319
    {
320
        $this->starred = $starred;
321
    }
322
323
    /**
324
     * @return mixed
325
     */
326
    public function getSimulated()
327
    {
328
        return $this->simulated;
329
    }
330
331
    /**
332
     * @param mixed $simulated
333
     */
334
    public function setSimulated($simulated): void
335
    {
336
        $this->simulated = $simulated;
337
    }
338
339
    /**
340
     * @return mixed
341
     */
342
    public function getTrackClicks()
343
    {
344
        return $this->track_clicks;
345
    }
346
347
    /**
348
     * @param mixed $track_clicks
349
     */
350
    public function setTrackClicks($track_clicks): void
351
    {
352
        $this->track_clicks = $track_clicks;
353
    }
354
355
    /**
356
     * @return mixed
357
     */
358
    public function getVars()
359
    {
360
        return $this->vars;
361
    }
362
363
    /**
364
     * @param mixed $vars
365
     */
366
    public function setVars($vars): void
367
    {
368
        $this->vars = $vars;
369
    }
370
371
    /**
372
     * @return mixed
373
     */
374
    public function getExternalId()
375
    {
376
        return $this->external_id;
377
    }
378
379
    /**
380
     * @param mixed $external_id
381
     */
382
    public function setExternalId($external_id): void
383
    {
384
        $this->external_id = $external_id;
385
    }
386
387
    /**
388
     * @return mixed
389
     */
390
    public function getLabelIds()
391
    {
392
        return $this->label_ids;
393
    }
394
395
    /**
396
     * @param mixed $label_ids
397
     */
398
    public function setLabelIds($label_ids): void
399
    {
400
        $this->label_ids = $label_ids;
401
    }
402
403
    /**
404
     * @return mixed
405
     */
406
    public function getRouteId()
407
    {
408
        return $this->route_id;
409
    }
410
411
    /**
412
     * @param mixed $route_id
413
     */
414
    public function setRouteId($route_id): void
415
    {
416
        $this->route_id = $route_id;
417
    }
418
419
    /**
420
     * @return mixed
421
     */
422
    public function getScheduledId()
423
    {
424
        return $this->scheduled_id;
425
    }
426
427
    /**
428
     * @param mixed $scheduled_id
429
     */
430
    public function setScheduledId($scheduled_id): void
431
    {
432
        $this->scheduled_id = $scheduled_id;
433
    }
434
435
    /**
436
     * @return mixed
437
     */
438
    public function getBroadcastId()
439
    {
440
        return $this->broadcast_id;
441
    }
442
443
    /**
444
     * @param mixed $broadcast_id
445
     */
446
    public function setBroadcastId($broadcast_id): void
447
    {
448
        $this->broadcast_id = $broadcast_id;
449
    }
450
451
    /**
452
     * @return mixed
453
     */
454
    public function getServiceId()
455
    {
456
        return $this->service_id;
457
    }
458
459
    /**
460
     * @param mixed $service_id
461
     */
462
    public function setServiceId($service_id): void
463
    {
464
        $this->service_id = $service_id;
465
    }
466
467
    /**
468
     * @return mixed
469
     */
470
    public function getUserId()
471
    {
472
        return $this->user_id;
473
    }
474
475
    /**
476
     * @param mixed $user_id
477
     */
478
    public function setUserId($user_id): void
479
    {
480
        $this->user_id = $user_id;
481
    }
482
483
    /**
484
     * @return mixed
485
     */
486
    public function getProjectId()
487
    {
488
        return $this->project_id;
489
    }
490
491
    /**
492
     * @param mixed $project_id
493
     */
494
    public function setProjectId($project_id): void
495
    {
496
        $this->project_id = $project_id;
497
    }
498
499
    /**
500
     * @return mixed
501
     */
502
    public function getPriority()
503
    {
504
        return $this->priority;
505
    }
506
507
    /**
508
     * @param mixed $priority
509
     */
510
    public function setPriority($priority): void
511
    {
512
        $this->priority = $priority;
513
    }
514
515
516
517
}
518