MessageParsers

Functions

Link copied to clipboard
fun parse(message: Message, messagesInit: Messages = emptyMessages()): ReceivingMessageParser.Context
fun parse(content: String, attachments: List<Message.Attachment>? = null, messagesInit: Messages = emptyMessages()): ReceivingMessageParser.Context

inline suspend fun parse(message: Message, crossinline onEachPre: MessageSendApi.Body.Builder.() -> Unit = {}, onEachPost: MessageSendApi.Body.Builder.() -> Unit = {}): List<MessageSendApi.Body.Builder>

message 解析为一个或多个 MessageSendApi.Body.Builder

Link copied to clipboard
inline suspend fun parseToGroupAndC2C(bot: QGBot, message: Message, builderType: SendingMessageParser.GroupBuilderType, targetOpenid: String, crossinline factory: () -> GroupAndC2CSendBody, crossinline onEachPre: GroupAndC2CSendBody.() -> Unit = {}, onEachPost: GroupAndC2CSendBody.() -> Unit = {}): List<GroupAndC2CSendBody>