00001 #ifndef OTMESSAGEERROR_H 00002 #define OTMESSAGEERROR_H 00003 00004 #include "ot_lib.h" 00005 00006 00007 // ------------------------------------------------------ 00008 class ot_messageERROR : public ot_messageResponse 00009 { 00010 private: 00011 00012 auto_ptr<ot_exception> m_ex; 00013 00014 00015 public: 00016 00017 ot_messageERROR(const ot_exception &ex) : 00018 ot_messageResponse(ERROR), 00019 m_ex((ot_exception *) ex.dup()) {} 00020 00021 ~ot_messageERROR(void) {} 00022 00023 /* 00024 int getExce(void) const {return(m_errorI);} 00025 const string & getErrorString(void) const {return(m_errorS);} 00026 */ 00027 00028 ot_exception * getException(void) {return(m_ex.get());} 00029 00030 static ot_messageBase * decode(const ot_map &input); 00031 void encode(ot_map &msg) const; 00032 00033 static const string m_messageCode; 00034 const string getMessageCode(void) const {return(m_messageCode);} 00035 }; 00036 00037 #endif