LSSTApplications  17.0+124,17.0+14,17.0+73,18.0.0+37,18.0.0+80,18.0.0-4-g68ffd23+4,18.1.0-1-g0001055+12,18.1.0-1-g03d53ef+5,18.1.0-1-g1349e88+55,18.1.0-1-g2505f39+44,18.1.0-1-g5315e5e+4,18.1.0-1-g5e4b7ea+14,18.1.0-1-g7e8fceb+4,18.1.0-1-g85f8cd4+48,18.1.0-1-g8ff0b9f+4,18.1.0-1-ga2c679d+1,18.1.0-1-gd55f500+35,18.1.0-10-gb58edde+2,18.1.0-11-g0997b02+4,18.1.0-13-gfe4edf0b+12,18.1.0-14-g259bd21+21,18.1.0-19-gdb69f3f+2,18.1.0-2-g5f9922c+24,18.1.0-2-gd3b74e5+11,18.1.0-2-gfbf3545+32,18.1.0-26-g728bddb4+5,18.1.0-27-g6ff7ca9+2,18.1.0-3-g52aa583+25,18.1.0-3-g8ea57af+9,18.1.0-3-gb69f684+42,18.1.0-3-gfcaddf3+6,18.1.0-32-gd8786685a,18.1.0-4-gf3f9b77+6,18.1.0-5-g1dd662b+2,18.1.0-5-g6dbcb01+41,18.1.0-6-gae77429+3,18.1.0-7-g9d75d83+9,18.1.0-7-gae09a6d+30,18.1.0-9-gc381ef5+4,w.2019.45
LSSTDataManagementBasePackage
Classes | Namespaces | Macros | Functions
Log.h File Reference

LSST DM logging module built on log4cxx. More...

#include <functional>
#include <sstream>
#include <stdarg.h>
#include <string>
#include <log4cxx/logger.h>
#include <boost/format.hpp>

Go to the source code of this file.

Classes

class  lsst::log::Log
 This static class includes a variety of methods for interacting with the the logging module. More...
 
class  lsst::log::LogMDCScope
 

Namespaces

 lsst
 A base class for image defects.
 
 lsst::log
 

Macros

#define LOG_CONFIG(filename)   lsst::log::Log::configure(filename)
 Configures log4cxx and initializes logging module. More...
 
#define LOG_CONFIG_PROP(string)   lsst::log::Log::configure_prop(string)
 Configures log4cxx from a string containing list of properties. More...
 
#define LOG_GET(logger)   lsst::log::Log::getLogger(logger)
 Returns a Log object associated with logger. More...
 
#define LOG_GET_CHILD(logger, suffix)   lsst::log::Log::getLogger(logger).getChild(suffix)
 Returns a Log object associated with descendant of a logger. More...
 
#define LOG_MDC(key, value)   lsst::log::Log::MDC(key, value)
 Places a KEY/VALUE pair in the Mapped Diagnostic Context (MDC) for the current thread. More...
 
#define LOG_MDC_REMOVE(key)   lsst::log::Log::MDCRemove(key)
 Remove the value associated with KEY within the MDC. More...
 
#define LOG_CONCAT_IMPL(a, b)   a ## b
 
#define LOG_CONCAT_IMPL2(a, b)   LOG_CONCAT_IMPL(a, b)
 
#define LOG_MDC_SCOPE(key, value)   lsst::log::LogMDCScope LOG_CONCAT_IMPL2(_log_mdc_scope_, __COUNTER__)(key, value);
 Places a KEY/VALUE pair in the Mapped Diagnostic Context (MDC) for the current thread, and restores previous KEY/VALUE on exit from a scope. More...
 
#define LOG_MDC_INIT(func)   lsst::log::Log::MDCRegisterInit(std::function<void()>(func))
 Register function for initialization of MDC. More...
 
#define LOG_SET_LVL(logger, level)   lsst::log::Log::getLogger(logger).setLevel(level)
 Set the logging threshold for LOGGER to LEVEL. More...
 
