Class AnimationSender
java.lang.Object
io.github.yvasyliev.telegramforwarderbot.service.sender.AnimationSender
Sends animations to Telegram.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.telegram.telegrambots.meta.api.objects.message.Message
sendAnimation
(InputFileDTO animation, String caption) Sends an animation to the Telegram admin chat.
-
Constructor Details
-
AnimationSender
public AnimationSender()
-
-
Method Details
-
sendAnimation
public org.telegram.telegrambots.meta.api.objects.message.Message sendAnimation(InputFileDTO animation, String caption) throws IOException, org.telegram.telegrambots.meta.exceptions.TelegramApiException Sends an animation to the Telegram admin chat.- Parameters:
animation
- the animation to sendcaption
- the caption for the animation, can benull
- Returns:
- the sent message
- Throws:
IOException
- if there is an error reading the animation fileorg.telegram.telegrambots.meta.exceptions.TelegramApiException
- if there is an error sending the animation
-