CAPD::DynSys Library  6.0.0
Logger.h File Reference
#include <sstream>
#include <iostream>
#include <iterator>
#include <vector>
#include <set>
#include <algorithm>
#include <utility>

Classes

class  capd::auxil::Logger
 
struct  CAPD_LOGGER
 

Namespaces

 capd
 
 capd::auxil
 
 std
 
 std::impl
 

Macros

#define FILE_BUILD_DIR   ""
 
#define INIT_CAPD_LOGGER   __attribute__((unused)) const void* CAPD_LOGGER_INITIALIZED = capd::auxil::Logger::init();
 
#define CAPD_CLASS_LOGGER
 
#define CAPD_UNLIKELY(expr)   expr
 
#define __CAPD_FUNC__   ""
 
#define CAPD_LOCATION   __FILE__, __CAPD_FUNC__, __LINE__
 
#define CAPD_DEBUG(message)
 
#define CAPD_TRACE(message)
 
#define CAPD_INFO(message)
 
#define CAPD_WARN(message)
 
#define CAPD_ERROR(message)
 
#define CAPD_FATAL(message)
 
#define CAPD_DEBUG_TMPL(message)    CAPD_DEBUG(message)
 
#define CAPD_TRACE_TMPL(message)    CAPD_TRACE(message)
 
#define CAPD_INFO_TMPL(message)    CAPD_INFO(message)
 
#define CAPD_WARN_TMPL(message)    CAPD_WARN(message)
 
#define CAPD_ERROR_TMPL(message)    CAPD_ERROR(message)
 
#define CAPD_FATAL_TMPL(message)    CAPD_FATAL(message)
 

Functions

template<typename T >
std::ostream & std::operator<< (std::ostream &out, const std::vector< T > &vec)
 
template<typename T >
std::ostream & std::operator<< (std::ostream &out, const std::set< T > &vec)
 
template<typename F , typename S >
std::ostream & std::operator<< (std::ostream &s, const std::pair< F, S > &p)
 
template<typename It >
std::ostream & std::impl::printRng (std::ostream &out, It begin, It end)
 

Detailed Description

Macro Definition Documentation

◆ __CAPD_FUNC__

#define __CAPD_FUNC__   ""

◆ CAPD_CLASS_LOGGER

#define CAPD_CLASS_LOGGER
Value:
struct CAPD_LOGGER {\
static inline return_type getCAPDLogger(const char* file, const char* buildDir) { static capd::auxil::Logger logger(file, buildDir, false); return logger; } \
};
Definition: Logger.h:34
Definition: Logger.h:151
capd::auxil::Logger return_type
Definition: Logger.h:152
static return_type getCAPDLogger(const char *file, const char *buildDir)
Definition: Logger.cpp:371

◆ CAPD_DEBUG

#define CAPD_DEBUG (   message)
Value:
{ \
if (CAPD_UNLIKELY(logger.isDebugEnabled())) {\
std::stringstream oss_; \
/*using log4cxx::helpers::operator<<;*/ oss_ << message; \
logger.forcedLogDebug(oss_.str(), CAPD_LOCATION); }}
#define CAPD_LOCATION
Definition: Logger.h:180
#define CAPD_UNLIKELY(expr)
Definition: Logger.h:163
#define FILE_BUILD_DIR
Definition: Logger.h:137

◆ CAPD_DEBUG_TMPL

#define CAPD_DEBUG_TMPL (   message)     CAPD_DEBUG(message)

◆ CAPD_ERROR

#define CAPD_ERROR (   message)
Value:
{ \
if (logger.isErrorEnabled()) {\
std::stringstream oss_; \
/*using log4cxx::helpers::operator<<;*/ oss_ << message; \
logger.forcedLogError(oss_.str(), CAPD_LOCATION); }}

◆ CAPD_ERROR_TMPL

#define CAPD_ERROR_TMPL (   message)     CAPD_ERROR(message)

◆ CAPD_FATAL

#define CAPD_FATAL (   message)
Value:
{ \
if (logger.isFatalEnabled()) {\
std::stringstream oss_; \
/*using log4cxx::helpers::operator<<;*/ oss_ << message; \
logger.forcedLogFatal(oss_.str(), CAPD_LOCATION); }}

◆ CAPD_FATAL_TMPL

#define CAPD_FATAL_TMPL (   message)     CAPD_FATAL(message)

◆ CAPD_INFO

#define CAPD_INFO (   message)
Value:
{ \
if (logger.isInfoEnabled()) {\
std::stringstream oss_; \
/*using log4cxx::helpers::operator<<;*/ oss_ << message; \
logger.forcedLogInfo(oss_.str(), CAPD_LOCATION); }}

◆ CAPD_INFO_TMPL

#define CAPD_INFO_TMPL (   message)     CAPD_INFO(message)

◆ CAPD_LOCATION

#define CAPD_LOCATION   __FILE__, __CAPD_FUNC__, __LINE__

◆ CAPD_TRACE

#define CAPD_TRACE (   message)
Value:
{ \
if (CAPD_UNLIKELY(logger.isTraceEnabled())) {\
std::stringstream oss_; \
/*using log4cxx::helpers::operator<<;*/ oss_ << message; \
logger.forcedLogTrace(oss_.str(), CAPD_LOCATION); }}

◆ CAPD_TRACE_TMPL

#define CAPD_TRACE_TMPL (   message)     CAPD_TRACE(message)

◆ CAPD_UNLIKELY

#define CAPD_UNLIKELY (   expr)    expr

◆ CAPD_WARN

#define CAPD_WARN (   message)
Value:
{ \
if (logger.isWarnEnabled()) {\
std::stringstream oss_; \
/*using log4cxx::helpers::operator<<;*/ oss_ << message; \
logger.forcedLogWarn(oss_.str(), CAPD_LOCATION); }}

◆ CAPD_WARN_TMPL

#define CAPD_WARN_TMPL (   message)     CAPD_WARN(message)

◆ FILE_BUILD_DIR

#define FILE_BUILD_DIR   ""

◆ INIT_CAPD_LOGGER

#define INIT_CAPD_LOGGER   __attribute__((unused)) const void* CAPD_LOGGER_INITIALIZED = capd::auxil::Logger::init();