00001 //----------------------------------------------------------------------------- 00002 // Author: Jim Holmström 00003 // Date: 2002-02-13 00004 //----------------------------------------------------------------------------- 00005 00006 #ifndef __EXCEPTION_HH 00007 #define __EXCEPTION_HH 00008 00009 #include <exception> 00010 #include <string> 00011 00015 class Exception : public std::exception 00016 { 00017 protected: 00018 std::string m_string; 00019 00020 public: 00021 Exception(std::string const & s) { m_string = s; } 00022 std::string const & ToString() { return m_string; } 00023 char const * ToCString() { return m_string.c_str(); } 00024 }; 00025 00026 #endif