#define LOG_GET_LVL(logger)   lsst::log::Log::getLogger(logger).getLevel()
 Retrieve the logging threshold for LOGGER. More...
 
#define LOG_CHECK_LVL(logger, level)   lsst::log::Log::getLogger(logger).isEnabledFor(level)
 Return whether the logging threshold of LOGGER is less than or equal to LEVEL. More...
 
#define LOG_CHECK_TRACE()   LOG4CXX_UNLIKELY(lsst::log::Log::getDefaultLogger().isTraceEnabled())
 Return whether the logging threshold of the default logger is less than or equal to TRACE. More...
 
#define LOG_CHECK_DEBUG()   LOG4CXX_UNLIKELY(lsst::log::Log::getDefaultLogger().isDebugEnabled())
 Return whether the logging threshold of the default logger is less than or equal to DEBUG. More...
 
#define LOG_CHECK_INFO()   lsst::log::Log::getDefaultLogger().isInfoEnabled()
 Return whether the logging threshold of the default logger is less than or equal to INFO. More...
 
#define LOG_CHECK_WARN()   lsst::log::Log::getDefaultLogger().isWarnEnabled()
 Return whether the logging threshold of the default logger is less than or equal to WARN. More...
 
#define LOG_CHECK_ERROR()   lsst::log::Log::getDefaultLogger().isErrorEnabled()
 Return whether the logging threshold of the default logger is less than or equal to ERROR. More...
 
#define LOG_CHECK_FATAL()   lsst::log::Log::getDefaultLogger().isFatalEnabled()
 Return whether the logging threshold of the default logger is less than or equal to FATAL. More...
 
#define LOG(logger, level, message...)
 Log a message using a varargs/printf style interface. More...
 
#define LOG_TRACE(message...)
 Log a trace-level message to the default logger using a varargs/printf style interface. More...
 
#define LOG_DEBUG(message...)
 Log a debug-level message to the default logger using a varargs/printf style interface. More...
 
#define LOG_INFO(message...)
 Log a info-level message to the default logger using a varargs/printf style interface. More...
 
#define LOG_WARN(message...)
 Log a warn-level message to the default logger using a varargs/printf style interface. More...
 
#define LOG_ERROR(message...)
 Log a error-level message to the default logger using a varargs/printf style interface. More...
 
#define LOG_FATAL(message...)
 Log a fatal-level message to the default logger using a varargs/printf style interface. More...
 
#define LOG_MESSAGE_VIA_STREAM_(logger, level, message)
 
#define LOGS(logger, level, message)
 Log a message using an iostream-based interface. More...
 
#define LOGS_TRACE(message)
 Log a trace-level message to the default logger using an iostream-based interface. More...
 
#define LOGS_DEBUG(message)
 Log a debug-level message to the default logger using an iostream-based interface. More...
 
#define LOGS_INFO(message)
 Log a info-level message to the default logger using an iostream-based interface. More...
 
#define LOGS_WARN(message)
 Log a warning-level message to the default logger using an iostream-based interface. More...
 
#define LOGS_ERROR(message)
 Log a error-level message to the default logger using an iostream-based interface. More...
 
#define LOGS_FATAL(message)
 Log a fatal-level message to the default logger using an iostream-based interface. More...
 
#define LOGL_TRACE(logger, message...)
 Log a trace-level message using a varargs/printf style interface. More...
 
#define LOGL_DEBUG(logger, message...)
 Log a debug-level message using a varargs/printf style interface. More...
 
#define LOGL_INFO(logger, message...)
 Log a info-level message using a varargs/printf style interface. More...
 
#define LOGL_WARN(logger, message...)
 Log a warn-level message using a varargs/printf style interface. More...
 
#define LOGL_ERROR(logger, message...)
 Log a error-level message using a varargs/printf style interface. More...
 
#define LOGL_FATAL(logger, message...)
 Log a fatal-level message using a varargs/printf style interface. More...
 
