Passed
Pull Request — master (#408)
by Alexander
02:08 queued 28s
created

Message::getPinnedMessage()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 1
c 1
b 0
f 1
dl 0
loc 3
ccs 0
cts 2
cp 0
rs 10
cc 1
nc 1
nop 0
crap 2
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
        'via_bot' => User::class,
38
        'edit_date' => true,
39
        'media_group_id' => true,
40
        'author_signature' => true,
41
        'text' => true,
42
        'entities' => ArrayOfMessageEntity::class,
43
        'caption_entities' => ArrayOfMessageEntity::class,
44
        'audio' => Audio::class,
45
        'document' => Document::class,
46
        'animation' => Animation::class,
47
        'photo' => ArrayOfPhotoSize::class,
48
        'sticker' => Sticker::class,
49
        'video' => Video::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
        'forum_topic_created' => ForumTopicCreated::class,
72
        'forum_topic_closed' => ForumTopicClosed::class,
73
        'forum_topic_reopened' => ForumTopicReopened::class,
74
        'is_topic_message' => true,
75
        'message_thread_id' => true,
76
        'reply_markup' => InlineKeyboardMarkup::class
77
    ];
78
79
    /**
80
     * Unique message identifier
81
     *
82
     * @var int
83
     */
84
    protected $messageId;
85
86
    /**
87
     * Optional. Sender name. Can be empty for messages sent to channels
88
     *
89
     * @var \TelegramBot\Api\Types\User
90
     */
91
    protected $from;
92
93
    /**
94
     * Date the message was sent in Unix time
95
     *
96
     * @var int
97
     */
98
    protected $date;
99
100
    /**
101
     * Conversation the message belongs to — user in case of a private message, GroupChat in case of a group
102
     *
103
     * @var \TelegramBot\Api\Types\Chat
104
     */
105
    protected $chat;
106
107
    /**
108
     * Optional. For forwarded messages, sender of the original message
109
     *
110
     * @var \TelegramBot\Api\Types\User
111
     */
112
    protected $forwardFrom;
113
114
    /**
115
     * Optional. For messages forwarded from channels, information about
116
     * the original channel
117
     *
118
     * @var \TelegramBot\Api\Types\Chat
119
     */
120
    protected $forwardFromChat;
121
122
    /**
123
     * Optional. For messages forwarded from channels, identifier of
124
     * the original message in the channel
125
     *
126
     * @var int
127
     */
128
    protected $forwardFromMessageId;
129
130
    /**
131
     * Optional. For messages forwarded from channels, signature of the post author if present
132
     *
133
     * @var string
134
     */
135
    protected $forwardSignature;
136
137
    /**
138
     * Optional. Sender's name for messages forwarded from users who disallow adding a link to their account
139
     * in forwarded messages
140
     *
141
     * @var string
142
     */
143
    protected $forwardSenderName;
144
145
    /**
146
     * Optional. For forwarded messages, date the original message was sent in Unix time
147
     *
148
     * @var int
149
     */
150
    protected $forwardDate;
151
152
    /**
153
     * Optional. For replies, the original message. Note that the Message object in this field will not contain further
154
     * reply_to_message fields even if it itself is a reply.
155
     *
156
     * @var \TelegramBot\Api\Types\Message
157
     */
158
    protected $replyToMessage;
159
160
    /**
161
     * Optional. Bot through which the message was sent.
162
     *
163
     * @var \TelegramBot\Api\Types\User
164
     */
165
    protected $viaBot;
166
167
    /**
168
     * Optional. Date the message was last edited in Unix time
169
     *
170
     * @var int
171
     */
172
    protected $editDate;
173
174
    /**
175
     * Optional. The unique identifier of a media message group
176
     * this message belongs to
177
     *
178
     * @var int
179
     */
180
    protected $mediaGroupId;
181
182
    /**
183
     * Optional. Signature of the post author for messages in channels
184
     *
185
     * @var string
186
     */
