java.lang.Object | ||
↳ | org.apache.log4j.spi.Filter | |
↳ | org.apache.log4j.varia.LevelRangeFilter |
This is a very simple filter based on level matching, which can be used to reject messages with priorities outside a certain range.
The filter admits three options LevelMin, LevelMax and AcceptOnMatch.
If the level of the LoggingEvent
is not between Min and Max
(inclusive), then DENY
is returned.
If the Logging event level is within the specified range, then if
AcceptOnMatch is true, ACCEPT
is returned, and if
AcceptOnMatch is false, NEUTRAL
is returned.
If LevelMin
w is not defined, then there is no
minimum acceptable level (ie a level is never rejected for
being too "low"/unimportant). If LevelMax
is not
defined, then there is no maximum acceptable level (ie a
level is never rejected for beeing too "high"/important).
Refer to the setThreshold
method
available to all
appenders extending AppenderSkeleton
for a more convenient way to
filter out events by level.
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.apache.log4j.spi.Filter
|
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.apache.log4j.spi.Filter
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Return the decision of this filter.
| |||||||||||
Get the value of the
AcceptOnMatch option. | |||||||||||
Get the value of the
LevelMax option. | |||||||||||
Get the value of the
LevelMin option. | |||||||||||
Set the
AcceptOnMatch option. | |||||||||||
Set the
LevelMax option. | |||||||||||
Set the
LevelMin option. |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
org.apache.log4j.spi.Filter
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
org.apache.log4j.spi.OptionHandler
|
Return the decision of this filter.
event | The LoggingEvent to decide upon. |
---|
Get the value of the AcceptOnMatch
option.
Set the AcceptOnMatch
option.