@Plugin(name="CountingNoOp", category="Core", elementType="appender", printObject=true) public class CountingNoOpAppender extends AbstractAppender
AbstractAppender.Builder<B extends AbstractAppender.Builder<B>>LifeCycle.StateDEFAULT_STOP_TIMEOUT, DEFAULT_STOP_TIMEUNIT, LOGGERELEMENT_TYPE| Constructor and Description |
|---|
CountingNoOpAppender(String name,
Layout<?> layout) |
| Modifier and Type | Method and Description |
|---|---|
void |
append(LogEvent event)
Logs a LogEvent using whatever logic this Appender wishes to use.
|
static CountingNoOpAppender |
createAppender(String name)
Creates a CountingNoOp Appender.
|
long |
getCount() |
error, error, error, getHandler, getLayout, getName, ignoreExceptions, parseInt, requiresLocation, setHandler, toSerializable, toStringaddFilter, getFilter, getPropertyArray, hasFilter, isFiltered, removeFilter, start, stop, stopequalsImpl, getState, getStatusLogger, hashCodeImpl, initialize, isInitialized, isStarted, isStarting, isStopped, isStopping, setStarted, setStarting, setState, setStopped, setStopping, stop, stoppublic CountingNoOpAppender(String name, Layout<?> layout)
public long getCount()
public void append(LogEvent event)
Appenderevent - The LogEvent.@PluginFactory public static CountingNoOpAppender createAppender(@PluginAttribute(value="name") String name)
Copyright © 1999-2021 The 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.