/* */ #ifndef _D_BT_KEEP_ALIVE_MESSAGE_H_ #define _D_BT_KEEP_ALIVE_MESSAGE_H_ #include "SimpleBtMessage.h" namespace aria2 { class BtKeepAliveMessage; typedef SharedHandle BtKeepAliveMessageHandle; class BtKeepAliveMessage : public SimpleBtMessage { private: unsigned char* msg; static const size_t MESSAGE_LENGTH = 4; public: BtKeepAliveMessage():SimpleBtMessage(ID, NAME), msg(0) {} virtual ~BtKeepAliveMessage() { delete [] msg; } static const uint8_t ID = 99; static const std::string NAME; virtual void doReceivedAction() {} virtual const unsigned char* getMessage(); virtual size_t getMessageLength(); virtual std::string toString() const { return NAME; } }; } // namespace aria2 #endif // _D_BT_KEEP_ALIVE_MESSAGE_H_