36#ifndef HPP_UTIL_EXCEPTION_HH
37#define HPP_UTIL_EXCEPTION_HH
50 unsigned line)
throw();
55 virtual const char* what()
const throw();
61 virtual std::ostream& print(std::ostream&
o)
const throw();
80#define HPP_THROW_EXCEPTION_(MSG) \
81 throw ::hpp::Exception(MSG, __FILE__, __LINE__)
84#define HPP_THROW_EXCEPTION(TYPE, MSG) throw TYPE(MSG, __FILE__, __LINE__)
87#define HPP_MAKE_EXCEPTION(EXTRA_QUALIFIER, TYPE) \
88 class EXTRA_QUALIFIER TYPE : public ::hpp::Exception { \
90 TYPE(const std::string& message, const std::string& file, unsigned line) \
91 throw() : ::hpp::Exception(message, file, line) {} \
95#define HPP_MAKE_EXCEPTION_NO_QUALIFIER(TYPE) \
96 class TYPE : public ::hpp::Exception { \
98 TYPE(const std::string& message, const std::string& file, unsigned line) \
99 throw() : ::hpp::Exception(message, file, line) {} \
Main exception class for HPP.
Definition exception.hh:47
#define HPP_UTIL_DLLAPI
Definition config.hh:88
Definition assertion.hh:45
HPP_UTIL_DLLAPI std::ostream & operator<<(std::ostream &o, const Exception &exception)
Override operator<< to handle exception display.
Definition exception.cc:79
Class to ease exception creation.
Definition exception-factory.hh:73