187
    protected $authorSignature;
188
189
    /**
190
     * Optional. For text messages, the actual UTF-8 text of the message
191
     *
192
     * @var string
193
     */
194
    protected $text;
195
196
    /**
197
     * Optional. For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text.
198
     * array of \TelegramBot\Api\Types\MessageEntity
199
     *
200
     * @var array
201
     */
202
    protected $entities;
203
204
    /**
205
     * Optional. For messages with a caption, special entities like usernames,
206
     * URLs, bot commands, etc. that appear in the caption
207
     *
208
     * @var ArrayOfMessageEntity
209
     */
210
    protected $captionEntities;
211
212
    /**
213
     * Optional. Message is an audio file, information about the file
214
     *
215
     * @var \TelegramBot\Api\Types\Audio
216
     */
217
    protected $audio;
218
219
    /**
220
     * Optional. Message is a general file, information about the file
221
     *
222
     * @var \TelegramBot\Api\Types\Document
223
     */
224
    protected $document;
225
226
    /**
227
     * Optional. Message is a animation, information about the animation
228
     *
229
     * @var \TelegramBot\Api\Types\Animation
230
     */
231
    protected $animation;
232
233
    /**
234
     * Optional. Message is a photo, available sizes of the photo
235
     * array of \TelegramBot\Api\Types\Photo
236
     *
237
     * @var array
238
     */
239
    protected $photo;
240
241
    /**
242
     * Optional. Message is a sticker, information about the sticker
243
     *
244
     * @var \TelegramBot\Api\Types\Sticker
245
     */
246
    protected $sticker;
247
248
    /**
249
     * Optional. Message is a video, information about the video
250
     *
251
     * @var \TelegramBot\Api\Types\Video
252
     */
253
    protected $video;
254
255
    /**
256
     * Optional. Message is a voice message, information about the file
257
     *
258
     * @var \TelegramBot\Api\Types\Voice
259
     */
260
    protected $voice;
261
262
    /**
263
     * Optional. Text description of the video (usually empty)
264
     *
265
     * @var string
266
     */
267
    protected $caption;
268
269
    /**
270
     * Optional. Message is a shared contact, information about the contact
271
     *
272
     * @var \TelegramBot\Api\Types\Contact
273
     */
274
    protected $contact;
275
276
    /**
277
     * Optional. Message is a shared location, information about the location
278
     *
279
     * @var \TelegramBot\Api\Types\Location
280
     */
281
    protected $location;
282
283
    /**
284
     * Optional. Message is a venue, information about the venue
285
     *
286
     * @var \TelegramBot\Api\Types\Venue
287
     */
288
    protected $venue;
289
290
    /**
291
     * Optional. Message is a native poll, information about the poll
292
     *
293
     * @var \TelegramBot\Api\Types\Poll
294
     */
295
    protected $poll;
296
297
    /**
298
     * Optional. Message is a dice with random value from 1 to 6
299
     *
300
     * @var \TelegramBot\Api\Types\Dice
301
     */
302
    protected $dice;
303
304
    /**
305
     * Optional. New members that were added to the group or supergroup and information about them
306
     * (the bot itself may be one of these members)
307
     * array of \TelegramBot\Api\Types\User
308
     *
309
     * @var array
310
     */
311
    protected $newChatMembers;
312
313
    /**
314
     * Optional. A member was removed from the group, information about them (this member may be bot itself)
315
     *
316
     * @var \TelegramBot\Api\Types\User
317
     */
318
    protected $leftChatMember;
319
320
    /**
321
     * Optional. A group title was changed to this value
322
     *
323
     * @var string
324
     */
325
    protected $newChatTitle;
326
327
    /**
328
     * Optional. A group photo was change to this value
329
     *
330
     * @var mixed
331
     */
332
    protected $newChatPhoto;
333
334
    /**
335
     * Optional. Informs that the group photo was deleted
336
     *
337
     * @var bool
338
     */
