mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2024-12-22 16:47:13 +00:00
InlineQueryResult#id type change
This commit is contained in:
parent
e4f305b3ec
commit
89dc7a4b2a
@ -44,6 +44,10 @@
|
||||
|
||||
### 0.28.3
|
||||
|
||||
* `TelegramBotAPI-core`:
|
||||
* All `InlineQueryResult` has changed their type of id for more obvious relation between `InlineQueryResult#id` and
|
||||
`ChosenInlineResult#resultId`: `String` -> `InlineQueryIdentifier`
|
||||
|
||||
### 0.28.2
|
||||
|
||||
* `TelegramBotAPI-extensions-utils`:
|
||||
|
@ -10,7 +10,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
class InlineQueryResultArticle(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(titleField)
|
||||
override val title: String,
|
||||
@SerialName(inputMessageContentField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultAudioCachedImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(audioFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(captionField)
|
||||
|
@ -13,7 +13,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultAudioImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(audioUrlField)
|
||||
override val url: String,
|
||||
@SerialName(titleField)
|
||||
|
@ -11,7 +11,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultContact(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(phoneNumberField)
|
||||
override val phoneNumber: String,
|
||||
@SerialName(firstNameField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultDocumentCachedImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(documentFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(titleField)
|
||||
|
@ -15,7 +15,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultDocumentImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(documentUrlField)
|
||||
override val url: String,
|
||||
@SerialName(titleField)
|
||||
|
@ -1,6 +1,7 @@
|
||||
package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult
|
||||
|
||||
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult.abstracts.InlineQueryResult
|
||||
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueryIdentifier
|
||||
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
|
||||
import com.github.insanusmokrassar.TelegramBotAPI.types.gameShortNameField
|
||||
import kotlinx.serialization.SerialName
|
||||
@ -8,7 +9,7 @@ import kotlinx.serialization.Serializable
|
||||
|
||||
@Serializable
|
||||
class InlineQueryResultGame(
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(gameShortNameField)
|
||||
val gameShortName: String,
|
||||
override val replyMarkup: InlineKeyboardMarkup? = null
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultGifCachedImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(gifFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(titleField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultGifImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(gifUrlField)
|
||||
override val url: String,
|
||||
@SerialName(thumbUrlField)
|
||||
|
@ -12,7 +12,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultLocation(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(latitudeField)
|
||||
override val latitude: Double,
|
||||
@SerialName(longitudeField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultMpeg4GifCachedImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(mpeg4GifFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(titleField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultMpeg4GifImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(mpeg4GifUrlField)
|
||||
override val url: String,
|
||||
@SerialName(thumbUrlField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultPhotoCachedImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(photoFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(titleField)
|
||||
|
@ -13,7 +13,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultPhotoImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(photoUrlField)
|
||||
override val url: String,
|
||||
@SerialName(thumbUrlField)
|
||||
|
@ -11,7 +11,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultStickerCached(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(stickerFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(replyMarkupField)
|
||||
|
@ -12,7 +12,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultVenue(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(latitudeField)
|
||||
override val latitude: Double,
|
||||
@SerialName(longitudeField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultVideoCachedImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(videoFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(titleField)
|
||||
|
@ -15,7 +15,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultVideoImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(videoUrlField)
|
||||
override val url: String,
|
||||
@SerialName(thumbUrlField)
|
||||
|
@ -14,7 +14,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultVoiceCachedImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(voiceFileIdField)
|
||||
override val fileId: FileId,
|
||||
@SerialName(titleField)
|
||||
|
@ -13,7 +13,7 @@ import kotlinx.serialization.Serializable
|
||||
@Serializable
|
||||
data class InlineQueryResultVoiceImpl(
|
||||
@SerialName(idField)
|
||||
override val id: String,
|
||||
override val id: InlineQueryIdentifier,
|
||||
@SerialName(voiceUrlField)
|
||||
override val url: String,
|
||||
@SerialName(titleField)
|
||||
|
@ -1,12 +1,13 @@
|
||||
package com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult.abstracts
|
||||
|
||||
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueries.InlineQueryResult.serializers.InlineQueryResultSerializer
|
||||
import com.github.insanusmokrassar.TelegramBotAPI.types.InlineQueryIdentifier
|
||||
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
|
||||
import kotlinx.serialization.Serializable
|
||||
|
||||
@Serializable(InlineQueryResultSerializer::class)
|
||||
interface InlineQueryResult {
|
||||
val type: String
|
||||
val id: String
|
||||
val id: InlineQueryIdentifier
|
||||
val replyMarkup: InlineKeyboardMarkup?
|
||||
}
|
Loading…
Reference in New Issue
Block a user