Enum rtdlib::types::TextEntityType
source · [−]pub enum TextEntityType {
Show 18 variants
BankCardNumber(TextEntityTypeBankCardNumber),
Bold(TextEntityTypeBold),
BotCommand(TextEntityTypeBotCommand),
Cashtag(TextEntityTypeCashtag),
Code(TextEntityTypeCode),
EmailAddress(TextEntityTypeEmailAddress),
Hashtag(TextEntityTypeHashtag),
Italic(TextEntityTypeItalic),
MediaTimestamp(TextEntityTypeMediaTimestamp),
Mention(TextEntityTypeMention),
MentionName(TextEntityTypeMentionName),
PhoneNumber(TextEntityTypePhoneNumber),
Pre(TextEntityTypePre),
PreCode(TextEntityTypePreCode),
Strikethrough(TextEntityTypeStrikethrough),
TextUrl(TextEntityTypeTextUrl),
Underline(TextEntityTypeUnderline),
Url(TextEntityTypeUrl),
// some variants omitted
}
Expand description
Represents a part of the text which must be formatted differently
Variants
BankCardNumber(TextEntityTypeBankCardNumber)
A bank card number. The getBankCardInfo method can be used to get information about the bank card
Bold(TextEntityTypeBold)
A bold text
BotCommand(TextEntityTypeBotCommand)
A bot command, beginning with “/”
Cashtag(TextEntityTypeCashtag)
A cashtag text, beginning with “$” and consisting of capital English letters (e.g., “$USD”)
Code(TextEntityTypeCode)
Text that must be formatted as if inside a code HTML tag
EmailAddress(TextEntityTypeEmailAddress)
An email address
Hashtag(TextEntityTypeHashtag)
A hashtag text, beginning with “#”
Italic(TextEntityTypeItalic)
An italic text
MediaTimestamp(TextEntityTypeMediaTimestamp)
A media timestamp
Mention(TextEntityTypeMention)
A mention of a user by their username
MentionName(TextEntityTypeMentionName)
A text shows instead of a raw mention of the user (e.g., when the user has no username)
PhoneNumber(TextEntityTypePhoneNumber)
A phone number
Pre(TextEntityTypePre)
Text that must be formatted as if inside a pre HTML tag
PreCode(TextEntityTypePreCode)
Text that must be formatted as if inside pre, and code HTML tags
Strikethrough(TextEntityTypeStrikethrough)
A strikethrough text
TextUrl(TextEntityTypeTextUrl)
A text description shown instead of a raw URL
Underline(TextEntityTypeUnderline)
An underlined text
Url(TextEntityTypeUrl)
An HTTP URL
Implementations
Trait Implementations
Performs the conversion.
fn deserialize<D>(deserializer: D) -> Result<TextEntityType, D::Error> where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<TextEntityType, D::Error> where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for TextEntityType
impl Send for TextEntityType
impl Sync for TextEntityType
impl Unpin for TextEntityType
impl UnwindSafe for TextEntityType
Blanket Implementations
Mutably borrows from an owned value. Read more