cpp-mirai-client
v2.6.1
cpp client for mirai-api-http
|
来源消息 更多...
#include <SourceMessage.hpp>
Public 成员函数 | |
SourceMessage ()=default | |
MessageId_t | GetMessageId () const |
获取消息id 更多... | |
std::time_t | GetTimestamp () const |
获取消息时间戳 更多... | |
![]() | |
std::unique_ptr< IMessage > | clone () const override |
![]() | |
virtual | ~IMessage ()=default |
virtual std::unique_ptr< IMessage > | clone () const =0 |
MessageTypes | type () const |
Return the type of the class 更多... | |
bool | allowSend () const |
检查消息是否可以用于发送 更多... | |
bool | valid () const |
检查消息是否有效 更多... | |
Protected 成员函数 | |
bool | isValid_ () const final |
![]() | |
IMessageImpl ()=default | |
MessageTypes | GetType_ () const override |
bool | isSendSupported_ () const override |
![]() | |
IMessage ()=default | |
virtual MessageTypes | GetType_ () const =0 |
virtual bool | isSendSupported_ () const =0 |
virtual bool | isValid_ () const =0 |
Protected 属性 | |
MessageId_t | id_ = -1 |
std::time_t | timestamp_ = 0 |
静态 Protected 属性 | |
static constexpr MessageTypes | TYPE_ = MessageTypes::SOURCE |
static constexpr bool | SUPPORT_SEND_ = false |
额外继承的成员函数 | |
![]() | |
static constexpr MessageTypes | GetType () |
static constexpr bool | isSendSupported () |
来源消息
用于标识消息的发送时间与id,仅可用于接收。
Member Variable | Default Value |
---|---|
SourceMessage::id_ | -1 |
SourceMessage::timestamp_ | 0 |
在文件 SourceMessage.hpp 第 39 行定义.
|
default |
|
inlinefinalprotectedvirtual |
实现了 Mirai::IMessage.
在文件 SourceMessage.hpp 第 50 行定义.
|
inline |
获取消息id
在文件 SourceMessage.hpp 第 56 行定义.
|
inline |
获取消息时间戳
在文件 SourceMessage.hpp 第 58 行定义.
|
protected |
在文件 SourceMessage.hpp 第 44 行定义.
|
protected |
在文件 SourceMessage.hpp 第 45 行定义.
|
staticconstexprprotected |
在文件 SourceMessage.hpp 第 47 行定义.
|
staticconstexprprotected |
在文件 SourceMessage.hpp 第 48 行定义.