#define LOGLS_TRACE(logger, message)
 Log a trace-level message using an iostream-based interface. More...
 
#define LOGLS_DEBUG(logger, message)
 Log a debug-level message using an iostream-based interface. More...
 
#define LOGLS_INFO(logger, message)
 Log a info-level message using an iostream-based interface. More...
 
#define LOGLS_WARN(logger, message)
 Log a warn-level message using an iostream-based interface. More...
 
#define LOGLS_ERROR(logger, message)
 Log a error-level message using an iostream-based interface. More...
 
#define LOGLS_FATAL(logger, message)
 Log a fatal-level message using an iostream-based interface. More...
 
#define LOG_LVL_TRACE   static_cast<int>(log4cxx::Level::TRACE_INT)
 
#define LOG_LVL_DEBUG   static_cast<int>(log4cxx::Level::DEBUG_INT)
 
#define LOG_LVL_INFO   static_cast<int>(log4cxx::Level::INFO_INT)
 
#define LOG_LVL_WARN   static_cast<int>(log4cxx::Level::WARN_INT)
 
#define LOG_LVL_ERROR   static_cast<int>(log4cxx::Level::ERROR_INT)
 
#define LOG_LVL_FATAL   static_cast<int>(log4cxx::Level::FATAL_INT)
 
#define LOG_LOGGER   lsst::log::Log
 

Functions

unsigned lsst::log::lwpID ()
 Function which returns LWP ID on platforms which support it. More...
 

Detailed Description

LSST DM logging module built on log4cxx.

Author
Bill Chickering Contact: chick.nosp@m.erin.nosp@m.g@cs..nosp@m.stan.nosp@m.ford..nosp@m.edu

Definition in file Log.h.

Macro Definition Documentation

◆ LOG

#define LOG (   logger,
  level,
  message... 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isEnabledFor(level)) { \
log.log(log4cxx::Level::toLevel(level), LOG4CXX_LOCATION, message); } \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a message using a varargs/printf style interface.

Parameters
loggerEither a logger name or a Log object.
levelLogging level associated with message.
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 240 of file Log.h.

◆ LOG_CHECK_DEBUG

#define LOG_CHECK_DEBUG ( )    LOG4CXX_UNLIKELY(lsst::log::Log::getDefaultLogger().isDebugEnabled())

Return whether the logging threshold of the default logger is less than or equal to DEBUG.

Returns
Bool indicating whether or not logger is enabled.

Definition at line 192 of file Log.h.

◆ LOG_CHECK_ERROR

#define LOG_CHECK_ERROR ( )    lsst::log::Log::getDefaultLogger().isErrorEnabled()

Return whether the logging threshold of the default logger is less than or equal to ERROR.

Returns
Bool indicating whether or not logger is enabled.

Definition at line 219 of file Log.h.

◆ LOG_CHECK_FATAL

#define LOG_CHECK_FATAL ( )    lsst::log::Log::getDefaultLogger().isFatalEnabled()

Return whether the logging threshold of the default logger is less than or equal to FATAL.

Returns
Bool indicating whether or not logger is enabled.

Definition at line 228 of file Log.h.

◆ LOG_CHECK_INFO

#define LOG_CHECK_INFO ( )    lsst::log::Log::getDefaultLogger().isInfoEnabled()

Return whether the logging threshold of the default logger is less than or equal to INFO.

Returns
Bool indicating whether or not logger is enabled.

Definition at line 201 of file Log.h.

◆ LOG_CHECK_LVL

#define LOG_CHECK_LVL (   logger,
  level 
)    lsst::log::Log::getLogger(logger).isEnabledFor(level)

Return whether the logging threshold of LOGGER is less than or equal to LEVEL.

Returns
Bool indicating whether or not logger is enabled.
Parameters
loggerEither a logger name or a Log object being queried.
levelLogging threshold to check.

Definition at line 174 of file Log.h.

◆ LOG_CHECK_TRACE

#define LOG_CHECK_TRACE ( )    LOG4CXX_UNLIKELY(lsst::log::Log::getDefaultLogger().isTraceEnabled())