339
    protected $deleteChatPhoto;
340
341
    /**
342
     * Optional. Informs that the group has been created
343
     *
344
     * @var bool
345
     */
346
    protected $groupChatCreated;
347
348
    /**
349
     * Optional. Service message: the supergroup has been created
350
     *
351
     * @var bool
352
     */
353
    protected $supergroupChatCreated;
354
355
    /**
356
     * Optional. Service message: the channel has been created
357
     *
358
     * @var bool
359
     */
360
    protected $channelChatCreated;
361
362
    /**
363
     * Optional. The group has been migrated to a supergroup with the specified identifier,
364
     * not exceeding 1e13 by absolute value
365
     *
366
     * @var int
367
     */
368
    protected $migrateToChatId;
369
370
    /**
371
     * Optional. The supergroup has been migrated from a group with the specified identifier,
372
     * not exceeding 1e13 by absolute value
373
     *
374
     * @var int
375
     */
376
    protected $migrateFromChatId;
377
378
    /**
379
     * Optional. Specified message was pinned.Note that the Message object in this field
380
     * will not contain further reply_to_message fields even if it is itself a reply.
381
     *
382
     * @var Message
383
     */
384
    protected $pinnedMessage;
385
386
    /**
387
     * Optional. Message is an invoice for a payment, information about the invoice.
388
     *
389
     * @var Invoice
390
     */
391
    protected $invoice;
392
393
    /**
394
     * Optional. Message is a service message about a successful payment, information about the payment.
395
     *
396
     * @var SuccessfulPayment
397
     */
398
    protected $successfulPayment;
399
400
    /**
401
     * Optional. The domain name of the website on which the user has logged in.
402
     *
403
     * @var string
404
     */
405
    protected $connectedWebsite;
406
407
    /**
408
     * Optional. Inline keyboard attached to the message. login_url buttons are represented as ordinary url buttons.
409
     *
410
     * @var InlineKeyboardMarkup
411
     */
412
    protected $replyMarkup;
413
414
    /**
415
     * Optional. Service message: forum topic created
416
     *
417
     * @var ForumTopicCreated
418
     */
419
    protected $forumTopicCreated;
420
421
    /**
422
     * Optional. Service message: forum topic closed
423
     *
424
     * @var ForumTopicReopened
425
     */
426
    protected $forumTopicReopened;
427
428
    /**
429
     * Optional. Service message: forum topic reopened
430
     *
431
     * @var ForumTopicClosed
432
     */
433
    protected $forumTopicClosed;
434
435
    /**
436
     * Optional. True, if the message is sent to a forum topic
437
     *
438
     * @var bool
439
     */
440
    protected $isTopicMessage;
441
442
    /**
443
     * Optional. Unique identifier of a message thread to which the message belongs; for supergroups only
444
     *
445
     * @var int
446
     */
447
    protected $messageThreadId;
448
449
450
    /**
451
     * @return int
452
     */
453 1
    public function getMessageId()
454
    {
455 1
        return $this->messageId;
456
    }
457
458
    /**
459
     * @param int $messageId
460
     *
461
     * @throws InvalidArgumentException
462
     */
463 16
    public function setMessageId($messageId)
464
    {
465 16
        if (is_integer($messageId) || is_float($messageId)) {
0 ignored issues
show
introduced by
The condition is_integer($messageId) is always true.
Loading history...
466 15
            $this->messageId = $messageId;
467 15
        } else {
468 1
            throw new InvalidArgumentException();
469
        }
470 15
    }
471
472
    /**
473
     * @return User
474
     */
475 1
    public function getFrom()
476
    {
477 1
        return $this->from;
478
    }
479
480
    /**
481
     * @param User $from
482
     */
483 14
    public function setFrom(User $from)
484
    {
485 14
        $this->from = $from;
486 14
    }
487
488
    /**
489
     * @return Chat
490
     */
