standard_exception.hpp
Go to the documentation of this file.
00001 
00011 /*****************************************************************************
00012 ** Ifdefs
00013 *****************************************************************************/
00014 
00015 #ifndef ECL_EXCEPTIONS_STANDARD_EXCEPTION_HPP_
00016 #define ECL_EXCEPTIONS_STANDARD_EXCEPTION_HPP_
00017 
00018 /*****************************************************************************
00019 ** Disable check
00020 *****************************************************************************/
00021 
00022 #include <ecl/config/ecl.hpp>
00023 #ifndef ECL_DISABLE_EXCEPTIONS
00024 
00025 /*****************************************************************************
00026 ** Includes
00027 *****************************************************************************/
00028 
00029 #include <string>
00030 #include "exception.hpp"
00031 #include <ecl/errors/handlers.hpp>
00032 #include <ecl/errors/macros.hpp>
00033 #include <cstring>
00034 
00035 /*****************************************************************************
00036 ** Namespaces
00037 *****************************************************************************/
00038 
00039 namespace ecl {
00040 
00041 /*****************************************************************************
00042 ** Interface [StandardException]
00043 *****************************************************************************/
00054 class ecl_exceptions_PUBLIC StandardException : public Exception
00055 {
00056     public:
00062         StandardException(const char* loc, ErrorFlag error );
00069         StandardException(const char* loc, ErrorFlag error, const std::string &msg );
00076         StandardException(const char* loc, const StandardException &e );
00077 
00078         virtual ~StandardException() throw() {}
00079 
00085         const char* what() const throw();
00086 
00087         const ErrorFlag& flag() const { return error_flag; }  
00089     private:
00090         const ErrorFlag error_flag;
00091         std::string message;
00092 };
00093 
00094 }; // namespace ecl
00095 
00096 #endif /* ECL_DISABLE_EXCEPTIONS */
00097 #endif /*ECL_EXCEPTIONS_STANDARD_EXCEPTION_HPP_*/


ecl_exceptions
Author(s): Daniel Stonier
autogenerated on Sun Oct 5 2014 23:35:18