Return whether the logging threshold of the default logger is less than or equal to TRACE.

Returns
Bool indicating whether or not logger is enabled.

Definition at line 183 of file Log.h.

◆ LOG_CHECK_WARN

#define LOG_CHECK_WARN ( )    lsst::log::Log::getDefaultLogger().isWarnEnabled()

Return whether the logging threshold of the default logger is less than or equal to WARN.

Returns
Bool indicating whether or not logger is enabled.

Definition at line 210 of file Log.h.

◆ LOG_CONCAT_IMPL

#define LOG_CONCAT_IMPL (   a,
  b 
)    a ## b

Definition at line 118 of file Log.h.

◆ LOG_CONCAT_IMPL2

#define LOG_CONCAT_IMPL2 (   a,
  b 
)    LOG_CONCAT_IMPL(a, b)

Definition at line 119 of file Log.h.

◆ LOG_CONFIG

#define LOG_CONFIG (   filename)    lsst::log::Log::configure(filename)

Configures log4cxx and initializes logging module.

Parameters
filenamePath to configuration file.

Definition at line 52 of file Log.h.

◆ LOG_CONFIG_PROP

#define LOG_CONFIG_PROP (   string)    lsst::log::Log::configure_prop(string)

Configures log4cxx from a string containing list of properties.

This is equivalent to configuring with a file name containing the same data as a string.

Note
Use of this macro will likely produce hard-coded configuration which is not advised for general-use code. It may be useful where pre-defined hard-coded configuration is necessary, e.g. in unit tests.
Parameters
stringList of properties (lines separated by new line character)

Definition at line 66 of file Log.h.

◆ LOG_DEBUG

#define LOG_DEBUG (   message...)
Value:
do { \
lsst::log::Log log; \
if (LOG4CXX_UNLIKELY(log.isDebugEnabled())) { \
log.log(log4cxx::Level::getDebug(), LOG4CXX_LOCATION, message); } \
} while (false)

Log a debug-level message to the default logger using a varargs/printf style interface.

Parameters
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 270 of file Log.h.

◆ LOG_ERROR

#define LOG_ERROR (   message...)
Value:
do { \
lsst::log::Log log; \
if (log.isErrorEnabled()) { \
log.log(log4cxx::Level::getError(), LOG4CXX_LOCATION, message); } \
} while (false)

Log a error-level message to the default logger using a varargs/printf style interface.

Parameters
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 315 of file Log.h.

◆ LOG_FATAL

#define LOG_FATAL (   message...)
Value:
do { \
lsst::log::Log log; \
if (log.isFatalEnabled()) { \
log.log(log4cxx::Level::getFatal(), LOG4CXX_LOCATION, message); } \
} while (false)

Log a fatal-level message to the default logger using a varargs/printf style interface.

Parameters
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 330 of file Log.h.

◆ LOG_GET

#define LOG_GET (   logger)    lsst::log::Log::getLogger(logger)

Returns a Log object associated with logger.

Returns
Log object corresponding to logger.
Parameters
loggerEither a logger name or a Log object.

Definition at line 75 of file Log.h.

◆ LOG_GET_CHILD

#define LOG_GET_CHILD (   logger,
  suffix 
)    lsst::log::Log::getLogger(logger).getChild(suffix)

Returns a Log object associated with descendant of a logger.

Returns
Log object corresponding to logger's descendant.
Parameters
loggerEither a logger name or a Log object.
suffixSuffix of a descendant.

Definition at line 85 of file Log.h.

◆ LOG_GET_LVL

#define LOG_GET_LVL (   logger)    lsst::log::Log::getLogger(logger).getLevel()

Retrieve the logging threshold for LOGGER.

Returns
int Indicating the logging threshold.
Parameters
loggerEither a logger name or a Log object with threshold to return.

Definition at line 162 of file Log.h.

◆ LOG_INFO

