Apache Log4cxx
Version 1.2.0
|
A smart pointer (implicity convertable to LoggerPtr) that conditionally removes a Logger from the spi::LoggerRepository at the end of the instance variable's lifetime. More...
#include <loggerinstance.h>
Public Member Functions | |
LoggerInstancePtr () | |
A null LoggerPtr. | |
template<class StringType > | |
LoggerInstancePtr (const StringType &instanceName) | |
A separately configurable logger named instanceName . | |
~LoggerInstancePtr () | |
Conditionally remove the logger from the the spi::LoggerRepository. | |
const LoggerPtr & | operator-> () const noexcept |
operator bool () const noexcept | |
operator LoggerPtr & () noexcept | |
operator const LoggerPtr & () const noexcept | |
Logger * | get () noexcept |
const Logger * | get () const noexcept |
void | reset () |
Conditionally remove the Logger from the spi::LoggerRepository. | |
template<class StringType > | |
void | reset (const StringType &instanceName) |
Change this to a logger named instanceName . | |
A smart pointer (implicity convertable to LoggerPtr) that conditionally removes a Logger from the spi::LoggerRepository at the end of the instance variable's lifetime.
If the configuration process loaded settings for the logger, or the logger is referenced elsewhere, the LoggerInstancePtr destructor will not remove it from the spi::LoggerRepository.
Use a LoggerInstancePtr to prevent unbounded growth of data in the spi::LoggerRepository when using runtime generated logger names.
A runtime generated logger name is a technique for marking logging messages that allows control of the logger level at a class instance level (i.e. a per object logger).
A per object logger is useful when the object instance has a identifiable name (e.g. when it is instantiated from configuration data).
|
inline |
A null LoggerPtr.
|
inline |
A separately configurable logger named instanceName
.
|
inline |
Conditionally remove the logger from the the spi::LoggerRepository.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlineexplicitnoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
Conditionally remove the Logger from the spi::LoggerRepository.
|
inline |
Change this to a logger named instanceName
.