491 2
    public function getChat()
492
    {
493 2
        return $this->chat;
494
    }
495
496
    /**
497
     * @param Chat $chat
498
     */
499 16
    public function setChat(Chat $chat)
500
    {
501 16
        $this->chat = $chat;
502 16
    }
503
504
    /**
505
     * @return int
506
     */
507 1
    public function getDate()
508
    {
509 1
        return $this->date;
510
    }
511
512
    /**
513
     * @param int $date
514
     *
515
     * @throws InvalidArgumentException
516
     */
517 15
    public function setDate($date)
518
    {
519 15
        if (is_int($date)) {
0 ignored issues
show
introduced by
The condition is_int($date) is always true.
Loading history...
520 14
            $this->date = $date;
521 14
        } else {
522 1
            throw new InvalidArgumentException();
523
        }
524 14
    }
525
526
    /**
527
     * @return User
528
     */
529 1
    public function getForwardFrom()
530
    {
531 1
        return $this->forwardFrom;
532
    }
533
534
    /**
535
     * @param User $forwardFrom
536
     */
537 2
    public function setForwardFrom(User $forwardFrom)
538
    {
539 2
        $this->forwardFrom = $forwardFrom;
540 2
    }
541
542
    /**
543
     * @return Chat
544
     */
545
    public function getForwardFromChat()
546
    {
547
        return $this->forwardFromChat;
548
    }
549
550
    /**
551
     * @param Chat $forwardFromChat
552
     */
553
    public function setForwardFromChat(Chat $forwardFromChat)
554
    {
555
        $this->forwardFromChat = $forwardFromChat;
556
    }
557
558
    /**
559
     * @return int
560
     */
561
    public function getForwardFromMessageId()
562
    {
563
        return $this->forwardFromMessageId;
564
    }
565
566
    /**
567
     * @param int $forwardFromMessageId
568
     */
569
    public function setForwardFromMessageId($forwardFromMessageId)
570
    {
571
        $this->forwardFromMessageId = $forwardFromMessageId;
572
    }
573
574
    /**
575
     * @return string
576
     */
577
    public function getForwardSignature()
578
    {
579
        return $this->forwardSignature;
580
    }
581
582
    /**
583
     * @param string $forwardSignature
584
     */
585
    public function setForwardSignature($forwardSignature)
586
    {
587
        $this->forwardSignature = $forwardSignature;
588
    }
589
590
    /**
591
     * @return string
592
     */
593
    public function getForwardSenderName()
594
    {
595
        return $this->forwardSenderName;
596
    }
597
598
    /**
599
     * @param string $forwardSenderName
600
     */
601
    public function setForwardSenderName($forwardSenderName)
602
    {
603
        $this->forwardSenderName = $forwardSenderName;
604
    }
605
606
    /**
607
     * @return int
608
     */
609 1
    public function getForwardDate()
610
    {
611 1
        return $this->forwardDate;
612
    }
613
614
    /**
615
     * @param int $forwardDate
616
     *
617
     * @throws InvalidArgumentException
618
     */
619 3
    public function setForwardDate($forwardDate)
620
    {
621 3
        if (is_int($forwardDate)) {
0 ignored issues
show
introduced by
The condition is_int($forwardDate) is always true.
Loading history...
622 2
            $this->forwardDate = $forwardDate;
623 2
        } else {
624 1
            throw new InvalidArgumentException();
625
        }
626 2
    }
627
628
    /**
629
     * @return Message
630
     */
631 1
    public function getReplyToMessage()
632
    {
633 1
        return $this->replyToMessage;
634
    }
635
636
    /**
637
     * @param Message $replyToMessage
638
     */
639 2
    public function setReplyToMessage(Message $replyToMessage)
640
    {
641 2
        $this->replyToMessage = $replyToMessage;
642 2
    }
643
644
    /**
645
     * @return User
646
     */
647 2
    public function getViaBot()
648
    {
649 2
        return $this->viaBot;
650
    }
651
652
    /**
653
     * @param User $viaBot
654
     */
655 3
    public function setViaBot(User $viaBot)
656
    {
657 3
        $this->viaBot = $viaBot;
658 3
    }
659
660
    /**
661
     * @return int
662
     */
663
    public function getEditDate()
664
    {
665
        return $this->editDate;
666
    }
667
668
    /**
669
     * @param int $editDate
670
     *
671
     * @throws InvalidArgumentException
672
     */
673
    public function setEditDate($editDate)
674
    {
675
        if (is_int($editDate)) {
0 ignored issues
show
introduced by
The condition is_int($editDate) is always true.
Loading history...
676
            $this->editDate = $editDate;
677
        } else {
678
            throw new InvalidArgumentException();
679
        }
680
    }
681
682
    /**
683
     * @return int
684
     */
685
    public function getMediaGroupId()
686
    {
687
        return $this->mediaGroupId;
688
    }
689
690
    /**
691
     * @param int $mediaGroupId
692
     */
693
    public function setMediaGroupId($mediaGroupId)
694
    {
695
        $this->mediaGroupId = $mediaGroupId;
696
    }
697
698
    /**
699
     * @return string
700
     */
701
    public function getAuthorSignature()
702
    {
703
        return $this->authorSignature;
704
    }
705
706
    /**
707
     * @param string $authorSignature
708
     */
709
    public function setAuthorSignature($authorSignature)
710
    {
711
        $this->authorSignature = $authorSignature;
712
    }
713
714
    /**
715
     * @return string
716
     */
717 7
    public function getText()
718
    {
719 7
        return $this->text;
720
    }
721
722
    /**
723
     * @param string $text
724
     */
725 5
    public function setText($text)
726
    {
727 5
        $this->text = $text;
728 5
    }
729
730
    /**
731
     * @return array
732
     */
733
    public function getEntities()
734
    {
735
        return $this->entities;
736
    }
737
738
    /**
739
     * @param array $entities
740
     */
741 1
    public function setEntities($entities)
742
    {
743 1
        $this->entities = $entities;
744 1
    }
745
746
    /**
747
     * @return ArrayOfMessageEntity
748
     */
749
    public function getCaptionEntities()
750
    {
751
        return $this->captionEntities;
752
    }
753
754
    /**
755
     * @param ArrayOfMessageEntity $captionEntities
756
     */
757
    public function setCaptionEntities($captionEntities)
758
    {
759
        $this->captionEntities = $captionEntities;
760
    }
761
762
    /**
763
     * @return Audio
764
     */
765 1
    public function getAudio()
766
    {
767 1
        return $this->audio;
768
    }
769
770
    /**
771
     * @param Audio $audio
772
     */
773 2
    public function setAudio(Audio $audio)
774
    {
775 2
        $this->audio = $audio;
776 2
    }
777
778
    /**
779
     * @return Document
780
     */
781 1
    public function getDocument()
782
    {
783 1
        return $this->document;
784
    }
785
786
    /**
787
     * @param Document $document
788
     */
789 2
    public function setDocument($document)
790
    {
791 2
        $this->document = $document;
792 2
    }
793
794
    /**
795
     * @return Animation
796
     */
797
    public function getAnimation()
798
    {
799
        return $this->animation;
800
    }
801
802
    /**
803
     * @param Animation $animation
804
     */
805
    public function setAnimation(Animation $animation)
806
    {
807
        $this->animation = $animation;
808
    }
809
810
    /**
811
     * @return array
812
     */
813 1
    public function getPhoto()
814
    {
815 1
        return $this->photo;
816
    }
817
818
    /**
819
     * @param array $photo
820
     */
821 2
    public function setPhoto(array $photo)
822
    {
823 2
        $this->photo = $photo;
824 2
    }
825
826
    /**
827
     * @return Sticker
828
     */
829 1
    public function getSticker()
