OpenTREP Logo  0.6.0
C++ Open Travel Request Parsing Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Logger.hpp File Reference
#include <assert.h>
#include <sstream>
#include <string>
#include <opentrep/OPENTREP_Types.hpp>

Go to the source code of this file.

Classes

class  OPENTREP::Logger
 

Namespaces

 OPENTREP
 

Macros

#define OPENTREP_LOG_CORE(iLevel, iToBeLogged)
 
#define OPENTREP_LOG_CRITICAL(iToBeLogged)   OPENTREP_LOG_CORE (OPENTREP::LOG::CRITICAL, iToBeLogged)
 
#define OPENTREP_LOG_ERROR(iToBeLogged)   OPENTREP_LOG_CORE (OPENTREP::LOG::ERROR, iToBeLogged)
 
#define OPENTREP_LOG_NOTIFICATION(iToBeLogged)   OPENTREP_LOG_CORE (OPENTREP::LOG::NOTIFICATION, iToBeLogged)
 
#define OPENTREP_LOG_WARNING(iToBeLogged)   OPENTREP_LOG_CORE (OPENTREP::LOG::WARNING, iToBeLogged)
 
#define OPENTREP_LOG_DEBUG(iToBeLogged)   OPENTREP_LOG_CORE (OPENTREP::LOG::DEBUG, iToBeLogged)
 
#define OPENTREP_LOG_VERBOSE(iToBeLogged)   OPENTREP_LOG_CORE (OPENTREP::LOG::VERBOSE, iToBeLogged)
 

Macro Definition Documentation

#define OPENTREP_LOG_CORE (   iLevel,
  iToBeLogged 
)
Value:
{ std::ostringstream ostr; ostr << iToBeLogged; \
OPENTREP::Logger::instance().log (iLevel, __LINE__, __FILE__, ostr.str()); }
void log(const LOG::EN_LogLevel iLevel, const int iLineNumber, const std::string &iFileName, const T &iToBeLogged)
Definition: Logger.hpp:52
static Logger & instance()
Definition: Logger.cpp:55

Definition at line 16 of file Logger.hpp.

#define OPENTREP_LOG_CRITICAL (   iToBeLogged)    OPENTREP_LOG_CORE (OPENTREP::LOG::CRITICAL, iToBeLogged)

Definition at line 20 of file Logger.hpp.

#define OPENTREP_LOG_WARNING (   iToBeLogged)    OPENTREP_LOG_CORE (OPENTREP::LOG::WARNING, iToBeLogged)

Definition at line 29 of file Logger.hpp.

#define OPENTREP_LOG_VERBOSE (   iToBeLogged)    OPENTREP_LOG_CORE (OPENTREP::LOG::VERBOSE, iToBeLogged)

Definition at line 35 of file Logger.hpp.