26#ifndef ELEMENTSKERNEL_ELEMENTSKERNEL_LOGGING_H_
27#define ELEMENTSKERNEL_ELEMENTSKERNEL_LOGGING_H_
33#include <log4cpp/Category.hh>
137 static void setLogFile(
const Path::Item& fileName);
144 m_log4cppLogger.debug(logMessage);
152 template <
typename... Args>
153 void debug(
const char* stringFormat, Args&&... args) {
154 m_log4cppLogger.debug(stringFormat, std::forward<Args>(args)...);
171 m_log4cppLogger.info(logMessage);
179 template <
typename... Args>
180 void info(
const char* stringFormat, Args&&... args) {
181 m_log4cppLogger.info(stringFormat, std::forward<Args>(args)...);
198 m_log4cppLogger.warn(logMessage);
206 template <
typename... Args>
207 void warn(
const char* stringFormat, Args&&... args) {
208 m_log4cppLogger.warn(stringFormat, std::forward<Args>(args)...);
225 m_log4cppLogger.error(logMessage);
233 template <
typename... Args>
234 void error(
const char* stringFormat, Args&&... args) {
235 m_log4cppLogger.error(stringFormat, std::forward<Args>(args)...);
252 m_log4cppLogger.fatal(logMessage);
260 template <
typename... Args>
261 void fatal(
const char* stringFormat, Args&&... args) {
262 m_log4cppLogger.fatal(stringFormat, std::forward<Args>(args)...);
280 m_log4cppLogger.log(level, logMessage);
289 template <
typename... Args>
290 void log(log4cpp::Priority::Value level,
const char* stringFormat, Args&&... args) {
291 m_log4cppLogger.log(level, stringFormat, std::forward<Args>(args)...);
295 explicit Logging(log4cpp::Category& log4cppLogger);
320 template <
typename T>
defines the macros to be used for explicit export of the symbols
provide functions to retrieve resources pointed by environment variables
A helper class for logging messages using the "<<" operator.
LogMessageStream(log4cpp::Category &logger, P_log_func log_func)
LogMessageStream & operator<<(const T &m)
void(log4cpp::Category::*)(const std::string &) P_log_func
log4cpp::Category & m_logger
Logging API of the Elements framework.
void error(const std::string &logMessage)
void debug(const std::string &logMessage)
void log(log4cpp::Priority::Value level, const char *stringFormat, Args &&... args)
void warn(const std::string &logMessage)
log4cpp::Category & m_log4cppLogger
void log(log4cpp::Priority::Value level, const std::string &logMessage)
void fatal(const char *stringFormat, Args &&... args)
void warn(const char *stringFormat, Args &&... args)
void debug(const char *stringFormat, Args &&... args)
void fatal(const std::string &logMessage)
void error(const char *stringFormat, Args &&... args)
void info(const std::string &logMessage)
void info(const char *stringFormat, Args &&... args)
#define ELEMENTS_API
Dummy definitions for the backward compatibility mode.