@Plugin(name="ThreadContextMapFilter", category="Core", elementType="filter", printObject=true) public class ThreadContextMapFilter extends MapFilter
Filter.ResultLifeCycle.StateonMatch, onMismatchDEFAULT_STOP_TIMEOUT, DEFAULT_STOP_TIMEUNIT, LOGGERELEMENT_TYPE| Constructor and Description |
|---|
ThreadContextMapFilter(Map<String,List<String>> pairs,
boolean oper,
Filter.Result onMatch,
Filter.Result onMismatch) |
| Modifier and Type | Method and Description |
|---|---|
static ThreadContextMapFilter |
createFilter(KeyValuePair[] pairs,
String oper,
Filter.Result match,
Filter.Result mismatch) |
Filter.Result |
filter(LogEvent event)
Context Filter method.
|
Filter.Result |
filter(Logger logger,
Level level,
Marker marker,
Message msg,
Throwable t)
Appender Filter method.
|
Filter.Result |
filter(Logger logger,
Level level,
Marker marker,
Object msg,
Throwable t)
Appender Filter method.
|
Filter.Result |
filter(Logger logger,
Level level,
Marker marker,
String msg,
Object... params)
Appender Filter method.
|
filter, getMap, isAnd, toStringequalsImpl, getOnMatch, getOnMismatch, hashCodeImplgetState, isInitialized, isStarted, isStarting, isStopped, isStopping, setStarted, setStarting, setState, setStopped, setStopping, start, stoppublic ThreadContextMapFilter(Map<String,List<String>> pairs, boolean oper, Filter.Result onMatch, Filter.Result onMismatch)
public Filter.Result filter(Logger logger, Level level, Marker marker, String msg, Object... params)
AbstractFilterfilter in interface Filterfilter in class AbstractFilterlogger - the Logger.level - The logging Level.marker - The Marker, if any.msg - The message, if present.params - An array of parameters or null.public Filter.Result filter(Logger logger, Level level, Marker marker, Object msg, Throwable t)
AbstractFilterfilter in interface Filterfilter in class AbstractFilterlogger - the Logger.level - The logging Level.marker - The Marker, if any.msg - The message, if present.t - A throwable or null.public Filter.Result filter(Logger logger, Level level, Marker marker, Message msg, Throwable t)
AbstractFilterpublic Filter.Result filter(LogEvent event)
AbstractFilter@PluginFactory public static ThreadContextMapFilter createFilter(@PluginElement(value="Pairs") KeyValuePair[] pairs, @PluginAttribute(value="operator") String oper, @PluginAttribute(value="onMatch") Filter.Result match, @PluginAttribute(value="onMismatch") Filter.Result mismatch)
Copyright © 1999-2021 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.