log4cplus_spi_LogLevelRangeFilter(3)

log4cplus::spi::LogLevelRangeFilter(3) log4cplus log4cplus::spi::LogLevelRangeFilter(3)

NAME

log4cplus::spi::LogLevelRangeFilter - This is a very simple filter based on LogLevel matching, which can be used to reject messages with LogLevels outside a certain range.

SYNOPSIS

#include <filter.h>

Inherits log4cplus::spi::Filter.

Public Member Functions


LogLevelRangeFilter ()
LogLevelRangeFilter (const log4cplus::helpers::Properties &p)
virtual FilterResult decide (const InternalLoggingEvent &event) const
Return the decision of this filter.

Public Member Functions inherited from log4cplus::spi::Filter
Filter ()
virtual ~Filter ()
void appendFilter (FilterPtr filter)
Appends filter to the end of this filter chain.

Public Member Functions inherited from log4cplus::helpers::SharedObject
void addReference () const LOG4CPLUS_NOEXCEPT
void removeReference () const

Additional Inherited Members

Public Attributes inherited from log4cplus::spi::Filter
FilterPtr next
Points to the next filter in the filter chain.

Public Attributes inherited from log4cplus::helpers::SharedObject
thread::Mutex access_mutex

Protected Member Functions inherited from log4cplus::helpers::SharedObject
SharedObject ()
SharedObject (const SharedObject &)
SharedObject (SharedObject &&)
virtual ~SharedObject ()
SharedObject & operator= (const SharedObject &) LOG4CPLUS_NOEXCEPT
SharedObject & operator= (SharedObject &&) LOG4CPLUS_NOEXCEPT

Detailed Description

This is a very simple filter based on LogLevel matching, which can be used to reject messages with LogLevels outside a certain range.

The filter admits three options LogLevelMin, LogLevelMax and AcceptOnMatch.

If the LogLevel of the Logging event is not between Min and Max (inclusive), then DENY is returned.

If the Logging event LogLevel is within the specified range, then if AcceptOnMatch is true, ACCEPT is returned, and if AcceptOnMatch is false, NEUTRAL is returned.

If LogLevelMin is not defined, then there is no minimum acceptable LogLevel (ie a LogLevel is never rejected for being too 'low'/unimportant). If LogLevelMax is not defined, then there is no maximum acceptable LogLevel (ie a LogLevel is never rejected for beeing too 'high'/important).

Refer to the setThreshold method available to all appenders for a more convenient way to filter out events by LogLevel.

Definition at line 228 of file filter.h.

Constructor & Destructor Documentation

log4cplus::spi::LogLevelRangeFilter::LogLevelRangeFilter ()

log4cplus::spi::LogLevelRangeFilter::LogLevelRangeFilter (const log4cplus::helpers::Properties & p)

Member Function Documentation

virtual FilterResult log4cplus::spi::LogLevelRangeFilter::decide (const InternalLoggingEvent & event) const [virtual]

Return the decision of this filter.

Implements log4cplus::spi::Filter.

Author

Generated automatically by Doxygen for log4cplus from the source code.

Mon Jun 5 2023 21:46:10 Version 2.0.7