YSTest  PreAlpha_b500_20140530
The YSLib Test Project
 全部 类 命名空间 文件 函数 变量 类型定义 枚举 枚举值 友元 宏定义 组 页
YSLib::Messaging::Message类 参考

消息。 更多...

#include <ymsg.h>

YSLib::Messaging::Message 的协作图:

Public 成员函数

 Message (ID msg_id=0)
 构造:使用消息标识和空消息内容。 更多...
 
 DefDeCopyCtor (Message) DefDeMoveCtor(Message) PDefHOp(Message &
 复制构造:默认实现。 更多...
 
const ValueObject &c ynothrow ImplRet (content=c,*this) PDefHOp(Message &
 成员赋值:使用值类型对象。 更多...
 
const ValueObject &c ynothrow
ValueObject &&c ynothrow 
ImplRet (content=std::move(c),*this) PDefHOp(Message &
 
const ValueObject &c ynothrow
ValueObject &&c ynothrow
Message msg ynothrow 
ImplRet (msg.swap(*this),*this) PDefHOp(bool
 判断无效性。 更多...
 
const ValueObject &c ynothrow
ValueObject &&c ynothrow
Message msg ynothrow const
ynothrow 
ImplRet (!bool(*this)) YF_API friend bool operator
 比较:相等关系。 更多...
 
 DefCvt (const ynothrow, bool, id) DefGetter(const ynothrow
 判断有效性。 更多...
 
id DefGetter (const ynothrow, const ValueObject &, Content, content) void swap(Message &) ynothrow
 < 取消息标识。 更多...
 
 Message (ID m, const ValueObject &vo)
 构造:使用消息标识和消息内容。 更多...
 
 Message (ID m, ValueObject &&vo) ynothrow
 

Public 属性

 ID
 
 MessageID
 

Private 属性

ID id
 消息标识。 更多...
 
ValueObject content
 

友元

class MessageQueue
 

相关函数

(请注意: 这些不是成员函数.)

#define DefSwap(_q, _t)
 消息队列。 更多...
 

详细描述

消息。

警告
非虚析构。
自从
build 145

在文件 ymsg.h 第 66 行定义.

构造及析构函数说明

YSLib::Messaging::Message::Message ( ID  msg_id = 0)
inline

构造:使用消息标识和空消息内容。

自从
build 368

在文件 ymsg.h 第 79 行定义.

YSLib::Messaging::Message::Message ( ID  m,
const ValueObject &  vo 
)
inline

构造:使用消息标识和消息内容。

自从
build 449
build 368

在文件 ymsg.h 第 88 行定义.

YSLib::Messaging::Message::Message ( ID  m,
ValueObject &&  vo 
)
inline

在文件 ymsg.h 第 91 行定义.

成员函数说明

YSLib::Messaging::Message::DefCvt ( const ynothrow  ,
bool  ,
id   
) const
explicit

判断有效性。

自从
build 319
YSLib::Messaging::Message::DefDeCopyCtor ( Message  )

复制构造:默认实现。

转移构造:默认实现。

自从
build 368
id YSLib::Messaging::Message::DefGetter ( const ynothrow  ,
const ValueObject &  ,
Content  ,
content   
)

< 取消息标识。

const ValueObject& c ynothrow YSLib::Messaging::Message::ImplRet ( content  = c,
*  this 
)

成员赋值:使用值类型对象。

自从
build 296
const ValueObject& c ynothrow ValueObject&& c ynothrow YSLib::Messaging::Message::ImplRet ( content  = std::move(c),
*  this 
)
const ValueObject& c ynothrow ValueObject&& c ynothrow Message msg ynothrow YSLib::Messaging::Message::ImplRet ( msg.swap *  this,
*  this 
)

判断无效性。

自从
build 319
const ValueObject& c ynothrow ValueObject&& c ynothrow Message msg ynothrow const ynothrow YSLib::Messaging::Message::ImplRet ( !bool *  this)

比较:相等关系。

自从
build 454

友元及相关函数文档

#define DefSwap (   ynothrow,
  Message 
)
related
值:
PDefH(void, swap, _t& _x, _t& _y) _q \
ImplExpr(_x.swap(_y))

消息队列。

自从
build 409
注解
使用 multiset 模拟。
警告
非虚析构。
自从
build 211
自从
build 449

迭代器。

自从
build 460

无参数构造:默认实现。

取消息队列中消息的最大优先级。

返回
若消息队列为空则 0 ,否则为最大优先级。
自从
build 288

合并消息队列:移动指定消息队列中的所有消息至此消息队列中。

从消息队列中取优先级最高的消息存至 msg 中。

注解
在队列中保留消息;不检查消息是否有效。
自从
build 271

丢弃消息队列中优先级最高的消息。

注解
消息队列为空时忽略。

若消息有效,以指定优先级插入至消息队列中。

自从
build 317

若消息有效,以指定优先级插入至消息队列中。

自从
build 454

移除不大于指定优先级的消息。

自从
build 320
build 449

在文件 ymsg.h 第 157 行定义.

friend class MessageQueue
friend

在文件 ymsg.h 第 68 行定义.

类成员变量说明

ValueObject YSLib::Messaging::Message::content
private

在文件 ymsg.h 第 72 行定义.

参考自 YSLib::Messaging::operator==().

ID YSLib::Messaging::Message::id
private

消息标识。

在文件 ymsg.h 第 71 行定义.

参考自 YSLib::Messaging::operator==().

YSLib::Messaging::Message::ID

在文件 ymsg.h 第 141 行定义.

YSLib::Messaging::Message::MessageID

在文件 ymsg.h 第 141 行定义.


该类的文档由以下文件生成: