Virtru SDK for C++  2.8.0
Virtru C++ SDK library - Create, Read, and Manage TDF3 Files
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
tdf_exception.h File Reference
#include <stdexcept>
#include <string>
#include <sstream>
#include <map>
#include "tdf_error_codes.h"
#include "logger.h"

Go to the source code of this file.

Classes

class  virtru::Exception
 

Namespaces

 virtru
 

Macros

#define EXPAND(x)   x
 
#define GET_MACRO(_1, _2, NAME,...)   NAME
 
#define ThrowException(...)   EXPAND(EXPAND(GET_MACRO(__VA_ARGS__, ThrowExceptionCode, ThrowExceptionNoCode))(__VA_ARGS__))
 
#define ThrowExceptionNoCode(message)   virtru::_ThrowVirtruException(message, __SOURCE_FILENAME__, __LINE__)
 
#define ThrowExceptionCode(message, code)   virtru::_ThrowVirtruException(message, __SOURCE_FILENAME__, __LINE__, code)
 

Functions

void virtru::_ThrowVirtruException (std::string &&errorStringPrefix, const char *fileName, unsigned int lineNumber, int code=VIRTRU_GENERAL_ERROR)
 

Macro Definition Documentation

#define EXPAND (   x)    x

macro for exception

#define GET_MACRO (   _1,
  _2,
  NAME,
  ... 
)    NAME
#define ThrowException (   ...)    EXPAND(EXPAND(GET_MACRO(__VA_ARGS__, ThrowExceptionCode, ThrowExceptionNoCode))(__VA_ARGS__))
#define ThrowExceptionCode (   message,
  code 
)    virtru::_ThrowVirtruException(message, __SOURCE_FILENAME__, __LINE__, code)
#define ThrowExceptionNoCode (   message)    virtru::_ThrowVirtruException(message, __SOURCE_FILENAME__, __LINE__)