2020-10-04 10:57:39 +00:00
|
|
|
package dev.inmo.tgbotapi.extensions.api
|
2020-02-15 09:33:04 +00:00
|
|
|
|
2020-10-04 07:18:24 +00:00
|
|
|
import com.github.insanusmokrassar.TelegramBotAPI.bot.TelegramBot
|
2020-02-15 09:33:04 +00:00
|
|
|
import com.github.insanusmokrassar.TelegramBotAPI.requests.StopPoll
|
|
|
|
import com.github.insanusmokrassar.TelegramBotAPI.types.*
|
|
|
|
import com.github.insanusmokrassar.TelegramBotAPI.types.buttons.InlineKeyboardMarkup
|
|
|
|
import com.github.insanusmokrassar.TelegramBotAPI.types.chat.abstracts.Chat
|
|
|
|
import com.github.insanusmokrassar.TelegramBotAPI.types.message.abstracts.Message
|
|
|
|
|
2020-10-04 07:18:24 +00:00
|
|
|
suspend fun TelegramBot.stopPoll(
|
2020-02-15 09:33:04 +00:00
|
|
|
chatId: ChatIdentifier,
|
|
|
|
messageId: MessageIdentifier,
|
|
|
|
replyMarkup: InlineKeyboardMarkup? = null
|
|
|
|
) = execute(
|
|
|
|
StopPoll(chatId, messageId, replyMarkup)
|
|
|
|
)
|
|
|
|
|
2020-10-04 07:18:24 +00:00
|
|
|
suspend fun TelegramBot.stopPoll(
|
2020-02-15 09:33:04 +00:00
|
|
|
chat: Chat,
|
|
|
|
messageId: MessageIdentifier,
|
|
|
|
replyMarkup: InlineKeyboardMarkup? = null
|
|
|
|
) = stopPoll(chat.id, messageId, replyMarkup)
|
|
|
|
|
2020-10-04 07:18:24 +00:00
|
|
|
suspend fun TelegramBot.stopPoll(
|
2020-02-15 09:33:04 +00:00
|
|
|
chatId: ChatId,
|
|
|
|
message: Message,
|
|
|
|
replyMarkup: InlineKeyboardMarkup? = null
|
|
|
|
) = stopPoll(chatId, message.messageId, replyMarkup)
|
|
|
|
|
2020-10-04 07:18:24 +00:00
|
|
|
suspend fun TelegramBot.stopPoll(
|
2020-02-15 09:33:04 +00:00
|
|
|
chat: Chat,
|
|
|
|
message: Message,
|
|
|
|
replyMarkup: InlineKeyboardMarkup? = null
|
|
|
|
) = stopPoll(chat.id, message.messageId, replyMarkup)
|