Test Failed
Pull Request — master (#250)
by
unknown
02:21
created

Message::getDocument()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php
2
namespace TelegramBot\Api\Types;
3
4
use TelegramBot\Api\BaseType;
5
use TelegramBot\Api\InvalidArgumentException;
6
use TelegramBot\Api\TypeInterface;
7
use TelegramBot\Api\Types\Inline\InlineKeyboardMarkup;
8
use TelegramBot\Api\Types\Payments\Invoice;
9
use TelegramBot\Api\Types\Payments\SuccessfulPayment;
10
11
class Message extends BaseType implements TypeInterface
12
{
13
    /**
14
     * {@inheritdoc}
15
     *
16
     * @var array
17
     */
18
    static protected $requiredParams = ['message_id', 'date', 'chat'];
19
20
    /**
21
     * {@inheritdoc}
22
     *
23
     * @var array
24
     */
25
    static protected $map = [
26
        'message_id' => true,
27
        'from' => User::class,
28
        'date' => true,
29
        'chat' => Chat::class,
30
        'forward_from' => User::class,
31
        'forward_from_chat' => Chat::class,
32
        'forward_from_message_id' => true,
33
        'forward_date' => true,
34
        'forward_signature' => true,
35
        'forward_sender_name' => true,
36
        'reply_to_message' => Message::class,
37
        'edit_date' => true,
38
        'media_group_id' => true,
39
        'author_signature' => true,
40
        'text' => true,
41
        'entities' => ArrayOfMessageEntity::class,
42
        'caption_entities' => ArrayOfMessageEntity::class,
43
        'audio' => Audio::class,
44
        'document' => Document::class,
45
        'animation' => Animation::class,
46
        'photo' => ArrayOfPhotoSize::class,
47
        'sticker' => Sticker::class,
48
        'video' => Video::class,
49
        'voice' => Voice::class,
50
        'caption' => true,
51
        'contact' => Contact::class,
52
        'location' => Location::class,
53
        'venue' => Venue::class,
54
        'poll' => Poll::class,
55
        'dice' => Dice::class,
56
        'new_chat_members' => ArrayOfUser::class,
57
        'left_chat_member' => User::class,
58
        'new_chat_title' => true,
59
        'new_chat_photo' => ArrayOfPhotoSize::class,
60
        'delete_chat_photo' => true,
61
        'group_chat_created' => true,
62
        'supergroup_chat_created' => true,
63
        'channel_chat_created' => true,
64
        'migrate_to_chat_id' => true,
65
        'migrate_from_chat_id' => true,
66
        'pinned_message' => Message::class,
67
        'invoice' => Invoice::class,
68
        'successful_payment' => SuccessfulPayment::class,
69
        'connected_website' => true,
70
        'reply_markup' => InlineKeyboardMarkup::class,
71
    ];
72
73
    /**
74
     * Unique message identifier
75
     *
76
     * @var int
77
     */
78
    protected $messageId;
79
80
    /**
81
     * Optional. Sender name. Can be empty for messages sent to channels
82
     *
83
     * @var \TelegramBot\Api\Types\User
84
     */
85
    protected $from;
86
87
    /**
88
     * Date the message was sent in Unix time
89
     *
90
     * @var int
91
     */
92
    protected $date;
93
94
    /**
95
     * Conversation the message belongs to — user in case of a private message, GroupChat in case of a group
96
     *
97
     * @var \TelegramBot\Api\Types\Chat
98
     */
99
    protected $chat;
100
101
    /**
102
     * Optional. For forwarded messages, sender of the original message
103
     *
104
     * @var \TelegramBot\Api\Types\User
105
     */
106
    protected $forwardFrom;
107
108
    /**
109
     * Optional. For messages forwarded from channels, information about
110
     * the original channel
111
     *
112
     * @var \TelegramBot\Api\Types\Chat
113
     */
114
    protected $forwardFromChat;
115
116
    /**
117
     * Optional. For messages forwarded from channels, identifier of
118
     * the original message in the channel
119
     *
120
     * @var int
121
     */
122
    protected $forwardFromMessageId;
123
124
    /**
125
     * Optional. For messages forwarded from channels, signature of the post author if present
126
     *
127
     * @var string
128
     */
129
    protected $forwardSignature;
130
131
    /**
132
     * Optional. Sender's name for messages forwarded from users who disallow adding a link to their account
133
     * in forwarded messages
134
     *
135
     * @var string
136
     */
137
    protected $forwardSenderName;
138
139
    /**
140
     * Optional. For forwarded messages, date the original message was sent in Unix time
141
     *
142
     * @var int
143
     */
144
    protected $forwardDate;
145
146
    /**
147
     * Optional. For replies, the original message. Note that the Message object in this field will not contain further
148
     * reply_to_message fields even if it itself is a reply.
149
     *
150
     * @var \TelegramBot\Api\Types\Message
151
     */
152
    protected $replyToMessage;
153
154
    /**
155
     * Optional. Date the message was last edited in Unix time
156
     *
157
     * @var int
158
     */
159
    protected $editDate;
160
161
    /**
162
     * Optional. The unique identifier of a media message group
163
     * this message belongs to
164
     *
165
     * @var int
166
     */
167
    protected $mediaGroupId;
168
169
    /**
170
     * Optional. Signature of the post author for messages in channels
171
     *
172
     * @var string
173
     */
174
    protected $authorSignature;
175
176
    /**
177
     * Optional. For text messages, the actual UTF-8 text of the message
178
     *
179
     * @var string
180
     */
181
    protected $text;
182
183
    /**
184
     * Optional. For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text.
185
     * array of \TelegramBot\Api\Types\MessageEntity
186
     *
187
     * @var array
188
     */
189
    protected $entities;
190
191
    /**
192
     * Optional. For messages with a caption, special entities like usernames,
193
     * URLs, bot commands, etc. that appear in the caption
194
     *
195
     * @var ArrayOfMessageEntity
196
     */
197
    protected $captionEntities;
198
199
    /**
200
     * Optional. Message is an audio file, information about the file
201
     *
202
     * @var \TelegramBot\Api\Types\Audio
203
     */
204
    protected $audio;
205
206
    /**
207
     * Optional. Message is a general file, information about the file
208
     *
209
     * @var \TelegramBot\Api\Types\Document
210
     */
211
    protected $document;
212
213
    /**
214
     * Optional. Message is a animation, information about the animation
215
     *
216
     * @var \TelegramBot\Api\Types\Animation
217
     */
218
    protected $animation;
219
220
    /**
221
     * Optional. Message is a photo, available sizes of the photo
222
     * array of \TelegramBot\Api\Types\Photo
223
     *
224
     * @var array
225
     */
226
    protected $photo;
227
228
    /**
229
     * Optional. Message is a sticker, information about the sticker
230
     *
231
     * @var \TelegramBot\Api\Types\Sticker
232
     */
233
    protected $sticker;
234
235
    /**
236
     * Optional. Message is a video, information about the video
237
     *
238
     * @var \TelegramBot\Api\Types\Video
239
     */
240
    protected $video;
241
242
    /**
243
     * Optional. Message is a voice message, information about the file
244
     *
245
     * @var \TelegramBot\Api\Types\Voice
246
     */
247
    protected $voice;
248
249
    /**
250
     * Optional. Text description of the video (usually empty)
251
     *
252
     * @var string
253
     */
254
    protected $caption;
255
256
    /**
257
     * Optional. Message is a shared contact, information about the contact
258
     *
259
     * @var \TelegramBot\Api\Types\Contact
260
     */
261
    protected $contact;
262
263
    /**
264
     * Optional. Message is a shared location, information about the location
265
     *
266
     * @var \TelegramBot\Api\Types\Location
267
     */
268
    protected $location;
269
270
    /**
271
     * Optional. Message is a venue, information about the venue
272
     *
273
     * @var \TelegramBot\Api\Types\Venue
274
     */
275
    protected $venue;
276
277
    /**
278
     * Optional. Message is a native poll, information about the poll
279
     *
280
     * @var \TelegramBot\Api\Types\Poll
281
     */
282
    protected $poll;
283
284
    /**
285
     * Optional. Message is a dice with random value from 1 to 6
286
     *
287
     * @var \TelegramBot\Api\Types\Dice
288
     */
289
    protected $dice;
290
291
    /**
292
     * Optional. New members that were added to the group or supergroup and information about them
293
     * (the bot itself may be one of these members)
294
     * array of \TelegramBot\Api\Types\User
295
     *
296
     * @var array
297
     */
298
    protected $newChatMembers;
299
300
    /**
301
     * Optional. A member was removed from the group, information about them (this member may be bot itself)
302
     *
303
     * @var \TelegramBot\Api\Types\User
304
     */
305
    protected $leftChatMember;
306
307
    /**
308
     * Optional. A group title was changed to this value
309
     *
310
     * @var string
311
     */
312
    protected $newChatTitle;
313
314
    /**
315
     * Optional. A group photo was change to this value
316
     *
317
     * @var mixed
318
     */
319
    protected $newChatPhoto;
320
321
    /**
322
     * Optional. Informs that the group photo was deleted
323
     *
324
     * @var bool
325
     */
326
    protected $deleteChatPhoto;
327
328
    /**
329
     * Optional. Informs that the group has been created
330
     *
331
     * @var bool
332
     */
333
    protected $groupChatCreated;
334
335
    /**
336
     * Optional. Service message: the supergroup has been created
337
     *
338
     * @var bool
339
     */
340
    protected $supergroupChatCreated;
341
342
    /**
343
     * Optional. Service message: the channel has been created
344
     *
345
     * @var bool
346
     */
347
    protected $channelChatCreated;
348
349
    /**
350
     * Optional. The group has been migrated to a supergroup with the specified identifier,
351
     * not exceeding 1e13 by absolute value
352
     *
353
     * @var int
354
     */
355
    protected $migrateToChatId;
356
357
    /**
358
     * Optional. The supergroup has been migrated from a group with the specified identifier,
359
     * not exceeding 1e13 by absolute value
360
     *
361
     * @var int
362
     */
363
    protected $migrateFromChatId;
364
365
    /**
366
     * Optional. Specified message was pinned.Note that the Message object in this field
367
     * will not contain further reply_to_message fields even if it is itself a reply.
368
     *
369 1
     * @var Message
370
     */
371 1
    protected $pinnedMessage;
372
373
    /**
374
     * Optional. Message is an invoice for a payment, information about the invoice.
375
     *
376
     * @var Invoice
377 2
     */
378
    protected $invoice;
379 2
380 2
    /**
381
     * Optional. Message is a service message about a successful payment, information about the payment.
382
     *
383
     * @var SuccessfulPayment
384
     */
385 1
    protected $successfulPayment;
386
387 1
    /**
388
     * Optional. The domain name of the website on which the user has logged in.
389
     *
390
     * @var string
391
     */
392
    protected $connectedWebsite;
393 2
394
    /**
395 2
     * Optional. Inline keyboard attached to the message. login_url buttons are represented as ordinary url buttons.
396 2
     *
397
     * @var InlineKeyboardMarkup
398
     */
399
    protected $replyMarkup;
400
401 2
    /**
402
     * @return int
403 2
     */
404
    public function getMessageId()
405
    {
406
        return $this->messageId;
407
    }
408
409 15
    /**
410
     * @param int $messageId
411 15
     *
412 15
     * @throws InvalidArgumentException
413
     */
414
    public function setMessageId($messageId)
415
    {
416
        if (is_integer($messageId) || is_float($messageId)) {
417 1
            $this->messageId = $messageId;
0 ignored issues
show
Documentation Bug introduced by
It seems like $messageId can also be of type double. However, the property $messageId is declared as type integer. Maybe add an additional type check?

Our type inference engine has found a suspicous assignment of a value to a property. This check raises an issue when a value that can be of a mixed type is assigned to a property that is type hinted more strictly.

For example, imagine you have a variable $accountId that can either hold an Id object or false (if there is no account id yet). Your code now assigns that value to the id property of an instance of the Account class. This class holds a proper account, so the id value must no longer be false.

Either this assignment is in error or a type check should be added for that assignment.

class Id
{
    public $id;

    public function __construct($id)
    {
        $this->id = $id;
    }

}

class Account
{
    /** @var  Id $id */
    public $id;
}

$account_id = false;

if (starsAreRight()) {
    $account_id = new Id(42);
}

$account = new Account();
if ($account instanceof Id)
{
    $account->id = $account_id;
}
Loading history...
418
        } else {
419 1
            throw new InvalidArgumentException();
420
        }
421
    }
422
423
    /**
424
     * @return User
425 2
     */
426
    public function getFrom()
427 2
    {
428 2
        return $this->from;
429
    }
430
431
    /**
432
     * @param User $from
433 1
     */
434
    public function setFrom(User $from)
435 1
    {
436
        $this->from = $from;
437
    }
438
439
    /**
440
     * @return Chat
441
     */
442
    public function getChat()
443 14
    {
444
        return $this->chat;
445 14
    }
446 13
447 13
    /**
448 1
     * @param Chat $chat
449
     */
450 13
    public function setChat(Chat $chat)
451
    {
452
        $this->chat = $chat;
453
    }
454
455 1
    /**
456
     * @return int
457 1
     */
458
    public function getDate()
459
    {
460
        return $this->date;
461
    }
462
463 2
    /**
464
     * @param int $date
465 2
     *
466 2
     * @throws InvalidArgumentException
467
     */
468
    public function setDate($date)
469
    {
470
        if (is_int($date)) {
471 1
            $this->date = $date;
472
        } else {
473 1
            throw new InvalidArgumentException();
474
        }
475
    }
476
477
    /**
478
     * @return User
479 2
     */
480
    public function getForwardFrom()
481 2
    {
482 2
        return $this->forwardFrom;
483
    }
484
485
    /**
486
     * @param User $forwardFrom
487 1
     */
488
    public function setForwardFrom(User $forwardFrom)
489 1
    {
490
        $this->forwardFrom = $forwardFrom;
491
    }
492
493
    /**
494
     * @return Chat
495
     */
496
    public function getForwardFromChat()
497 3
    {
498
        return $this->forwardFromChat;
499 3
    }
500 2
501 2
    /**
502 1
     * @param Chat $forwardFromChat
503
     */
504 2
    public function setForwardFromChat(Chat $forwardFromChat)
505
    {
506
        $this->forwardFromChat = $forwardFromChat;
507
    }
508
509 1
    /**
510
     * @return int
511 1
     */
512
    public function getForwardFromMessageId()
513
    {
514
        return $this->forwardFromMessageId;
515
    }
516
517 2
    /**
518
     * @param int $forwardFromMessageId
519 2
     */
520 2
    public function setForwardFromMessageId($forwardFromMessageId)
521
    {
522
        $this->forwardFromMessageId = $forwardFromMessageId;
523
    }
524
525
    /**
526
     * @return string
527
     */
528
    public function getForwardSignature()
529
    {
530
        return $this->forwardSignature;
531
    }
532
533
    /**
534
     * @param string $forwardSignature
535
     */
536
    public function setForwardSignature($forwardSignature)
537
    {
538
        $this->forwardSignature = $forwardSignature;
539
    }
540
541
    /**
542
     * @return string
543
     */
544
    public function getForwardSenderName()
545
    {
546
        return $this->forwardSenderName;
547
    }
548
549
    /**
550
     * @param string $forwardSenderName
551
     */
552
    public function setForwardSenderName($forwardSenderName)
553
    {
554
        $this->forwardSenderName = $forwardSenderName;
555
    }
556
557 1
    /**
558
     * @return int
559 1
     */
560
    public function getForwardDate()
561
    {
562
        return $this->forwardDate;
563
    }
564
565 2
    /**
566
     * @param int $forwardDate
567 2
     *
568 2
     * @throws InvalidArgumentException
569
     */
570
    public function setForwardDate($forwardDate)
571
    {
572
        if (is_int($forwardDate)) {
573 1
            $this->forwardDate = $forwardDate;
574
        } else {
575 1
            throw new InvalidArgumentException();
576
        }
577
    }
578
579
    /**
580
     * @return Message
581 2
     */
582
    public function getReplyToMessage()
583 2
    {
584 2
        return $this->replyToMessage;
585
    }
586
587
    /**
588
     * @param Message $replyToMessage
589 1
     */
590
    public function setReplyToMessage(Message $replyToMessage)
591 1
    {
592
        $this->replyToMessage = $replyToMessage;
593
    }
594
595
    /**
596
     * @return int
597 2
     */
598
    public function getEditDate()
599 2
    {
600 2
        return $this->editDate;
601
    }
602
603
    /**
604
     * @param int $editDate
605
     *
606
     * @throws InvalidArgumentException
607
     */
608
    public function setEditDate($editDate)
609
    {
610
        if (is_int($editDate)) {
611
            $this->editDate = $editDate;
612
        } else {
613
            throw new InvalidArgumentException();
614
        }
615
    }
616
617
    /**
618
     * @return int
619
     */
620
    public function getMediaGroupId()
621
    {
622
        return $this->mediaGroupId;
623
    }
624
625
    /**
626
     * @param int $mediaGroupId
627
     */
628
    public function setMediaGroupId($mediaGroupId)
629
    {
630
        $this->mediaGroupId = $mediaGroupId;
631
    }
632
633
    /**
634
     * @return string
635
     */
636
    public function getAuthorSignature()
637 1
    {
638
        return $this->authorSignature;
639 1
    }
640
641
    /**
642
     * @param string $authorSignature
643
     */
644
    public function setAuthorSignature($authorSignature)
645
    {
646
        $this->authorSignature = $authorSignature;
647 15
    }
648
649 15
    /**
650 14
     * @return string
651 14
     */
652 1
    public function getText()
653
    {
654 14
        return $this->text;
655
    }
656
657
    /**
658
     * @param string $text
659 1
     */
660
    public function setText($text)
661 1
    {
662
        $this->text = $text;
663
    }
664
665
    /**
666
     * @return array
667 2
     */
668
    public function getEntities()
669 2
    {
670 2
        return $this->entities;
671
    }
672
673
    /**
674
     * @param array $entities
675 1
     */
676
    public function setEntities($entities)
677 1
    {
678
        $this->entities = $entities;
679
    }
680
681
    /**
682
     * @return ArrayOfMessageEntity
683 2
     */
684
    public function getCaptionEntities()
685 2
    {
686 2
        return $this->captionEntities;
687
    }
688
689
    /**
690
     * @param ArrayOfMessageEntity $captionEntities
691 1
     */
692
    public function setCaptionEntities($captionEntities)
693 1
    {
694
        $this->captionEntities = $captionEntities;
695
    }
696
697
    /**
698
     * @return Audio
699 2
     */
700
    public function getAudio()
701 2
    {
702 2
        return $this->audio;
703
    }
704
705
    /**
706
     * @param Audio $audio
707 1
     */
708
    public function setAudio(Audio $audio)
709 1
    {
710
        $this->audio = $audio;
711
    }
712
713
    /**
714
     * @return Document
715 2
     */
716
    public function getDocument()
717 2
    {
718 2
        return $this->document;
719
    }
720
721
    /**
722
     * @param Document $document
723
     */
724
    public function setDocument($document)
725
    {
726
        $this->document = $document;
727
    }
728
729
    /**
730
     * @return Animation
731
     */
732
    public function getAnimation()
733
    {
734
        return $this->animation;
735
    }
736
737
    /**
738
     * @param Animation $animation
739 1
     */
740
    public function setAnimation(Animation $animation)
741 1
    {
742
        $this->animation = $animation;
743
    }
744
745
    /**
746
     * @return array
747 2
     */
748
    public function getPhoto()
749 2
    {
750 2
        return $this->photo;
751
    }
752
753
    /**
754
     * @param array $photo
755 1
     */
756
    public function setPhoto(array $photo)
757 1
    {
758
        $this->photo = $photo;
759
    }
760
761
    /**
762
     * @return Sticker
763 2
     */
764
    public function getSticker()
765 2
    {
766 2
        return $this->sticker;
767
    }
768
769
    /**
770
     * @param Sticker $sticker
771 7
     */
772
    public function setSticker(Sticker $sticker)
773 7
    {
774
        $this->sticker = $sticker;
775
    }
776
777
    /**
778
     * @return Video
779 5
     */
780
    public function getVideo()
781 5
    {
782 5
        return $this->video;
783
    }
784
785
    /**
786
     * @param Video $video
787
     */
788
    public function setVideo(Video $video)
789
    {
790
        $this->video = $video;
791
    }
792
793
    /**
794
     * @return Voice
795 1
     */
796
    public function getVoice()
797 1
    {
798 1
        return $this->voice;
799
    }
800
801
    /**
802
     * @param Voice $voice
803 1
     */
804
    public function setVoice($voice)
805 1
    {
806
        $this->voice = $voice;
807
    }
808
809
    /**
810
     * @return string
811 13
     */
812
    public function getCaption()
813 13
    {
814 13
        return $this->caption;
815
    }
816
817
    /**
818
     * @param string $caption
819 1
     */
820
    public function setCaption($caption)
821 1
    {
822
        $this->caption = $caption;
823
    }
824
825
    /**
826
     * @return Contact
827 2
     */
828
    public function getContact()
829 2
    {
830 2
        return $this->contact;
831
    }
832
833
    /**
834
     * @param Contact $contact
835
     */
836
    public function setContact(Contact $contact)
837
    {
838
        $this->contact = $contact;
839
    }
840
841
    /**
842
     * @return Location
843
     */
844
    public function getLocation()
845
    {
846
        return $this->location;
847
    }
848
849
    /**
850
     * @param Location $location
851 1
     */
852
    public function setLocation(Location $location)
853 1
    {
854
        $this->location = $location;
855
    }
856
857
    /**
858
     * @return Venue
859 2
     */
860
    public function getVenue()
861 2
    {
862 2
        return $this->venue;
863
    }
864
865
    /**
866
     * @param Venue $venue
867 2
     */
868
    public function setVenue($venue)
869 2
    {
870 2
        $this->venue = $venue;
871
    }
872
873
    /**
874
     * @return Poll
875 1
     */
876
    public function getPoll()
877 1
    {
878
        return $this->poll;
879
    }
880
881
    /**
882
     * @param Poll $poll
883 2
     */
884
    public function setPoll($poll)
885 2
    {
886 2
        $this->poll = $poll;
887
    }
888
889
    /**
890
     * @return Dice
891 1
     */
892
    public function getDice()
893 1
    {
894
        return $this->dice;
895
    }
896
897
    /**
898
     * @param Dice $dice
899 2
     */
900
    public function setDice(Dice $dice)
901 2
    {
902 2
        $this->dice = $dice;
903
    }
904
905
    /**
906
     * @return array
907 1
     */
908
    public function getNewChatMembers()
909 1
    {
910
        return $this->newChatMembers;
911
    }
912
913
    /**
914
     * @param array $newChatMembers
915 4
     */
916
    public function setNewChatMembers($newChatMembers)
917 4
    {
918 4
        $this->newChatMembers = $newChatMembers;
919
    }
920
921
    /**
922
     * @return User
923 1
     */
924
    public function getLeftChatMember()
925 1
    {
926
        return $this->leftChatMember;
927
    }
928
929
    /**
930
     * @param User $leftChatMember
931
     */
932
    public function setLeftChatMember($leftChatMember)
933
    {
934
        $this->leftChatMember = $leftChatMember;
935
    }
936
937
    /**
938
     * @return string
939
     */
940
    public function getNewChatTitle()
941
    {
942
        return $this->newChatTitle;
943
    }
944
945
    /**
946
     * @param string $newChatTitle
947
     */
948
    public function setNewChatTitle($newChatTitle)
949
    {
950
        $this->newChatTitle = $newChatTitle;
951
    }
952
953
    /**
954
     * @return array
955
     */
956
    public function getNewChatPhoto()
957
    {
958
        return $this->newChatPhoto;
959
    }
960
961
    /**
962
     * @param array $newChatPhoto
963
     */
964
    public function setNewChatPhoto($newChatPhoto)
965
    {
966
        $this->newChatPhoto = $newChatPhoto;
967
    }
968
969
    /**
970
     * @return boolean
971
     */
972
    public function isDeleteChatPhoto()
973
    {
974
        return $this->deleteChatPhoto;
975
    }
976
977
    /**
978
     * @param boolean $deleteChatPhoto
979
     */
980
    public function setDeleteChatPhoto($deleteChatPhoto)
981
    {
982
        $this->deleteChatPhoto = (bool)$deleteChatPhoto;
983
    }
984
985
    /**
986
     * @return boolean
987
     */
988
    public function isGroupChatCreated()
989
    {
990
        return $this->groupChatCreated;
991
    }
992
993
    /**
994
     * @param boolean $groupChatCreated
995
     */
996
    public function setGroupChatCreated($groupChatCreated)
997
    {
998
        $this->groupChatCreated = (bool)$groupChatCreated;
999
    }
1000
1001
    /**
1002
     * @return boolean
1003
     */
1004
    public function isSupergroupChatCreated()
1005
    {
1006
        return $this->supergroupChatCreated;
1007
    }
1008
1009
    /**
1010
     * @param boolean $supergroupChatCreated
1011
     */
1012
    public function setSupergroupChatCreated($supergroupChatCreated)
1013
    {
1014
        $this->supergroupChatCreated = $supergroupChatCreated;
1015
    }
1016
1017
    /**
1018
     * @return boolean
1019
     */
1020
    public function isChannelChatCreated()
1021
    {
1022
        return $this->channelChatCreated;
1023
    }
1024
1025
    /**
1026
     * @param boolean $channelChatCreated
1027
     */
1028
    public function setChannelChatCreated($channelChatCreated)
1029
    {
1030
        $this->channelChatCreated = $channelChatCreated;
1031
    }
1032
1033
    /**
1034
     * @return int
1035
     */
1036
    public function getMigrateToChatId()
1037
    {
1038
        return $this->migrateToChatId;
1039
    }
1040
1041
    /**
1042
     * @param int $migrateToChatId
1043
     */
1044
    public function setMigrateToChatId($migrateToChatId)
1045
    {
1046
        $this->migrateToChatId = $migrateToChatId;
1047
    }
1048
1049
    /**
1050
     * @return int
1051
     */
1052
    public function getMigrateFromChatId()
1053
    {
1054
        return $this->migrateFromChatId;
1055
    }
1056
1057
    /**
1058
     * @param int $migrateFromChatId
1059
     */
1060
    public function setMigrateFromChatId($migrateFromChatId)
1061
    {
1062
        $this->migrateFromChatId = $migrateFromChatId;
1063
    }
1064
1065
    /**
1066
     * @return Message
1067
     */
1068
    public function getPinnedMessage()
1069
    {
1070
        return $this->pinnedMessage;
1071
    }
1072
1073
    /**
1074
     * @param Message $pinnedMessage
1075
     */
1076
    public function setPinnedMessage($pinnedMessage)
1077
    {
1078
        $this->pinnedMessage = $pinnedMessage;
1079
    }
1080
1081
    /**
1082
     * @author MY
1083
     * @return Invoice
1084
     */
1085
    public function getInvoice()
1086
    {
1087
        return $this->invoice;
1088
    }
1089
1090
    /**
1091
     * @author MY
1092
     * @param Invoice $invoice
1093
     */
1094
    public function setInvoice($invoice)
1095
    {
1096
        $this->invoice = $invoice;
1097
    }
1098
1099
    /**
1100
     * @author MY
1101
     * @return SuccessfulPayment
1102
     */
1103
    public function getSuccessfulPayment()
1104
    {
1105
        return $this->successfulPayment;
1106
    }
1107
1108
    /**
1109
     * @author MY
1110
     * @param SuccessfulPayment $successfulPayment
1111
     */
1112
    public function setSuccessfulPayment($successfulPayment)
1113
    {
1114
        $this->successfulPayment = $successfulPayment;
1115
    }
1116
1117
    /**
1118
     * @return string
1119
     */
1120
    public function getConnectedWebsite()
1121
    {
1122
        return $this->connectedWebsite;
1123
    }
1124
1125
    /**
1126
     * @param string $connectedWebsite
1127
     */
1128
    public function setConnectedWebsite($connectedWebsite)
1129
    {
1130
        $this->connectedWebsite = $connectedWebsite;
1131
    }
1132
1133
    /**
1134
     * @return InlineKeyboardMarkup
1135
     */
1136
    public function getReplyMarkup()
1137
    {
1138
        return $this->replyMarkup;
1139
    }
1140
1141
    /**
1142
     * @param InlineKeyboardMarkup $replyMarkup
1143
     */
1144
    public function setReplyMarkup($replyMarkup)
1145
    {
1146
        $this->replyMarkup = $replyMarkup;
1147
    }
1148
}
1149