From 0f9533e54a83fbb9055e676f4afa850daf988ff5 Mon Sep 17 00:00:00 2001 From: InsanusMokrassar Date: Thu, 7 Feb 2019 11:25:49 +0800 Subject: [PATCH] InputMessageContent filling --- CHANGELOG.md | 10 ++++++++ .../Captioned.kt | 2 +- .../CommonAbstracts/CommonContactData.kt | 8 +++++++ .../CommonAbstracts/CommonVenueData.kt | 8 +++++++ .../TelegramBotAPI/CommonAbstracts/Livable.kt | 8 +++++++ .../Locationed.kt | 2 +- .../types/ByInlineMessageId.kt | 2 +- .../types/ByMessageId.kt | 2 +- .../types/ChatRequest.kt | 2 +- .../types/DisableNotification.kt | 5 ++++ .../types/DisableWebPagePreview.kt | 2 +- .../types/ReplyMarkup.kt | 2 +- .../types/ReplyMessageId.kt | 2 +- .../types/UntilDate.kt | 2 +- .../abstracts/types/DisableNotification.kt | 5 ---- .../requests/chat/ExportChatInviteLink.kt | 2 +- .../TelegramBotAPI/requests/chat/LeaveChat.kt | 2 +- .../chat/abstracts/ChatMemberRequest.kt | 2 +- .../requests/chat/get/GetChat.kt | 2 +- .../chat/get/GetChatAdministrators.kt | 2 +- .../requests/chat/get/GetChatMembersCount.kt | 2 +- .../requests/chat/members/KickChatMember.kt | 2 +- .../chat/members/PromoteChatMember.kt | 2 +- .../chat/members/RestrictChatMember.kt | 2 +- .../requests/chat/modify/DeleteChatPhoto.kt | 2 +- .../requests/chat/modify/PinChatMessage.kt | 4 ++-- .../chat/modify/SetChatDescription.kt | 2 +- .../requests/chat/modify/SetChatPhoto.kt | 2 +- .../requests/chat/modify/SetChatTitle.kt | 2 +- .../requests/chat/modify/UnpinChatMessage.kt | 2 +- .../chat/stickers/DeleteChatStickerSet.kt | 2 +- .../chat/stickers/SetChatStickerSet.kt | 2 +- .../edit/abstracts/EditReplyMessage.kt | 2 +- .../requests/games/GetGameHighScoresByChat.kt | 2 +- .../GetGameHighScoresByInlineMessageId.kt | 2 +- .../requests/games/SetGameScoreByChatId.kt | 2 +- .../games/SetGameScoreByInlineMessageId.kt | 2 +- .../requests/send/SendMessage.kt | 2 +- .../ReplyingMarkupSendMessageRequest.kt | 2 +- .../send/abstracts/SendChatMessageRequest.kt | 2 +- .../send/abstracts/SendMessageRequest.kt | 4 ++-- .../requests/send/games/SendGame.kt | 2 +- .../requests/send/payments/SendInvoice.kt | 2 +- .../types/ChatMember/BannedChatMember.kt | 2 +- .../TelegramBotAPI/types/Common.kt | 1 + .../TelegramBotAPI/types/Contact.kt | 11 +++++---- .../abstracts/CaptionedInlineQueryResult.kt | 2 +- .../abstracts/PositionedInlineQueryResult.kt | 2 +- .../InputContactMessageContent.kt | 19 +++++++++++++++ .../InputLocationMessageContent.kt | 18 ++++++++++++++ .../InputTextMessageContent.kt | 21 ++++++++++++++++ .../InputVenueMessageContent.kt | 24 +++++++++++++++++++ .../abstracts/InputMessageContent.kt | 3 +-- .../TelegramBotAPI/types/Location.kt | 2 +- .../TelegramBotAPI/types/Venue.kt | 11 +++++---- 55 files changed, 178 insertions(+), 60 deletions(-) rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{types/abstracts => CommonAbstracts}/Captioned.kt (71%) create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonContactData.kt create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonVenueData.kt create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Livable.kt rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{types/abstracts => CommonAbstracts}/Locationed.kt (55%) rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{requests/abstracts => CommonAbstracts}/types/ByInlineMessageId.kt (68%) rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{requests/abstracts => CommonAbstracts}/types/ByMessageId.kt (66%) rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{requests/abstracts => CommonAbstracts}/types/ChatRequest.kt (62%) create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/DisableNotification.kt rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{requests/abstracts => CommonAbstracts}/types/DisableWebPagePreview.kt (50%) rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{requests/abstracts => CommonAbstracts}/types/ReplyMarkup.kt (65%) rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{requests/abstracts => CommonAbstracts}/types/ReplyMessageId.kt (66%) rename src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/{requests/abstracts => CommonAbstracts}/types/UntilDate.kt (62%) delete mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/DisableNotification.kt create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputContactMessageContent.kt create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputLocationMessageContent.kt create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputTextMessageContent.kt create mode 100644 src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputVenueMessageContent.kt diff --git a/CHANGELOG.md b/CHANGELOG.md index 779abf4b53..89b494639e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -80,3 +80,13 @@ must be regular text * Update `MediaGroupMessage` interface * Add implementation of `MediaGroupMessage` * Add generating of `MediaGroupMessage` in `RawMessage` + +#### Inline mode changes + +// It is temporal block of changes which will be replaced before complete merge + +* Most part of abstractions was replaced from `requests` and `types` on more high level +* Added abstraction `CommonVenueData` +* Added abstraction `CommonContactData` +* Added `InputMessageContent` +* Update some types and requests according to abstractions replacing diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/abstracts/Captioned.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Captioned.kt similarity index 71% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/abstracts/Captioned.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Captioned.kt index 23bf23b54e..7b3c72c6f5 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/abstracts/Captioned.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Captioned.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.types.abstracts +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonContactData.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonContactData.kt new file mode 100644 index 0000000000..0a7d4b09fc --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonContactData.kt @@ -0,0 +1,8 @@ +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts + +interface CommonContactData { + val phoneNumber: String + val firstName: String + val lastName: String? + val vcard: String? // TODO:: Replace by some vCard abstraction +} \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonVenueData.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonVenueData.kt new file mode 100644 index 0000000000..c8dd1501d6 --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/CommonVenueData.kt @@ -0,0 +1,8 @@ +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts + +interface CommonVenueData { + val title: String + val address: String + val foursquareId: String? + val foursquareType: String? // TODO:: Rewrite with enum or interface +} diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Livable.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Livable.kt new file mode 100644 index 0000000000..d0f268a2d9 --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Livable.kt @@ -0,0 +1,8 @@ +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts + +interface Livable { + /** + * Period in SECONDS + */ + val livePeriod: Int? +} \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/abstracts/Locationed.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Locationed.kt similarity index 55% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/abstracts/Locationed.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Locationed.kt index e8cbbfeba0..0544a94e0c 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/abstracts/Locationed.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/Locationed.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.types.abstracts +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts interface Locationed { val latitude: Double diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ByInlineMessageId.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ByInlineMessageId.kt similarity index 68% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ByInlineMessageId.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ByInlineMessageId.kt index 9bf0c75555..b163e044e5 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ByInlineMessageId.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ByInlineMessageId.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types import com.github.insanusmokrassar.TelegramBotAPI.types.InlineMessageIdentifier diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ByMessageId.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ByMessageId.kt similarity index 66% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ByMessageId.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ByMessageId.kt index 844c1ddfbb..768c99e312 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ByMessageId.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ByMessageId.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types import com.github.insanusmokrassar.TelegramBotAPI.types.MessageIdentifier diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ChatRequest.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ChatRequest.kt similarity index 62% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ChatRequest.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ChatRequest.kt index 6b227e1345..8add2db69b 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ChatRequest.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ChatRequest.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/DisableNotification.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/DisableNotification.kt new file mode 100644 index 0000000000..a07ec1055a --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/DisableNotification.kt @@ -0,0 +1,5 @@ +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types + +interface DisableNotification { + val disableNotification: Boolean +} \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/DisableWebPagePreview.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/DisableWebPagePreview.kt similarity index 50% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/DisableWebPagePreview.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/DisableWebPagePreview.kt index 60790ab8c5..34636ed4b0 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/DisableWebPagePreview.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/DisableWebPagePreview.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types interface DisableWebPagePreview { val disableWebPagePreview: Boolean? diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ReplyMarkup.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ReplyMarkup.kt similarity index 65% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ReplyMarkup.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ReplyMarkup.kt index 71fc490fc2..9536f7c2a9 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ReplyMarkup.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ReplyMarkup.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.KeyboardMarkup diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ReplyMessageId.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ReplyMessageId.kt similarity index 66% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ReplyMessageId.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ReplyMessageId.kt index 9c72d3c704..785c5b6392 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/ReplyMessageId.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/ReplyMessageId.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types import com.github.insanusmokrassar.TelegramBotAPI.types.MessageIdentifier diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/UntilDate.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/UntilDate.kt similarity index 62% rename from src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/UntilDate.kt rename to src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/UntilDate.kt index 3b22c62855..7be9229808 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/UntilDate.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/CommonAbstracts/types/UntilDate.kt @@ -1,4 +1,4 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types +package com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types import com.github.insanusmokrassar.TelegramBotAPI.types.TelegramDate diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/DisableNotification.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/DisableNotification.kt deleted file mode 100644 index e9feb38ff1..0000000000 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/abstracts/types/DisableNotification.kt +++ /dev/null @@ -1,5 +0,0 @@ -package com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types - -interface DisableNotification { - val disableNotification: Boolean -} \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/ExportChatInviteLink.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/ExportChatInviteLink.kt index d88cdbd862..e595a5580b 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/ExportChatInviteLink.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/ExportChatInviteLink.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/LeaveChat.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/LeaveChat.kt index abe7ba5185..5b9e145d3e 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/LeaveChat.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/LeaveChat.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/abstracts/ChatMemberRequest.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/abstracts/ChatMemberRequest.kt index 408a4973ed..8d83987fa5 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/abstracts/ChatMemberRequest.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/abstracts/ChatMemberRequest.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.UserId interface ChatMemberRequest : ChatRequest, SimpleRequest { diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChat.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChat.kt index 1fdde3afb5..4625b9dd9a 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChat.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChat.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.chat.RawChat import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatAdministrators.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatAdministrators.kt index 0733cacd82..b29d1c3d98 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatAdministrators.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatAdministrators.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.ChatMember.RawChatMember import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatMembersCount.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatMembersCount.kt index c7d11a722e..9d28fc4021 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatMembersCount.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/get/GetChatMembersCount.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.get import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/KickChatMember.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/KickChatMember.kt index d6c9db5775..96f917ab9c 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/KickChatMember.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/KickChatMember.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.UntilDate +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.UntilDate import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/PromoteChatMember.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/PromoteChatMember.kt index 599834c976..4751adb8c6 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/PromoteChatMember.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/PromoteChatMember.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.UntilDate +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.UntilDate import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/RestrictChatMember.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/RestrictChatMember.kt index 6706b899b0..cf960fa91b 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/RestrictChatMember.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/members/RestrictChatMember.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.members -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.UntilDate +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.UntilDate import com.github.insanusmokrassar.TelegramBotAPI.requests.chat.abstracts.ChatMemberRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/DeleteChatPhoto.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/DeleteChatPhoto.kt index fc4608d176..2a43b04c72 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/DeleteChatPhoto.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/DeleteChatPhoto.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/PinChatMessage.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/PinChatMessage.kt index 63908dbc6a..430af565cb 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/PinChatMessage.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/PinChatMessage.kt @@ -1,8 +1,8 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.DisableNotification +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.DisableNotification import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* import kotlinx.serialization.internal.BooleanSerializer diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatDescription.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatDescription.kt index fd0d33f983..9c4b1ab62d 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatDescription.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatDescription.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* import kotlinx.serialization.internal.BooleanSerializer diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatPhoto.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatPhoto.kt index 5053581e67..7aa0d80c3e 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatPhoto.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatPhoto.kt @@ -2,7 +2,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.MultipartFile import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.MultipartRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* import kotlinx.serialization.internal.BooleanSerializer diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatTitle.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatTitle.kt index faf46fa7e1..f98f80b39b 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatTitle.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/SetChatTitle.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* import kotlinx.serialization.internal.BooleanSerializer diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/UnpinChatMessage.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/UnpinChatMessage.kt index 1ef661ec56..18154fc892 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/UnpinChatMessage.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/modify/UnpinChatMessage.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.modify import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/DeleteChatStickerSet.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/DeleteChatStickerSet.kt index a224ebd87d..ef3c36ab43 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/DeleteChatStickerSet.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/DeleteChatStickerSet.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.stickers import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.ChatIdentifier import com.github.insanusmokrassar.TelegramBotAPI.types.chatIdField import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/SetChatStickerSet.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/SetChatStickerSet.kt index 207895dc4c..cfa6a469fe 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/SetChatStickerSet.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/chat/stickers/SetChatStickerSet.kt @@ -1,7 +1,7 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.chat.stickers import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* import kotlinx.serialization.internal.BooleanSerializer diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/edit/abstracts/EditReplyMessage.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/edit/abstracts/EditReplyMessage.kt index 94fcf34ff6..9cfe3b6718 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/edit/abstracts/EditReplyMessage.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/edit/abstracts/EditReplyMessage.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.edit.abstracts -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ReplyMarkup +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ReplyMarkup import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup interface EditReplyMessage : ReplyMarkup { diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByChat.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByChat.kt index bbc42ff686..47d96d04b0 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByChat.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByChat.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.games -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ByMessageId +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ByMessageId import com.github.insanusmokrassar.TelegramBotAPI.requests.games.abstracts.GetGameHighScores import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.SerialName diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByInlineMessageId.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByInlineMessageId.kt index 6d9d8cae81..b5e7aadc2e 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByInlineMessageId.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/GetGameHighScoresByInlineMessageId.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.games -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ByInlineMessageId +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ByInlineMessageId import com.github.insanusmokrassar.TelegramBotAPI.requests.games.abstracts.GetGameHighScores import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.SerialName diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByChatId.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByChatId.kt index e6a96cccb7..f5a057be78 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByChatId.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByChatId.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.games -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ByMessageId +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ByMessageId import com.github.insanusmokrassar.TelegramBotAPI.requests.games.abstracts.SetGameScore import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByInlineMessageId.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByInlineMessageId.kt index efd78d4563..67551d60bc 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByInlineMessageId.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/games/SetGameScoreByInlineMessageId.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.games -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ByInlineMessageId +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ByInlineMessageId import com.github.insanusmokrassar.TelegramBotAPI.requests.games.abstracts.SetGameScore import com.github.insanusmokrassar.TelegramBotAPI.types.* import kotlinx.serialization.* diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/SendMessage.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/SendMessage.kt index 1e6c7b5d8e..8e7c7b16bd 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/SendMessage.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/SendMessage.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.send -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.DisableWebPagePreview +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.DisableWebPagePreview import com.github.insanusmokrassar.TelegramBotAPI.requests.send.abstracts.* import com.github.insanusmokrassar.TelegramBotAPI.types.* import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/ReplyingMarkupSendMessageRequest.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/ReplyingMarkupSendMessageRequest.kt index adcfaeff88..85a7d41746 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/ReplyingMarkupSendMessageRequest.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/ReplyingMarkupSendMessageRequest.kt @@ -1,5 +1,5 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.send.abstracts -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ReplyMarkup +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ReplyMarkup interface ReplyingMarkupSendMessageRequest: SendMessageRequest, ReplyMarkup \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendChatMessageRequest.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendChatMessageRequest.kt index 56ed3cb4d6..40760c976b 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendChatMessageRequest.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendChatMessageRequest.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.send.abstracts import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.SimpleRequest -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ChatRequest +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ChatRequest interface SendChatMessageRequest : SimpleRequest, ChatRequest \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendMessageRequest.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendMessageRequest.kt index 31ea67cf0a..7ace010c70 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendMessageRequest.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/abstracts/SendMessageRequest.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.send.abstracts -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.DisableNotification -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ReplyMessageId +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.DisableNotification +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ReplyMessageId interface SendMessageRequest : SendChatMessageRequest, ReplyMessageId, DisableNotification diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/games/SendGame.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/games/SendGame.kt index 2704ee8be6..38ba35bb1a 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/games/SendGame.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/games/SendGame.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.send.games -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.ReplyMarkup +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.ReplyMarkup import com.github.insanusmokrassar.TelegramBotAPI.requests.send.abstracts.SendMessageRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.KeyboardMarkup diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/payments/SendInvoice.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/payments/SendInvoice.kt index 4c7d4b6c9d..7f4239b4f1 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/payments/SendInvoice.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/requests/send/payments/SendInvoice.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.requests.send.payments -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.* +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.* import com.github.insanusmokrassar.TelegramBotAPI.requests.send.abstracts.SendMessageRequest import com.github.insanusmokrassar.TelegramBotAPI.types.* import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/ChatMember/BannedChatMember.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/ChatMember/BannedChatMember.kt index 31ef2097bc..1bf15213b8 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/ChatMember/BannedChatMember.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/ChatMember/BannedChatMember.kt @@ -1,5 +1,5 @@ package com.github.insanusmokrassar.TelegramBotAPI.types.ChatMember -import com.github.insanusmokrassar.TelegramBotAPI.requests.abstracts.types.UntilDate +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.UntilDate interface BannedChatMember : ChatMember, UntilDate \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Common.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Common.kt index e9e28b1d50..7b2733b247 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Common.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Common.kt @@ -58,6 +58,7 @@ const val foursquareIdField = "foursquare_id" const val foursquareTypeField = "foursquare_type" const val untilDateField = "until_date" const val errorMessageField = "error_message" +const val messageTextField = "message_text" const val photoUrlField = "photo_url" const val photoSizeField = "photo_size" diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Contact.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Contact.kt index 09b4ed72ea..c1fc7610d8 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Contact.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Contact.kt @@ -1,19 +1,20 @@ package com.github.insanusmokrassar.TelegramBotAPI.types +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.CommonContactData import kotlinx.serialization.* @Serializable data class Contact( @SerialName(phoneNumberField) - val phoneNumber: String, + override val phoneNumber: String, @SerialName(firstNameField) - val firstName: String, + override val firstName: String, @SerialName(lastNameField) @Optional - val lastName: String? = null, + override val lastName: String? = null, @SerialName(userIdField) @Optional val userId: UserId? = null, @Optional - val vcard: String? = null -) + override val vcard: String? = null +) : CommonContactData diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/CaptionedInlineQueryResult.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/CaptionedInlineQueryResult.kt index 0e00f81679..6973c94ea0 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/CaptionedInlineQueryResult.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/CaptionedInlineQueryResult.kt @@ -1,5 +1,5 @@ package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult.abstracts -import com.github.insanusmokrassar.TelegramBotAPI.types.abstracts.Captioned +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.Captioned interface CaptionedInlineQueryResult : InlineQueryResult, Captioned diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/PositionedInlineQueryResult.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/PositionedInlineQueryResult.kt index b1b1748b66..22387eced2 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/PositionedInlineQueryResult.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InlineQueryResult/abstracts/PositionedInlineQueryResult.kt @@ -1,5 +1,5 @@ package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult.abstracts -import com.github.insanusmokrassar.TelegramBotAPI.types.abstracts.Locationed +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.Locationed interface PositionedInlineQueryResult : InlineQueryResult, Locationed \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputContactMessageContent.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputContactMessageContent.kt new file mode 100644 index 0000000000..e08718eaf7 --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputContactMessageContent.kt @@ -0,0 +1,19 @@ +package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InputMessageContent + +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.CommonContactData +import com.github.insanusmokrassar.TelegramBotAPI.types.* +import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.abstracts.InputMessageContent +import kotlinx.serialization.* + +@Serializable +data class InputContactMessageContent( + @SerialName(phoneNumberField) + override val phoneNumber: String, + @SerialName(firstNameField) + override val firstName: String, + @SerialName(lastNameField) + @Optional + override val lastName: String? = null, + @Optional + override val vcard: String? = null +) : CommonContactData, InputMessageContent \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputLocationMessageContent.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputLocationMessageContent.kt new file mode 100644 index 0000000000..747d23d067 --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputLocationMessageContent.kt @@ -0,0 +1,18 @@ +package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InputMessageContent + +import com.github.insanusmokrassar.TelegramBotAPI.types.* +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.Livable +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.Locationed +import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.abstracts.InputMessageContent +import kotlinx.serialization.* + +@Serializable +data class InputLocationMessageContent( + @SerialName(latitudeField) + override val latitude: Double, + @SerialName(longitudeField) + override val longitude: Double, + @SerialName(livePeriodField) + @Optional + override val livePeriod: Int? = null +) : Locationed, Livable, InputMessageContent \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputTextMessageContent.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputTextMessageContent.kt new file mode 100644 index 0000000000..d8fc3af32f --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputTextMessageContent.kt @@ -0,0 +1,21 @@ +package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InputMessageContent + +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.types.DisableWebPagePreview +import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.ParseMode +import com.github.insanusmokrassar.TelegramBotAPI.types.ParseMode.parseModeField +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.Captioned +import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.abstracts.InputMessageContent +import com.github.insanusmokrassar.TelegramBotAPI.types.disableWebPagePreviewField +import com.github.insanusmokrassar.TelegramBotAPI.types.messageTextField +import kotlinx.serialization.* + +@Serializable +data class InputTextMessageContent( + @SerialName(messageTextField) + override val caption: String, + @SerialName(parseModeField) + override val parseMode: ParseMode, + @SerialName(disableWebPagePreviewField) + @Optional + override val disableWebPagePreview: Boolean? = null +) : Captioned, DisableWebPagePreview, InputMessageContent \ No newline at end of file diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputVenueMessageContent.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputVenueMessageContent.kt new file mode 100644 index 0000000000..9cc65db875 --- /dev/null +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/InputMessageContent/InputVenueMessageContent.kt @@ -0,0 +1,24 @@ +package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InputMessageContent + +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.* +import com.github.insanusmokrassar.TelegramBotAPI.types.* +import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.abstracts.InputMessageContent +import kotlinx.serialization.* + +@Serializable +data class InputVenueMessageContent( + @SerialName(latitudeField) + override val latitude: Double, + @SerialName(longitudeField) + override val longitude: Double, + @SerialName(titleField) + override val title: String, + @SerialName(addressField) + override val address: String, + @SerialName(foursquareIdField) + @Optional + override val foursquareId: String? = null, + @SerialName(foursquareTypeField) + @Optional + override val foursquareType: String? = null +) : Locationed, CommonVenueData, InputMessageContent diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/abstracts/InputMessageContent.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/abstracts/InputMessageContent.kt index fa2ec1f741..f36cbb3a20 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/abstracts/InputMessageContent.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/InlineQueries/abstracts/InputMessageContent.kt @@ -1,4 +1,3 @@ package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.abstracts -interface InputMessageContent { -} \ No newline at end of file +interface InputMessageContent diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Location.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Location.kt index 3d313c268d..29ab9f3472 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Location.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Location.kt @@ -1,6 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.types -import com.github.insanusmokrassar.TelegramBotAPI.types.abstracts.Locationed +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.Locationed import kotlinx.serialization.SerialName import kotlinx.serialization.Serializable diff --git a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Venue.kt b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Venue.kt index f979d0131c..8a7514a62d 100644 --- a/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Venue.kt +++ b/src/main/kotlin/com/github/insanusmokrassar/TelegramBotAPI/types/Venue.kt @@ -1,5 +1,6 @@ package com.github.insanusmokrassar.TelegramBotAPI.types +import com.github.insanusmokrassar.TelegramBotAPI.CommonAbstracts.CommonVenueData import kotlinx.serialization.* @Serializable @@ -7,13 +8,13 @@ data class Venue( @SerialName(locationField) val location: Location, @SerialName(titleField) - val title: String, + override val title: String, @SerialName(addressField) - val address: String, + override val address: String, @SerialName(foursquareIdField) @Optional - val foursquareId: String? = null, + override val foursquareId: String? = null, @SerialName(foursquareTypeField) @Optional - val foursquareType: String? = null // TODO:: Rewrite with enum or interface -) + override val foursquareType: String? = null +) : CommonVenueData