mmsgroutingsenddata.h
来自「游戏《家园》源码」· C头文件 代码 · 共 58 行
H
58 行
#if !defined(MMsgRoutingSendData_H)
#define MMsgRoutingSendData_H
// MMsgRoutingSendData.h
#include "common/won.h"
#include "AddresseeList.h"
namespace WONMsg {
class MMsgRoutingSendData : public RoutingServerMessage, public AddresseeList {
public:
// Default ctor
MMsgRoutingSendData(void);
// RoutingServerMessage ctor
explicit MMsgRoutingSendData(const RoutingServerMessage& theMsgR);
// Copy ctor
MMsgRoutingSendData(const MMsgRoutingSendData& theMsgR);
// Destructor
virtual ~MMsgRoutingSendData(void);
// Assignment
MMsgRoutingSendData& operator=(const MMsgRoutingSendData& theMsgR);
// Virtual Duplicate from RoutingServerMessage
virtual TRawMsg* Duplicate(void) const;
// Debug output
virtual void Dump(std::ostream& os) const;
// Pack and Unpack the message
// Unpack will throw a BadMsgException is message is not of this type
virtual void* Pack(void);
virtual void Unpack(void);
// Member access
bool ShouldSendReply() const { return mShouldSendReply; }
const WONCommon::RawBuffer& GetData() const { return mData; }
void SetShouldSendReply(bool shouldSendReply) { mShouldSendReply = shouldSendReply; }
void SetData(const WONCommon::RawBuffer& theDataR) { mData = theDataR; }
void AppendToData(const WONCommon::RawBuffer& theAppendandR) { mData += theAppendandR; }
protected:
bool mShouldSendReply;
WONCommon::RawBuffer mData;
};
// Inlines
inline TRawMsg* MMsgRoutingSendData::Duplicate(void) const
{ return new MMsgRoutingSendData(*this); }
}; // Namespace WONMsg
#endif // MMsgRoutingSendData_H
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?