11package com .pengrad .telegrambot .model ;
22
33import com .google .gson .annotations .SerializedName ;
4- import com .pengrad .telegrambot .model .business .BusinessIntro ;
5- import com .pengrad .telegrambot .model .business .BusinessLocation ;
6- import com .pengrad .telegrambot .model .business .BusinessOpeningHours ;
7- import com .pengrad .telegrambot .model .reaction .ReactionType ;
8-
94
105import java .io .Serializable ;
11- import java .util .Arrays ;
126import java .util .Objects ;
137
148/**
@@ -36,41 +30,6 @@ public enum Type {
3630 private String last_name ;
3731
3832 private Boolean is_forum ;
39- private ChatPhoto photo ;
40- private String [] active_usernames ;
41- private Birthdate birthdate ;
42- private BusinessIntro business_intro ;
43- private BusinessLocation business_location ;
44- private BusinessOpeningHours business_opening_hours ;
45- private Chat personal_chat ;
46- private ReactionType [] available_reactions ;
47- private Integer accent_color_id ;
48- private String background_custom_emoji_id ;
49- private Integer profile_accent_color_id ;
50- private String profile_background_custom_emoji_id ;
51- private String emoji_status_custom_emoji_id ;
52- private Integer emoji_status_expiration_date ;
53- private String bio ;
54- private Boolean has_private_forwards ;
55- private Boolean has_restricted_voice_and_video_messages ;
56- private Boolean has_hidden_members ;
57- private Boolean has_aggressive_anti_spam_enabled ;
58- private Boolean join_to_send_messages ;
59- private Boolean join_by_request ;
60- private String description ;
61- private String invite_link ;
62- private Message pinned_message ;
63- private ChatPermissions permissions ;
64- private Integer slow_mode_delay ;
65- private Integer unrestrict_boost_count ;
66- private Integer message_auto_delete_time ;
67- private Boolean has_protected_content ;
68- private Boolean has_visible_history ;
69- private String sticker_set_name ;
70- private Boolean can_set_sticker_set ;
71- private String custom_emoji_sticker_set_name ;
72- private Long linked_chat_id ;
73- private ChatLocation location ;
7433
7534 public Long id () {
7635 return id ;
@@ -100,162 +59,6 @@ public String title() {
10059 return title ;
10160 }
10261
103- public ChatPhoto photo () {
104- return photo ;
105- }
106-
107- /**
108- * @deprecated Use activeUsernames() instead
109- */
110- @ Deprecated
111- public String [] getActiveUsernames () {
112- return active_usernames ;
113- }
114-
115- public String [] activeUsernames () {
116- return active_usernames ;
117- }
118-
119- public Birthdate birthdate () {
120- return birthdate ;
121- }
122-
123- public BusinessIntro businessIntro () {
124- return business_intro ;
125- }
126-
127- public BusinessLocation businessLocation () {
128- return business_location ;
129- }
130-
131- public BusinessOpeningHours businessOpeningHours () {
132- return business_opening_hours ;
133- }
134-
135- public Chat personalChat () {
136- return personal_chat ;
137- }
138-
139- public ReactionType [] availableReactions () {
140- return available_reactions ;
141- }
142-
143- public Integer accentColorId () {
144- return accent_color_id ;
145- }
146-
147- public String backgroundCustomEmojiId () {
148- return background_custom_emoji_id ;
149- }
150-
151- public Integer profileAccentColorId () {
152- return profile_accent_color_id ;
153- }
154-
155- public String profileBackgroundCustomEmojiId () {
156- return profile_background_custom_emoji_id ;
157- }
158-
159- /**
160- * @deprecated Use emojiStatusCustomEmojiId() instead
161- */
162- @ Deprecated
163- public String getEmojiStatusCustomEmojiId () {
164- return emoji_status_custom_emoji_id ;
165- }
166-
167- public String emojiStatusCustomEmojiId () {
168- return emoji_status_custom_emoji_id ;
169- }
170-
171- public Integer emojiStatusExpirationDate () {
172- return emoji_status_expiration_date ;
173- }
174-
175- public String bio () {
176- return bio ;
177- }
178-
179- public Boolean hasPrivateForwards () {
180- return has_private_forwards != null && has_private_forwards ;
181- }
182-
183- public Boolean hasRestrictedVoiceAndVideoMessages () {
184- return has_restricted_voice_and_video_messages != null && has_restricted_voice_and_video_messages ;
185- }
186-
187- public Boolean hasHiddenMembers () {
188- return has_hidden_members != null && has_hidden_members ;
189- }
190-
191- public Boolean hasAggressiveAntiSpamEnabled () {
192- return has_aggressive_anti_spam_enabled != null && has_aggressive_anti_spam_enabled ;
193- }
194-
195- public Boolean joinToSendMessages () {
196- return join_to_send_messages != null && join_to_send_messages ;
197- }
198-
199- public Boolean joinByRequest () {
200- return join_by_request != null && join_by_request ;
201- }
202-
203- public String description () {
204- return description ;
205- }
206-
207- public String inviteLink () {
208- return invite_link ;
209- }
210-
211- public Message pinnedMessage () {
212- return pinned_message ;
213- }
214-
215- public ChatPermissions permissions () {
216- return permissions ;
217- }
218-
219- public Integer slowModeDelay () {
220- return slow_mode_delay ;
221- }
222-
223- public Integer unrestrictBoostCount () {
224- return unrestrict_boost_count ;
225- }
226-
227- public Integer messageAutoDeleteTime () {
228- return message_auto_delete_time ;
229- }
230-
231- public Boolean hasProtectedContent () {
232- return has_protected_content != null && has_protected_content ;
233- }
234-
235- public Boolean hasVisibleHistory () {
236- return has_visible_history != null && has_visible_history ;
237- }
238-
239- public String stickerSetName () {
240- return sticker_set_name ;
241- }
242-
243- public Boolean canSetStickerSet () {
244- return can_set_sticker_set != null && can_set_sticker_set ;
245- }
246-
247- public String customEmojiStickerSetName () {
248- return custom_emoji_sticker_set_name ;
249- }
250-
251- public Long linkedChatId () {
252- return linked_chat_id ;
253- }
254-
255- public ChatLocation location () {
256- return location ;
257- }
258-
25962 @ Override
26063 public boolean equals (Object o ) {
26164 if (this == o ) return true ;
@@ -267,42 +70,7 @@ public boolean equals(Object o) {
26770 Objects .equals (last_name , chat .last_name ) &&
26871 Objects .equals (is_forum , chat .is_forum ) &&
26972 Objects .equals (username , chat .username ) &&
270- Objects .equals (title , chat .title ) &&
271- Objects .equals (photo , chat .photo ) &&
272- Arrays .equals (active_usernames , chat .active_usernames ) &&
273- Objects .equals (birthdate , chat .birthdate ) &&
274- Objects .equals (business_intro , chat .business_intro ) &&
275- Objects .equals (business_location , chat .business_location ) &&
276- Objects .equals (business_opening_hours , chat .business_opening_hours ) &&
277- Objects .equals (personal_chat , chat .personal_chat ) &&
278- Arrays .equals (available_reactions , chat .available_reactions ) &&
279- Objects .equals (accent_color_id , chat .accent_color_id ) &&
280- Objects .equals (background_custom_emoji_id , chat .background_custom_emoji_id ) &&
281- Objects .equals (profile_accent_color_id , chat .profile_accent_color_id ) &&
282- Objects .equals (profile_background_custom_emoji_id , chat .profile_background_custom_emoji_id ) &&
283- Objects .equals (emoji_status_custom_emoji_id , chat .emoji_status_custom_emoji_id ) &&
284- Objects .equals (emoji_status_expiration_date , chat .emoji_status_expiration_date ) &&
285- Objects .equals (bio , chat .bio ) &&
286- Objects .equals (has_private_forwards , chat .has_private_forwards ) &&
287- Objects .equals (has_restricted_voice_and_video_messages , chat .has_restricted_voice_and_video_messages ) &&
288- Objects .equals (has_hidden_members , chat .has_hidden_members ) &&
289- Objects .equals (has_aggressive_anti_spam_enabled , chat .has_aggressive_anti_spam_enabled ) &&
290- Objects .equals (join_to_send_messages , chat .join_to_send_messages ) &&
291- Objects .equals (join_by_request , chat .join_by_request ) &&
292- Objects .equals (description , chat .description ) &&
293- Objects .equals (invite_link , chat .invite_link ) &&
294- Objects .equals (pinned_message , chat .pinned_message ) &&
295- Objects .equals (permissions , chat .permissions ) &&
296- Objects .equals (slow_mode_delay , chat .slow_mode_delay ) &&
297- Objects .equals (unrestrict_boost_count , chat .unrestrict_boost_count ) &&
298- Objects .equals (message_auto_delete_time , chat .message_auto_delete_time ) &&
299- Objects .equals (has_protected_content , chat .has_protected_content ) &&
300- Objects .equals (has_visible_history , chat .has_visible_history ) &&
301- Objects .equals (sticker_set_name , chat .sticker_set_name ) &&
302- Objects .equals (can_set_sticker_set , chat .can_set_sticker_set ) &&
303- Objects .equals (custom_emoji_sticker_set_name , chat .custom_emoji_sticker_set_name ) &&
304- Objects .equals (linked_chat_id , chat .linked_chat_id ) &&
305- Objects .equals (location , chat .location );
73+ Objects .equals (title , chat .title );
30674 }
30775
30876 @ Override
@@ -319,42 +87,7 @@ public String toString() {
31987 ", last_name='" + last_name + '\'' +
32088 ", is_forum=" + is_forum +
32189 ", username='" + username + '\'' +
322- ", title='" + title + '\'' +
323- ", photo=" + photo +
324- ", active_usernames=" + Arrays .toString (active_usernames ) +
325- ", birthdate=" + birthdate +
326- ", business_intro=" + business_intro +
327- ", business_location=" + business_location +
328- ", business_opening_hours=" + business_opening_hours +
329- ", personal_chat=" + personal_chat +
330- ", available_reactions=" + Arrays .toString (available_reactions ) +
331- ", accent_color_id=" + accent_color_id +
332- ", background_custom_emoji_id='" + background_custom_emoji_id + '\'' +
333- ", profile_accent_color_id=" + profile_accent_color_id +
334- ", profile_background_custom_emoji_id='" + profile_background_custom_emoji_id + '\'' +
335- ", emoji_status_custom_emoji_id='" + emoji_status_custom_emoji_id + '\'' +
336- ", emoji_status_expiration_date='" + emoji_status_expiration_date + '\'' +
337- ", bio='" + bio + '\'' +
338- ", has_private_forwards=" + has_private_forwards +
339- ", has_restricted_voice_and_video_messages=" + has_restricted_voice_and_video_messages +
340- ", has_hidden_members=" + has_hidden_members +
341- ", has_aggressive_anti_spam_enabled=" + has_aggressive_anti_spam_enabled +
342- ", join_to_send_messages=" + join_to_send_messages +
343- ", join_by_request=" + join_by_request +
344- ", description='" + description + '\'' +
345- ", invite_link='" + invite_link + '\'' +
346- ", pinned_message=" + pinned_message +
347- ", permissions=" + permissions +
348- ", slow_mode_delay=" + slow_mode_delay +
349- ", unrestrict_boost_count=" + unrestrict_boost_count +
350- ", message_auto_delete_time=" + message_auto_delete_time +
351- ", has_protected_content=" + has_protected_content +
352- ", has_visible_history=" + has_visible_history +
353- ", sticker_set_name='" + sticker_set_name + '\'' +
354- ", can_set_sticker_set=" + can_set_sticker_set +
355- ", custom_emoji_sticker_set_name=" + custom_emoji_sticker_set_name +
356- ", linked_chat_id=" + linked_chat_id +
357- ", location=" + location +
90+ ", title='" + title + '\'' +
35891 '}' ;
35992 }
36093}
0 commit comments