#define LOG_INFO (   message...)
Value:
do { \
lsst::log::Log log; \
if (log.isInfoEnabled()) { \
log.log(log4cxx::Level::getInfo(), LOG4CXX_LOCATION, message); } \
} while (false)

Log a info-level message to the default logger using a varargs/printf style interface.

Parameters
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 285 of file Log.h.

◆ LOG_LOGGER

#define LOG_LOGGER   lsst::log::Log

Definition at line 703 of file Log.h.

◆ LOG_LVL_DEBUG

#define LOG_LVL_DEBUG   static_cast<int>(log4cxx::Level::DEBUG_INT)

Definition at line 697 of file Log.h.

◆ LOG_LVL_ERROR

#define LOG_LVL_ERROR   static_cast<int>(log4cxx::Level::ERROR_INT)

Definition at line 700 of file Log.h.

◆ LOG_LVL_FATAL

#define LOG_LVL_FATAL   static_cast<int>(log4cxx::Level::FATAL_INT)

Definition at line 701 of file Log.h.

◆ LOG_LVL_INFO

#define LOG_LVL_INFO   static_cast<int>(log4cxx::Level::INFO_INT)

Definition at line 698 of file Log.h.

◆ LOG_LVL_TRACE

#define LOG_LVL_TRACE   static_cast<int>(log4cxx::Level::TRACE_INT)

Definition at line 696 of file Log.h.

◆ LOG_LVL_WARN

#define LOG_LVL_WARN   static_cast<int>(log4cxx::Level::WARN_INT)

Definition at line 699 of file Log.h.

◆ LOG_MDC

#define LOG_MDC (   key,
  value 
)    lsst::log::Log::MDC(key, value)

Places a KEY/VALUE pair in the Mapped Diagnostic Context (MDC) for the current thread.

The VALUE may then be included in log messages by using the following the X conversion character within a pattern layout as X{KEY}.

Parameters
keyUnique key.
valueString value.

Definition at line 97 of file Log.h.

◆ LOG_MDC_INIT

#define LOG_MDC_INIT (   func)    lsst::log::Log::MDCRegisterInit(std::function<void()>(func))

Register function for initialization of MDC.

This function will be called for current thread and every new thread (but not for other existing threads) before any message is logged using one of the macros below. Its main purpose is to initialize MDC (using LOG_MDC macro). In some cases the function may be called more than once per thread.

This macro is thread safe, but typically it will be called from main thread before any other LOG macro.

Macro returns an integer number, the value is not specified, but this allows it to be used in one-time initialization constructs like:

static int dummyMdcInit = LOG_MDC_INIT(some_init_func);
Parameters
funcAny function object which takes no arguments and returns void.

Definition at line 142 of file Log.h.

◆ LOG_MDC_REMOVE

#define LOG_MDC_REMOVE (   key)    lsst::log::Log::MDCRemove(key)

Remove the value associated with KEY within the MDC.

Parameters
keyKey identifying value to remove.

Definition at line 105 of file Log.h.

◆ LOG_MDC_SCOPE

#define LOG_MDC_SCOPE (   key,
  value 
)    lsst::log::LogMDCScope LOG_CONCAT_IMPL2(_log_mdc_scope_, __COUNTER__)(key, value);

Places a KEY/VALUE pair in the Mapped Diagnostic Context (MDC) for the current thread, and restores previous KEY/VALUE on exit from a scope.

Parameters
keyUnique key.
valueString value.

Definition at line 120 of file Log.h.

◆ LOG_MESSAGE_VIA_STREAM_

#define LOG_MESSAGE_VIA_STREAM_ (   logger,
  level,
  message 
)
Value:
stream_ << message; \
logger.logMsg(level, LOG4CXX_LOCATION, stream_.str())
T str(T... args)

Definition at line 339 of file Log.h.

◆ LOG_SET_LVL

#define LOG_SET_LVL (   logger,
  level 
)    lsst::log::Log::getLogger(logger).setLevel(level)

Set the logging threshold for LOGGER to LEVEL.