830
    {
831 1
        return $this->sticker;
832
    }
833
834
    /**
835
     * @param Sticker $sticker
836
     */
837 2
    public function setSticker(Sticker $sticker)
838
    {
839 2
        $this->sticker = $sticker;
840 2
    }
841
842
    /**
843
     * @return Video
844
     */
845 1
    public function getVideo()
846
    {
847 1
        return $this->video;
848
    }
849
850
    /**
851
     * @param Video $video
852
     */
853 2
    public function setVideo(Video $video)
854
    {
855 2
        $this->video = $video;
856 2
    }
857
858
    /**
859
     * @return Voice
860
     */
861 1
    public function getVoice()
862
    {
863 1
        return $this->voice;
864
    }
865
866
    /**
867
     * @param Voice $voice
868
     */
869 2
    public function setVoice($voice)
870
    {
871 2
        $this->voice = $voice;
872 2
    }
873
874
    /**
875
     * @return string
876
     */
877 1
    public function getCaption()
878
    {
879 1
        return $this->caption;
880
    }
881
882
    /**
883
     * @param string $caption
884
     */
885 2
    public function setCaption($caption)
886
    {
887 2
        $this->caption = $caption;
888 2
    }
889
890
    /**
891
     * @return Contact
892
     */
893 1
    public function getContact()
894
    {
895 1
        return $this->contact;
896
    }
897
898
    /**
899
     * @param Contact $contact
900
     */
901 2
    public function setContact(Contact $contact)
902
    {
903 2
        $this->contact = $contact;
904 2
    }
905
906
    /**
907
     * @return Location
908
     */
909 1
    public function getLocation()
910
    {
911 1
        return $this->location;
912
    }
913
914
    /**
915
     * @param Location $location
916
     */
917 2
    public function setLocation(Location $location)
918
    {
919 2
        $this->location = $location;
920 2
    }
921
922
    /**
923
     * @return Venue
924
     */
925
    public function getVenue()
926
    {
927
        return $this->venue;
928
    }
929
930
    /**
931
     * @param Venue $venue
932
     */
933
    public function setVenue($venue)
934
    {
935
        $this->venue = $venue;
936
    }
937
938
    /**
939
     * @return Poll
940
     */
941
    public function getPoll()
942
    {
943
        return $this->poll;
944
    }
945
946
    /**
947
     * @param Poll $poll
948
     */
949
    public function setPoll($poll)
950
    {
951
        $this->poll = $poll;
952
    }
953
954
    /**
955
     * @return Dice
956
     */
957 1
    public function getDice()
958
    {
959 1
        return $this->dice;
960
    }
961
962
    /**
963
     * @param Dice $dice
964
     */
965 2
    public function setDice(Dice $dice)
966
    {
967 2
        $this->dice = $dice;
968 2
    }
969
970
    /**
971
     * @return array
972
     */
973 1
    public function getNewChatMembers()
974
    {
975 1
        return $this->newChatMembers;
976
    }
977
978
    /**
979
     * @param array $newChatMembers
980
     */
981 2
    public function setNewChatMembers($newChatMembers)
982
    {
983 2
        $this->newChatMembers = $newChatMembers;
984 2
    }
985
986
    /**
987
     * @return User
988
     */
989 1
    public function getLeftChatMember()
990
    {
991 1
        return $this->leftChatMember;
992
    }
993
994
    /**
995
     * @param User $leftChatMember
996
     */
997 2
    public function setLeftChatMember($leftChatMember)
998
    {
999 2
        $this->leftChatMember = $leftChatMember;
1000 2
    }
1001
1002
    /**
1003
     * @return string
1004
     */
1005 1
    public function getNewChatTitle()
1006
    {
1007 1
        return $this->newChatTitle;
1008
    }
1009
1010
    /**
1011
     * @param string $newChatTitle
1012
     */
1013 2
    public function setNewChatTitle($newChatTitle)
