Passed
Pull Request — master (#284)
by
unknown
03:40
created

Message::getCaption()   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
        'video_note' => VideoNote::class,
50
        'voice' => Voice::class,
51
        'caption' => true,
52
        'contact' => Contact::class,
53
        'location' => Location::class,
54
        'venue' => Venue::class,
55
        'poll' => Poll::class,
56
        'dice' => Dice::class,
57
        'new_chat_members' => ArrayOfUser::class,
58
        'left_chat_member' => User::class,
59
        'new_chat_title' => true,
60
        'new_chat_photo' => ArrayOfPhotoSize::class,
61
        'delete_chat_photo' => true,
62
        'group_chat_created' => true,
63
        'supergroup_chat_created' => true,
64
        'channel_chat_created' => true,
65
        'migrate_to_chat_id' => true,
66
        'migrate_from_chat_id' => true,
67
        'pinned_message' => Message::class,
68
        'invoice' => Invoice::class,
69
        'successful_payment' => SuccessfulPayment::class,
70
        'connected_website' => true,
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 video note, information about the video note
244
     *
245
     * @var \TelegramBot\Api\Types\VideoNote
246
     */
247
    protected $videoNote;
248
249
    /**
250
     * Optional. Message is a voice message, information about the file
251
     *
252
     * @var \TelegramBot\Api\Types\Voice
253
     */
254
    protected $voice;
255
256
    /**
257
     * Optional. Text description of the video (usually empty)
258
     *
259
     * @var string
260
     */
261
    protected $caption;
262
263
    /**
264
     * Optional. Message is a shared contact, information about the contact
265
     *
266
     * @var \TelegramBot\Api\Types\Contact
267
     */
268
    protected $contact;
269
270
    /**
271
     * Optional. Message is a shared location, information about the location
272
     *
273
     * @var \TelegramBot\Api\Types\Location
274
     */
275
    protected $location;
276
277
    /**
278
     * Optional. Message is a venue, information about the venue
279
     *
280
     * @var \TelegramBot\Api\Types\Venue
281
     */
282
    protected $venue;
283
284
    /**
285
     * Optional. Message is a native poll, information about the poll
286
     *
287
     * @var \TelegramBot\Api\Types\Poll
288
     */
289
    protected $poll;
290
291
    /**
292
     * Optional. Message is a dice with random value from 1 to 6
293
     *
294
     * @var \TelegramBot\Api\Types\Dice
295
     */
296
    protected $dice;
297
298
    /**
299
     * Optional. New members that were added to the group or supergroup and information about them
300
     * (the bot itself may be one of these members)
301
     * array of \TelegramBot\Api\Types\User
302
     *
303
     * @var array
304
     */
305
    protected $newChatMembers;
306
307
    /**
308
     * Optional. A member was removed from the group, information about them (this member may be bot itself)
309
     *
310
     * @var \TelegramBot\Api\Types\User
311
     */
312
    protected $leftChatMember;
313
314
    /**
315
     * Optional. A group title was changed to this value
316
     *
317
     * @var string
318
     */
319
    protected $newChatTitle;
320
321
    /**
322
     * Optional. A group photo was change to this value
323
     *
324
     * @var mixed
325
     */
326
    protected $newChatPhoto;
327
328
    /**
329
     * Optional. Informs that the group photo was deleted
330
     *
331
     * @var bool
332
     */
333
    protected $deleteChatPhoto;
334
335
    /**
336
     * Optional. Informs that the group has been created
337
     *
338
     * @var bool
339
     */
340
    protected $groupChatCreated;
341
342
    /**
343
     * Optional. Service message: the supergroup has been created
344
     *
345
     * @var bool
346
     */
347
    protected $supergroupChatCreated;
348
349
    /**
350
     * Optional. Service message: the channel has been created
351
     *
352
     * @var bool
353
     */
354
    protected $channelChatCreated;
355
356
    /**
357
     * Optional. The group has been migrated to a supergroup with the specified identifier,
358
     * not exceeding 1e13 by absolute value
359
     *
360
     * @var int
361
     */
362
    protected $migrateToChatId;
363
364
    /**
365
     * Optional. The supergroup has been migrated from a group with the specified identifier,
366
     * not exceeding 1e13 by absolute value
367
     *
368
     * @var int
369
     */
370
    protected $migrateFromChatId;
371
372
    /**
373
     * Optional. Specified message was pinned.Note that the Message object in this field
374
     * will not contain further reply_to_message fields even if it is itself a reply.
375
     *
376
     * @var Message
377
     */
378
    protected $pinnedMessage;
379
380
    /**
381
     * Optional. Message is an invoice for a payment, information about the invoice.
382
     *
383
     * @var Invoice
384
     */
385
    protected $invoice;
386
387
    /**
388
     * Optional. Message is a service message about a successful payment, information about the payment.
389
     *
390
     * @var SuccessfulPayment
391
     */
392
    protected $successfulPayment;
393
394
    /**
395
     * Optional. The domain name of the website on which the user has logged in.
396
     *
397
     * @var string
398
     */
399
    protected $connectedWebsite;
400
401
    /**
402
     * Optional. Inline keyboard attached to the message. login_url buttons are represented as ordinary url buttons.
403
     *
404
     * @var InlineKeyboardMarkup
405
     */
406
    protected $replyMarkup;
407
408
    /**
409
     * @return int
410
     */
411 1
    public function getMessageId()
412
    {
413 1
        return $this->messageId;
414
    }
415
416
    /**
417
     * @param int $messageId
418
     *
419
     * @throws InvalidArgumentException
420
     */
421 15
    public function setMessageId($messageId)
422
    {
423 15
        if (is_integer($messageId) || is_float($messageId)) {
424 14
            $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...
425 14
        } else {
426 1
            throw new InvalidArgumentException();
427
        }
428 14
    }
429
430
    /**
431
     * @return User
432
     */
433 1
    public function getFrom()
434
    {
435 1
        return $this->from;
436
    }
437
438
    /**
439
     * @param User $from
440
     */
441 13
    public function setFrom(User $from)
442
    {
443 13
        $this->from = $from;
444 13
    }
445
446
    /**
447
     * @return Chat
448
     */
449 2
    public function getChat()
450
    {
451 2
        return $this->chat;
452
    }
453
454
    /**
455
     * @param Chat $chat
456
     */
457 15
    public function setChat(Chat $chat)
458
    {
459 15
        $this->chat = $chat;
460 15
    }
461
462
    /**
463
     * @return int
464
     */
465 1
    public function getDate()
466
    {
467 1
        return $this->date;
468
    }
469
470
    /**
471
     * @param int $date
472
     *
473
     * @throws InvalidArgumentException
474
     */
475 14
    public function setDate($date)
476
    {
477 14
        if (is_int($date)) {
478 13
            $this->date = $date;
479 13
        } else {
480 1
            throw new InvalidArgumentException();
481
        }
482 13
    }
483
484
    /**
485
     * @return User
486
     */
487 1
    public function getForwardFrom()
488
    {
489 1
        return $this->forwardFrom;
490
    }
491
492
    /**
493
     * @param User $forwardFrom
494
     */
495 2
    public function setForwardFrom(User $forwardFrom)
496
    {
497 2
        $this->forwardFrom = $forwardFrom;
498 2
    }
499
500
    /**
501
     * @return Chat
502
     */
503
    public function getForwardFromChat()
504
    {
505
        return $this->forwardFromChat;
506
    }
507
508
    /**
509
     * @param Chat $forwardFromChat
510
     */
511
    public function setForwardFromChat(Chat $forwardFromChat)
512
    {
513
        $this->forwardFromChat = $forwardFromChat;
514
    }
515
516
    /**
517
     * @return int
518
     */
519
    public function getForwardFromMessageId()
520
    {
521
        return $this->forwardFromMessageId;
522
    }
523
524
    /**
525
     * @param int $forwardFromMessageId
526
     */
527
    public function setForwardFromMessageId($forwardFromMessageId)
528
    {
529
        $this->forwardFromMessageId = $forwardFromMessageId;
530
    }
531
532
    /**
533
     * @return string
534
     */
535
    public function getForwardSignature()
536
    {
537
        return $this->forwardSignature;
538
    }
539
540
    /**
541
     * @param string $forwardSignature
542
     */
543
    public function setForwardSignature($forwardSignature)
544
    {
545
        $this->forwardSignature = $forwardSignature;
546
    }
547
548
    /**
549
     * @return string
550
     */
551
    public function getForwardSenderName()
552
    {
553
        return $this->forwardSenderName;
554
    }
555
556
    /**
557
     * @param string $forwardSenderName
558
     */
559
    public function setForwardSenderName($forwardSenderName)
560
    {
561
        $this->forwardSenderName = $forwardSenderName;
562
    }
563
564
    /**
565
     * @return int
566
     */
567 1
    public function getForwardDate()
568
    {
569 1
        return $this->forwardDate;
570
    }
571
572
    /**
573
     * @param int $forwardDate
574
     *
575
     * @throws InvalidArgumentException
576
     */
577 3
    public function setForwardDate($forwardDate)
578
    {
579 3
        if (is_int($forwardDate)) {
580 2
            $this->forwardDate = $forwardDate;
581 2
        } else {
582 1
            throw new InvalidArgumentException();
583
        }
584 2
    }
585
586
    /**
587
     * @return Message
588
     */
589 1
    public function getReplyToMessage()
590
    {
591 1
        return $this->replyToMessage;
592
    }
593
594
    /**
595
     * @param Message $replyToMessage
596
     */
597 2
    public function setReplyToMessage(Message $replyToMessage)
598
    {
599 2
        $this->replyToMessage = $replyToMessage;
600 2
    }
601
602
    /**
603
     * @return int
604
     */
605
    public function getEditDate()
606
    {
607
        return $this->editDate;
608
    }
609
610
    /**
611
     * @param int $editDate
612
     *
613
     * @throws InvalidArgumentException
614
     */
615
    public function setEditDate($editDate)
616
    {
617
        if (is_int($editDate)) {
618
            $this->editDate = $editDate;
619
        } else {
620
            throw new InvalidArgumentException();
621
        }
622
    }
623
624
    /**
625
     * @return int
626
     */
627
    public function getMediaGroupId()
628
    {
629
        return $this->mediaGroupId;
630
    }
631
632
    /**
633
     * @param int $mediaGroupId
634
     */
635
    public function setMediaGroupId($mediaGroupId)
636
    {
637
        $this->mediaGroupId = $mediaGroupId;
638
    }
639
640
    /**
641
     * @return string
642
     */
643
    public function getAuthorSignature()
644
    {
645
        return $this->authorSignature;
646
    }
647
648
    /**
649
     * @param string $authorSignature
650
     */
651
    public function setAuthorSignature($authorSignature)
652
    {
653
        $this->authorSignature = $authorSignature;
654
    }
655
656
    /**
657
     * @return string
658
     */
659 7
    public function getText()
660
    {
661 7
        return $this->text;
662
    }
663
664
    /**
665
     * @param string $text
666
     */
667 5
    public function setText($text)
668
    {
669 5
        $this->text = $text;
670 5
    }
671
672
    /**
673
     * @return array
674
     */
675
    public function getEntities()
676
    {
677
        return $this->entities;
678
    }
679
680
    /**
681
     * @param array $entities
682
     */
683 1
    public function setEntities($entities)
684
    {
685 1
        $this->entities = $entities;
686 1
    }
687
688
    /**
689
     * @return ArrayOfMessageEntity
690
     */
691
    public function getCaptionEntities()
692
    {
693
        return $this->captionEntities;
694
    }
695
696
    /**
697
     * @param ArrayOfMessageEntity $captionEntities
698
     */
699
    public function setCaptionEntities($captionEntities)
700
    {
701
        $this->captionEntities = $captionEntities;
702
    }
703
704
    /**
705
     * @return Audio
706
     */
707 1
    public function getAudio()
708
    {
709 1
        return $this->audio;
710
    }
711
712
    /**
713
     * @param Audio $audio
714
     */
715 2
    public function setAudio(Audio $audio)
716
    {
717 2
        $this->audio = $audio;
718 2
    }
719
720
    /**
721
     * @return Document
722
     */
723 1
    public function getDocument()
724
    {
725 1
        return $this->document;
726
    }
727
728
    /**
729
     * @param Document $document
730
     */
731 2
    public function setDocument($document)
732
    {
733 2
        $this->document = $document;
734 2
    }
735
736
    /**
737
     * @return Animation
738
     */
739
    public function getAnimation()
740
    {
741
        return $this->animation;
742
    }
743
744
    /**
745
     * @param Animation $animation
746
     */
747
    public function setAnimation(Animation $animation)
748
    {
749
        $this->animation = $animation;
750
    }
751
752
    /**
753
     * @return array
754
     */
755 1
    public function getPhoto()
756
    {
757 1
        return $this->photo;
758
    }
759
760
    /**
761
     * @param array $photo
762
     */
763 2
    public function setPhoto(array $photo)
764
    {
765 2
        $this->photo = $photo;
766 2
    }
767
768
    /**
769
     * @return Sticker
770
     */
771 1
    public function getSticker()
772
    {
773 1
        return $this->sticker;
774
    }
775
776
    /**
777
     * @param Sticker $sticker
778
     */
779 2
    public function setSticker(Sticker $sticker)
780
    {
781 2
        $this->sticker = $sticker;
782 2
    }
783
784
    /**
785
     * @return Video
786
     */
787 1
    public function getVideo()
788
    {
789 1
        return $this->video;
790
    }
791
792
    /**
793
     * @param Video $video
794
     */
795 2
    public function setVideo(Video $video)
796
    {
797 2
        $this->video = $video;
798 2
    }
799
800
801
    /**
802
     * @return VideoNote
803
     */
804
    public function getVideoNote()
805
    {
806
        return $this->videoNote;
807
    }
808
809
    /**
810
     * @param VideoNote $videoNote
811
     */
812
    public function setVideoNote(VideoNote $videoNote)
813
    {
814
        $this->videoNote = $videoNote;
815
    }
816
817
    /**
818
     * @return Voice
819
     */
820 1
    public function getVoice()
821
    {
822 1
        return $this->voice;
823
    }
824
825
    /**
826
     * @param Voice $voice
827
     */
828 2
    public function setVoice($voice)
829
    {
830 2
        $this->voice = $voice;
831 2
    }
832
833
    /**
834
     * @return string
835
     */
836 1
    public function getCaption()
837
    {
838 1
        return $this->caption;
839
    }
840
841
    /**
842
     * @param string $caption
843
     */
844 2
    public function setCaption($caption)
845
    {
846 2
        $this->caption = $caption;
847 2
    }
848
849
    /**
850
     * @return Contact
851
     */
852 1
    public function getContact()
853
    {
854 1
        return $this->contact;
855
    }
856
857
    /**
858
     * @param Contact $contact
859
     */
860 2
    public function setContact(Contact $contact)
861
    {
862 2
        $this->contact = $contact;
863 2
    }
864
865
    /**
866
     * @return Location
867
     */
868 1
    public function getLocation()
869
    {
870 1
        return $this->location;
871
    }
872
873
    /**
874
     * @param Location $location
875
     */
876 2
    public function setLocation(Location $location)
877
    {
878 2
        $this->location = $location;
879 2
    }
880
881
    /**
882
     * @return Venue
883
     */
884
    public function getVenue()
885
    {
886
        return $this->venue;
887
    }
888
889
    /**
890
     * @param Venue $venue
891
     */
892
    public function setVenue($venue)
893
    {
894
        $this->venue = $venue;
895
    }
896
897
    /**
898
     * @return Poll
899
     */
900
    public function getPoll()
901
    {
902
        return $this->poll;
903
    }
904
905
    /**
906
     * @param Poll $poll
907
     */
908
    public function setPoll($poll)
909
    {
910
        $this->poll = $poll;
911
    }
912
913
    /**
914
     * @return Dice
915
     */
916
    public function getDice()
917
    {
918
        return $this->dice;
919
    }
920
921
    /**
922
     * @param Dice $dice
923
     */
924
    public function setDice(Dice $dice)
925
    {
926
        $this->dice = $dice;
927
    }
928
929
    /**
930
     * @return array
931
     */
932 1
    public function getNewChatMembers()
933
    {
934 1
        return $this->newChatMembers;
935
    }
936
937
    /**
938
     * @param array $newChatMembers
939
     */
940 2
    public function setNewChatMembers($newChatMembers)
941
    {
942 2
        $this->newChatMembers = $newChatMembers;
943 2
    }
944
945
    /**
946
     * @return User
947
     */
948 1
    public function getLeftChatMember()
949
    {
950 1
        return $this->leftChatMember;
951
    }
952
953
    /**
954
     * @param User $leftChatMember
955
     */
956 2
    public function setLeftChatMember($leftChatMember)
957
    {
958 2
        $this->leftChatMember = $leftChatMember;
959 2
    }
960
961
    /**
962
     * @return string
963
     */
964 1
    public function getNewChatTitle()
965
    {
966 1
        return $this->newChatTitle;
967
    }
968
969
    /**
970
     * @param string $newChatTitle
971
     */
972 2
    public function setNewChatTitle($newChatTitle)
973
    {
974 2
        $this->newChatTitle = $newChatTitle;
975 2
    }
976
977
    /**
978
     * @return array
979
     */
980 1
    public function getNewChatPhoto()
981
    {
982 1
        return $this->newChatPhoto;
983
    }
984
985
    /**
986
     * @param array $newChatPhoto
987
     */
988 2
    public function setNewChatPhoto($newChatPhoto)
989
    {
990 2
        $this->newChatPhoto = $newChatPhoto;
991 2
    }
992
993
    /**
994
     * @return boolean
995
     */
996 1
    public function isDeleteChatPhoto()
997
    {
998 1
        return $this->deleteChatPhoto;
999
    }
1000
1001
    /**
1002
     * @param boolean $deleteChatPhoto
1003
     */
1004 2
    public function setDeleteChatPhoto($deleteChatPhoto)
1005
    {
1006 2
        $this->deleteChatPhoto = (bool)$deleteChatPhoto;
1007 2
    }
1008
1009
    /**
1010
     * @return boolean
1011
     */
1012 1
    public function isGroupChatCreated()
1013
    {
1014 1
        return $this->groupChatCreated;
1015
    }
1016
1017
    /**
1018
     * @param boolean $groupChatCreated
1019
     */
1020 2
    public function setGroupChatCreated($groupChatCreated)
1021
    {
1022 2
        $this->groupChatCreated = (bool)$groupChatCreated;
1023 2
    }
1024
1025
    /**
1026
     * @return boolean
1027
     */
1028 1
    public function isSupergroupChatCreated()
1029
    {
1030 1
        return $this->supergroupChatCreated;
1031
    }
1032
1033
    /**
1034
     * @param boolean $supergroupChatCreated
1035
     */
1036 2
    public function setSupergroupChatCreated($supergroupChatCreated)
1037
    {
1038 2
        $this->supergroupChatCreated = $supergroupChatCreated;
1039 2
    }
1040
1041
    /**
1042
     * @return boolean
1043
     */
1044 1
    public function isChannelChatCreated()
1045
    {
1046 1
        return $this->channelChatCreated;
1047
    }
1048
1049
    /**
1050
     * @param boolean $channelChatCreated
1051
     */
1052 2
    public function setChannelChatCreated($channelChatCreated)
1053
    {
1054 2
        $this->channelChatCreated = $channelChatCreated;
1055 2
    }
1056
1057
    /**
1058
     * @return int
1059
     */
1060 1
    public function getMigrateToChatId()
1061
    {
1062 1
        return $this->migrateToChatId;
1063
    }
1064
1065
    /**
1066
     * @param int $migrateToChatId
1067
     */
1068 2
    public function setMigrateToChatId($migrateToChatId)
1069
    {
1070 2
        $this->migrateToChatId = $migrateToChatId;
1071 2
    }
1072
1073
    /**
1074
     * @return int
1075
     */
1076 1
    public function getMigrateFromChatId()
1077
    {
1078 1
        return $this->migrateFromChatId;
1079
    }
1080
1081
    /**
1082
     * @param int $migrateFromChatId
1083
     */
1084 4
    public function setMigrateFromChatId($migrateFromChatId)
1085
    {
1086 4
        $this->migrateFromChatId = $migrateFromChatId;
1087 4
    }
1088
1089
    /**
1090
     * @return Message
1091
     */
1092
    public function getPinnedMessage()
1093
    {
1094
        return $this->pinnedMessage;
1095
    }
1096
1097
    /**
1098
     * @param Message $pinnedMessage
1099
     */
1100
    public function setPinnedMessage($pinnedMessage)
1101
    {
1102
        $this->pinnedMessage = $pinnedMessage;
1103
    }
1104
1105
    /**
1106
     * @author MY
1107
     * @return Invoice
1108
     */
1109
    public function getInvoice()
1110
    {
1111
        return $this->invoice;
1112
    }
1113
1114
    /**
1115
     * @author MY
1116
     * @param Invoice $invoice
1117
     */
1118
    public function setInvoice($invoice)
1119
    {
1120
        $this->invoice = $invoice;
1121
    }
1122
1123
    /**
1124
     * @author MY
1125
     * @return SuccessfulPayment
1126
     */
1127
    public function getSuccessfulPayment()
1128
    {
1129
        return $this->successfulPayment;
1130
    }
1131
1132
    /**
1133
     * @author MY
1134
     * @param SuccessfulPayment $successfulPayment
1135
     */
1136
    public function setSuccessfulPayment($successfulPayment)
1137
    {
1138
        $this->successfulPayment = $successfulPayment;
1139
    }
1140
1141
    /**
1142
     * @return string
1143
     */
1144
    public function getConnectedWebsite()
1145
    {
1146
        return $this->connectedWebsite;
1147
    }
1148
1149
    /**
1150
     * @param string $connectedWebsite
1151
     */
1152
    public function setConnectedWebsite($connectedWebsite)
1153
    {
1154
        $this->connectedWebsite = $connectedWebsite;
1155
    }
1156
1157
    /**
1158
     * @return InlineKeyboardMarkup
1159
     */
1160
    public function getReplyMarkup()
1161
    {
1162
        return $this->replyMarkup;
1163
    }
1164
1165
    /**
1166
     * @param InlineKeyboardMarkup $replyMarkup
1167
     */
1168
    public function setReplyMarkup($replyMarkup)
1169
    {
1170
        $this->replyMarkup = $replyMarkup;
1171
    }
1172
}
1173