Parameters
loggerLogger with threshold to adjust.
levelNew logging threshold.

Definition at line 151 of file Log.h.

◆ LOG_TRACE

#define LOG_TRACE (   message...)
Value:
do { \
lsst::log::Log log; \
if (LOG4CXX_UNLIKELY(log.isTraceEnabled())) { \
log.log(log4cxx::Level::getTrace(), LOG4CXX_LOCATION, message); } \
} while (false)

Log a trace-level message to the default logger using a varargs/printf style interface.

Parameters
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 255 of file Log.h.

◆ LOG_WARN

#define LOG_WARN (   message...)
Value:
do { \
lsst::log::Log log; \
if (log.isWarnEnabled()) { \
log.log(log4cxx::Level::getWarn(), LOG4CXX_LOCATION, message); } \
} while (false)

Log a warn-level message to the default logger using a varargs/printf style interface.

Parameters
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 300 of file Log.h.

◆ LOGL_DEBUG

#define LOGL_DEBUG (   logger,
  message... 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (LOG4CXX_UNLIKELY(log.isDebugEnabled())) { \
log.log(log4cxx::Level::getDebug(), LOG4CXX_LOCATION, message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a debug-level message using a varargs/printf style interface.

Parameters
loggerEither a logger name or a Log object.
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 504 of file Log.h.

◆ LOGL_ERROR

#define LOGL_ERROR (   logger,
  message... 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isErrorEnabled()) { \
log.log(log4cxx::Level::getError(), LOG4CXX_LOCATION, message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a error-level message using a varargs/printf style interface.

Parameters
loggerEither a logger name or a Log object.
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 552 of file Log.h.

◆ LOGL_FATAL

#define LOGL_FATAL (   logger,
  message... 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isFatalEnabled()) { \
log.log(log4cxx::Level::getFatal(), LOG4CXX_LOCATION, message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a fatal-level message using a varargs/printf style interface.

Parameters
loggerEither a logger name or a Log object.
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 568 of file Log.h.

◆ LOGL_INFO

#define LOGL_INFO (   logger,
  message... 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isInfoEnabled()) { \
log.log(log4cxx::Level::getInfo(), LOG4CXX_LOCATION, message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a info-level message using a varargs/printf style interface.

Parameters
loggerEither a logger name or a Log object.
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 520 of file Log.h.

◆ LOGL_TRACE

#define LOGL_TRACE (   logger,
  message... 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (LOG4CXX_UNLIKELY(log.isTraceEnabled())) { \
log.log(log4cxx::Level::getTrace(), LOG4CXX_LOCATION, message);\
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a trace-level message using a varargs/printf style interface.

Parameters
loggerEither a logger name or a Log object.
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 488 of file Log.h.

◆ LOGL_WARN

#define LOGL_WARN (   logger,
  message... 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isWarnEnabled()) { \
log.log(log4cxx::Level::getWarn(), LOG4CXX_LOCATION, message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a warn-level message using a varargs/printf style interface.

Parameters
loggerEither a logger name or a Log object.
messageAn sprintf-compatible format string followed by zero, one, or more comma-separated arguments.

Definition at line 536 of file Log.h.

◆ LOGLS_DEBUG

#define LOGLS_DEBUG (   logger,
  message 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (LOG4CXX_UNLIKELY(log.isDebugEnabled())) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getDebug(), message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a debug-level message using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGLS_DEBUG(logger, "coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
loggerEither a logger name or a Log object.
messageMessage to be logged.

Definition at line 608 of file Log.h.

◆ LOGLS_ERROR

#define LOGLS_ERROR (   logger,
  message 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isErrorEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getError(), message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a error-level message using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGLS_ERROR(logger, "coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
loggerEither a logger name or a Log object.
messageMessage to be logged.

Definition at line 668 of file Log.h.

◆ LOGLS_FATAL

#define LOGLS_FATAL (   logger,
  message 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isFatalEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getFatal(), message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a fatal-level message using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGLS_FATAL(logger, "coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
loggerEither a logger name or a Log object.
messageMessage to be logged.

Definition at line 688 of file Log.h.

◆ LOGLS_INFO

#define LOGLS_INFO (   logger,
  message 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isInfoEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getInfo(), message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a info-level message using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGLS_INFO(logger, "coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
loggerEither a logger name or a Log object.
messageMessage to be logged.

Definition at line 628 of file Log.h.

◆ LOGLS_TRACE

#define LOGLS_TRACE (   logger,
  message 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (LOG4CXX_UNLIKELY(log.isTraceEnabled())) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getTrace(), message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a trace-level message using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGLS_TRACE(logger, "coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
loggerEither a logger name or a Log object.
messageMessage to be logged.

Definition at line 588 of file Log.h.

◆ LOGLS_WARN

#define LOGLS_WARN (   logger,
  message 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isWarnEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getWarn(), message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a warn-level message using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGLS_WARN(logger, "coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
loggerEither a logger name or a Log object.
messageMessage to be logged.

Definition at line 648 of file Log.h.

◆ LOGS

#define LOGS (   logger,
  level,
  message 
)
Value:
do { \
lsst::log::Log log(lsst::log::Log::getLogger(logger)); \
if (log.isEnabledFor(level)) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::toLevel(level), message); \
} \
} while (false)
static Log getLogger(Log const &logger)
Definition: Log.h:760

Log a message using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGS("logger", LOG_LVL_DEBUG, "coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
loggerEither a logger name or a Log object.
levelLogging level associated with message.
messageMessage to be logged.

Definition at line 358 of file Log.h.

◆ LOGS_DEBUG

#define LOGS_DEBUG (   message)
Value:
do { \
lsst::log::Log log; \
if (LOG4CXX_UNLIKELY(log.isDebugEnabled())) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getDebug(), message); \
} \
} while (false)

Log a debug-level message to the default logger using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGS_DEBUG("coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
messageMessage to be logged.

Definition at line 396 of file Log.h.

◆ LOGS_ERROR

#define LOGS_ERROR (   message)
Value:
do { \
lsst::log::Log log; \
if (log.isErrorEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getError(), message); \
} \
} while (false)

Log a error-level message to the default logger using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGS_ERROR("coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
messageMessage to be logged.

Definition at line 453 of file Log.h.

◆ LOGS_FATAL

#define LOGS_FATAL (   message)
Value:
do { \
lsst::log::Log log; \
if (log.isFatalEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getFatal(), message); \
} \
} while (false)

Log a fatal-level message to the default logger using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGS_FATAL("coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
messageMessage to be logged.

Definition at line 472 of file Log.h.

◆ LOGS_INFO

#define LOGS_INFO (   message)
Value:
do { \
lsst::log::Log log; \
if (log.isInfoEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getInfo(), message); \
} \
} while (false)

Log a info-level message to the default logger using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGS_INFO("coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
messageMessage to be logged.

Definition at line 415 of file Log.h.

◆ LOGS_TRACE

#define LOGS_TRACE (   message)
Value:
do { \
lsst::log::Log log; \
if (LOG4CXX_UNLIKELY(log.isTraceEnabled())) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getTrace(), message); \
} \
} while (false)

Log a trace-level message to the default logger using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGS_TRACE("coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
messageMessage to be logged.

Definition at line 377 of file Log.h.

◆ LOGS_WARN

#define LOGS_WARN (   message)
Value:
do { \
lsst::log::Log log; \
if (log.isWarnEnabled()) { \
LOG_MESSAGE_VIA_STREAM_(log, log4cxx::Level::getWarn(), message); \
} \
} while (false)

Log a warning-level message to the default logger using an iostream-based interface.

Message is any expression which can appear on the right side of the stream insertion operator, e.g. LOGS_WARN("coordinates: x=" << x << " y=" << y);. Usual caveat regarding commas inside macro arguments applies to message argument.

Parameters
messageMessage to be logged.

Definition at line 434 of file Log.h.