1014
    {
1015 2
        $this->newChatTitle = $newChatTitle;
1016 2
    }
1017
1018
    /**
1019
     * @return array
1020
     */
1021 1
    public function getNewChatPhoto()
1022
    {
1023 1
        return $this->newChatPhoto;
1024
    }
1025
1026
    /**
1027
     * @param array $newChatPhoto
1028
     */
1029 2
    public function setNewChatPhoto($newChatPhoto)
1030
    {
1031 2
        $this->newChatPhoto = $newChatPhoto;
1032 2
    }
1033
1034
    /**
1035
     * @return boolean
1036
     */
1037 1
    public function isDeleteChatPhoto()
1038
    {
1039 1
        return $this->deleteChatPhoto;
1040
    }
1041
1042
    /**
1043
     * @param boolean $deleteChatPhoto
1044
     */
1045 2
    public function setDeleteChatPhoto($deleteChatPhoto)
1046
    {
1047 2
        $this->deleteChatPhoto = (bool)$deleteChatPhoto;
1048 2
    }
1049
1050
    /**
1051
     * @return boolean
1052
     */
1053 1
    public function isGroupChatCreated()
1054
    {
1055 1
        return $this->groupChatCreated;
1056
    }
1057
1058
    /**
1059
     * @param boolean $groupChatCreated
1060
     */
1061 2
    public function setGroupChatCreated($groupChatCreated)
1062
    {
1063 2
        $this->groupChatCreated = (bool)$groupChatCreated;
1064 2
    }
1065
1066
    /**
1067
     * @return boolean
1068
     */
1069 1
    public function isSupergroupChatCreated()
1070
    {
1071 1
        return $this->supergroupChatCreated;
1072
    }
1073
1074
    /**
1075
     * @param boolean $supergroupChatCreated
1076
     */
1077 2
    public function setSupergroupChatCreated($supergroupChatCreated)
1078
    {
1079 2
        $this->supergroupChatCreated = $supergroupChatCreated;
1080 2
    }
1081
1082
    /**
1083
     * @return boolean
1084
     */
1085 1
    public function isChannelChatCreated()
1086
    {
1087 1
        return $this->channelChatCreated;
1088
    }
1089
1090
    /**
1091
     * @param boolean $channelChatCreated
1092
     */
1093 2
    public function setChannelChatCreated($channelChatCreated)
1094
    {
1095 2
        $this->channelChatCreated = $channelChatCreated;
1096 2
    }
1097
1098
    /**
1099
     * @return int
1100
     */
1101 1
    public function getMigrateToChatId()
1102
    {
1103 1
        return $this->migrateToChatId;
1104
    }
1105
1106
    /**
1107
     * @param int $migrateToChatId
1108
     */
1109 2
    public function setMigrateToChatId($migrateToChatId)
1110
    {
1111 2
        $this->migrateToChatId = $migrateToChatId;
1112 2
    }
1113
1114
    /**
1115
     * @return int
1116
     */
1117 1
    public function getMigrateFromChatId()
1118
    {
1119 1
        return $this->migrateFromChatId;
1120
    }
1121
1122
    /**
1123
     * @param int $migrateFromChatId
1124
     */
1125 4
    public function setMigrateFromChatId($migrateFromChatId)
1126
    {
1127 4
        $this->migrateFromChatId = $migrateFromChatId;
1128 4
    }
1129
1130
    /**
1131
     * @return Message
1132
     */
1133
    public function getPinnedMessage()
1134
    {
1135
        return $this->pinnedMessage;
1136
    }
1137
1138
    /**
1139
     * @param Message $pinnedMessage
1140
     */
1141
    public function setPinnedMessage($pinnedMessage)
1142
    {
1143
        $this->pinnedMessage = $pinnedMessage;
1144
    }
1145
1146
    /**
1147
     * @author MY
1148
     * @return Invoice
1149
     */
1150
    public function getInvoice()
