TelegramMessageEntity
A TelegramMessageElement for MessageEntity.
发送
当发送一个或多个 TelegramMessageEntity 时, 它们会自动聚合为 text
和 entities
。
例如:
send(
createTextLink("GitHub", "https://github.com/") +
",Hello,".toText() +
create("1=1", MessageEntityType.CODE)
)
Content copied to clipboard
发送时会产生大概这样的 Message:
{
...
"text": "GitHub,Hello,1=1",
"entities": [
{
"type": "text_link",
"offset": 0,
"length": 6
},
{
"type": "code",
"offset": 13,
"length": 3
}
]
}
Content copied to clipboard
Inheritors
Types
Link copied to clipboard
An implementation with type MessageEntityType.PRE for TelegramMessageEntity.
Link copied to clipboard
An implementation with type MessageEntityType.PRE for TelegramMessageEntity.
Link copied to clipboard
A simple implementation for TelegramMessageEntity.
Link copied to clipboard
An implementation with type MessageEntityType.TEXT_LINK for TelegramMessageEntity.
Link copied to clipboard
An implementation with type MessageEntityType.TEXT_MENTION for TelegramMessageEntity.