/* */ #ifndef _D_BT_INTERESTED_MESSAGE_H_ #define _D_BT_INTERESTED_MESSAGE_H_ #include "SimpleBtMessage.h" namespace aria2 { class BtInterestedMessage; typedef SharedHandle BtInterestedMessageHandle; class BtInterestedMessage : public SimpleBtMessage { private: unsigned char* msg; static size_t MESSAGE_LENGTH; public: BtInterestedMessage():msg(0) {} virtual ~BtInterestedMessage() { delete [] msg; } static const uint8_t ID = 2; static BtInterestedMessageHandle create(const unsigned char* data, size_t dataLength); virtual uint8_t getId() { return ID; } virtual void doReceivedAction(); virtual const unsigned char* getMessage(); virtual size_t getMessageLength(); virtual std::string toString() const; virtual bool sendPredicate() const; virtual void onSendComplete(); }; } // namespace aria2 #endif // _D_BT_INTERESTED_MESSAGE_H_