1151
    {
1152
        return $this->invoice;
1153
    }
1154
1155
    /**
1156
     * @author MY
1157
     * @param Invoice $invoice
1158
     */
1159
    public function setInvoice($invoice)
1160
    {
1161
        $this->invoice = $invoice;
1162
    }
1163
1164
    /**
1165
     * @author MY
1166
     * @return SuccessfulPayment
1167
     */
1168
    public function getSuccessfulPayment()
1169
    {
1170
        return $this->successfulPayment;
1171
    }
1172
1173
    /**
1174
     * @author MY
1175
     * @param SuccessfulPayment $successfulPayment
1176
     */
1177
    public function setSuccessfulPayment($successfulPayment)
1178
    {
1179
        $this->successfulPayment = $successfulPayment;
1180
    }
1181
1182
    /**
1183
     * @return string
1184
     */
1185
    public function getConnectedWebsite()
1186
    {
1187
        return $this->connectedWebsite;
1188
    }
1189
1190
    /**
1191
     * @param string $connectedWebsite
1192
     */
1193
    public function setConnectedWebsite($connectedWebsite)
1194
    {
1195
        $this->connectedWebsite = $connectedWebsite;
1196
    }
1197
1198
    /**
1199
     * @return InlineKeyboardMarkup
1200
     */
1201
    public function getReplyMarkup()
1202
    {
1203
        return $this->replyMarkup;
1204
    }
1205
1206
    /**
1207
     * @param InlineKeyboardMarkup $replyMarkup
1208
     */
1209
    public function setReplyMarkup($replyMarkup)
1210
    {
1211
        $this->replyMarkup = $replyMarkup;
1212
    }
1213
1214
    /**
1215
     * @return ForumTopicCreated
1216
     */
1217
    public function getForumTopicCreated()
1218
    {
1219
        return $this->forumTopicCreated;
1220
    }
1221
1222
    /**
1223
     * @param ForumTopicCreated $forumTopicCreated
1224
     */
1225
    public function setForumTopicCreated($forumTopicCreated)
1226
    {
1227
        $this->forumTopicCreated = $forumTopicCreated;
1228
    }
1229
1230
    /**
1231
     * @return ForumTopicClosed
1232
     */
1233
    public function getForumTopicClosed()
1234
    {
1235
        return $this->forumTopicClosed;
1236
    }
1237
1238
    /**
1239
     * @param ForumTopicClosed $forumTopicClosed
1240
     */
1241
    public function setForumTopicClosed($forumTopicClosed)
1242
    {
1243
        $this->forumTopicClosed = $forumTopicClosed;
1244
    }
1245
1246
    /**
1247
     * @return ForumTopicReopened
1248
     */
1249
    public function getForumTopicReopened()
1250
    {
1251
        return $this->forumTopicReopened;
1252
    }
1253
1254
    /**
1255
     * @param ForumTopicReopened $forumTopicReopened
1256
     */
1257
    public function setForumTopicReopened($forumTopicReopened)
1258
    {
1259
        $this->forumTopicReopened = $forumTopicReopened;
1260
    }
1261
1262
    /**
1263
     * @return bool
1264
     */
1265
    public function getIsTopicMessage()
1266
    {
1267
        return $this->isTopicMessage;
1268
    }
1269
1270
    /**
1271
     * @param bool $isTopicMessage
1272
     */
1273
    public function setIsTopicMessage($isTopicMessage)
1274
    {
1275
        $this->isTopicMessage = $isTopicMessage;
1276
    }
1277
1278
    /**
1279
     * @return int|null
1280
     */
1281
    public function getMessageThreadId()
1282
    {
1283
        return $this->messageThreadId;
1284
    }
1285
1286
    /**
1287
     * @param int|null $messageThreadId
1288
     */
1289
    public function setMessageThreadId($messageThreadId)
1290
    {
1291
        $this->messageThreadId = $messageThreadId;
1292
    }
1293
}
1294