Class InputMedia
- java.lang.Object
-
- io.micronaut.chatbots.telegram.api.InputMedia
-
- Direct Known Subclasses:
InputMediaDocument,InputMediaPhoto
public abstract class InputMedia extends java.lang.ObjectThis object represents the content of a media message to be sent. It should be one of: -InputMediaAnimation-InputMediaDocument-InputMediaPhoto-InputMediaVideo
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedInputMedia(java.lang.String type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetCaption()java.util.List<MessageEntity>getCaptionEntities()java.lang.StringgetMedia()java.lang.StringgetParseMode()java.lang.StringgetType()voidsetCaption(java.lang.String caption)voidsetCaptionEntities(java.util.List<MessageEntity> captionEntities)voidsetMedia(java.lang.String media)voidsetParseMode(java.lang.String parseMode)voidsetType(java.lang.String type)java.lang.StringtoString()
-
-
-
Method Detail
-
getType
@NonNull public java.lang.String getType()
- Returns:
- Type of the result, must be photo.
-
setType
public void setType(@NonNull java.lang.String type)- Parameters:
type- Type of the result, must be photo.
-
getMedia
@NonNull public java.lang.String getMedia()
- Returns:
- File to send.
-
setMedia
public void setMedia(@NonNull java.lang.String media)- Parameters:
media- File to send.
-
getCaption
@Nullable public java.lang.String getCaption()
- Returns:
- Caption of the audio to be sent, 0-1024 characters
-
setCaption
public void setCaption(@Nullable java.lang.String caption)- Parameters:
caption- Caption of the audio to be sent, 0-1024 characters
-
getParseMode
@Nullable public java.lang.String getParseMode()
- Returns:
- Send Markdown or HTML, if you want Telegram apps to show bold, italic, fixed-width text or inline URLs in the media caption.
-
setParseMode
public void setParseMode(@Nullable java.lang.String parseMode)- Parameters:
parseMode- Send Markdown or HTML, if you want Telegram apps to show bold, italic, fixed-width text or inline URLs in the media caption.
-
getCaptionEntities
@Nullable public java.util.List<MessageEntity> getCaptionEntities()
- Returns:
- List of special entities that appear in the caption, which can be specified instead of parse_mode.
-
setCaptionEntities
public void setCaptionEntities(@Nullable java.util.List<MessageEntity> captionEntities)- Parameters:
captionEntities- List of special entities that appear in the caption, which can be specified instead of parse_mode.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-