GeoDesk for C++
Fast and storage-efficient spatial database engine for OpenStreetMap features
Loading...
Searching...
No Matches
exception.h File Reference

Go to the source code of this file.

Namespaces

namespace  clarisma
 

Macros

#define DECLARE_EXCEPTION(EXCEPTION_NAME)
 
#define DECLARE_EXCEPTION_WITH_BASE(EXCEPTION_NAME, BASE_CLASS)
 

Macro Definition Documentation

◆ DECLARE_EXCEPTION

#define DECLARE_EXCEPTION ( EXCEPTION_NAME)
Value:
class EXCEPTION_NAME : public std::runtime_error \
{ \
public: \
explicit EXCEPTION_NAME(const char* message) \
: std::runtime_error(message) {} \
explicit EXCEPTION_NAME(const std::string& message) \
: std::runtime_error(message) {} \
template <typename... Args> \
explicit EXCEPTION_NAME(const char* message, Args... args) \
: std::runtime_error(Format::format(message, args...)) {} \
};

◆ DECLARE_EXCEPTION_WITH_BASE

#define DECLARE_EXCEPTION_WITH_BASE ( EXCEPTION_NAME,
BASE_CLASS )
Value:
class EXCEPTION_NAME : public BASE_CLASS \
{ \
public: \
explicit EXCEPTION_NAME(const char* message) \
: BASE_CLASS(message) {} \
explicit EXCEPTION_NAME(const std::string& message) \
: BASE_CLASS(message) {} \
template <typename... Args> \
explicit EXCEPTION_NAME(const char* message, Args... args) \
: BASE_CLASS(Format::format(message, args...)) {} \
};