Incoming
接收到的一条消息的 MessageSource
Types
FromFriend
Link copied to clipboard
abstract class FromFriend @MiraiInternalApi constructor : OnlineMessageSource.Incoming
Content copied to clipboard
FromGroup
Link copied to clipboard
abstract class FromGroup @MiraiInternalApi constructor : OnlineMessageSource.Incoming
Content copied to clipboard
FromStranger
Link copied to clipboard
abstract class FromStranger @MiraiInternalApi constructor : OnlineMessageSource.Incoming
Content copied to clipboard
FromTemp
Link copied to clipboard
abstract class FromTemp @MiraiInternalApi constructor : OnlineMessageSource.Incoming
Content copied to clipboard
Key
Link copied to clipboard
object Key : AbstractPolymorphicMessageKey<OnlineMessageSource, OnlineMessageSource.Incoming.FromTemp>
Content copied to clipboard
Functions
contentEquals
Link copied to clipboard
open fun contentEquals(another: String, ignoreCase: Boolean = false): Boolean
Content copied to clipboard
判断内容是否与 another 相等.
open fun contentEquals(another: Message, ignoreCase: Boolean = false): Boolean
Content copied to clipboard
判断内容是否与 another 相等即 this
与 another 的 contentToString 相等.
open fun contentEquals(another: Message, ignoreCase: Boolean = false, strict: Boolean = false): Boolean
Content copied to clipboard
判断内容是否与 another 相等即 this
与 another 的 contentToString 相等. strict 为 true
时, 还会额外判断每个消息元素的类型, 顺序和属性. 如 Image 会判断 Image.imageId
contentToString
Link copied to clipboard
转为最接近官方格式的字符串. 如 At(member) + "test"
将转为 "@群名片 test"
.
followedBy
Link copied to clipboard
将 this
和 tail 连接.
Properties
internalIds
Link copied to clipboard
key
Link copied to clipboard
用于判断是否为同一种元素的 MessageKey. 使用多态类型 MessageKey 最上层的 MessageKey.
originalMessage
Link copied to clipboard
Inheritors
FromFriend
Link copied to clipboard
FromTemp
Link copied to clipboard
FromStranger
Link copied to clipboard
FromGroup
Link copied to clipboard