Package | Description |
---|---|
org.apache.logging.log4j |
Public API for Log4j 2.
|
org.apache.logging.log4j.core.config |
Configuration of Log4j 2.
|
org.apache.logging.log4j.core.filter |
Log4j 2 Filter support.
|
org.apache.logging.log4j.core.pattern |
Provides classes implementing format specifiers in conversion patterns.
|
org.apache.logging.log4j.core.time | |
org.apache.logging.log4j.message |
Public Message Types used for Log4j 2.
|
org.apache.logging.log4j.util |
Internal utility classes for the Log4j 2 API.
|
Modifier and Type | Method and Description |
---|---|
boolean |
MarkerManager.Log4jMarker.isInstanceOf(Marker marker) |
boolean |
MarkerManager.Log4jMarker.isInstanceOf(String markerName) |
Modifier and Type | Class and Description |
---|---|
class |
AppenderControlArraySet
Data structure with similar semantics to CopyOnWriteArraySet, but giving direct access to the underlying array.
|
Modifier and Type | Method and Description |
---|---|
protected void |
LoggerConfig.callAppenders(LogEvent event) |
void |
LoggerConfig.log(String loggerName,
String fqcn,
Marker marker,
Level level,
Message data,
Throwable t)
Logs an event.
|
void |
LoggerConfig.log(String loggerName,
String fqcn,
StackTraceElement location,
Marker marker,
Level level,
Message data,
Throwable t)
Logs an event.
|
Modifier and Type | Class and Description |
---|---|
class |
CompositeFilter
Composes and invokes one or more filters.
|
class |
DenyAllFilter
This filter causes all logging events to be dropped.
|
class |
DynamicThresholdFilter
Compares against a log level that is associated with a context value.
|
class |
LevelMatchFilter
This filter returns the onMatch result if the logging level in the event matches the specified logging level
exactly.
|
class |
LevelRangeFilter
This filter returns the
onMatch result if the level in the LogEvent is in the range of the configured
min and max levels, otherwise it returns onMismatch value . |
class |
MapFilter
A Filter that operates on a Map.
|
class |
MarkerFilter
This filter returns the onMatch result if the marker in the LogEvent is the same as or has the
configured marker as a parent.
|
class |
NoMarkerFilter
This filter returns the onMatch result if there is no marker in the LogEvent.
|
class |
StringMatchFilter
This filter returns the onMatch result if the logging level in the event matches the specified logging level
exactly.
|
class |
StructuredDataFilter
Filter based on data in a StructuredDataMessage.
|
class |
ThreadContextMapFilter
Filter based on a value in the Thread Context Map (MDC).
|
class |
ThresholdFilter
This filter returns the onMatch result if the level in the LogEvent is the same or more specific
than the configured level and the onMismatch value otherwise.
|
class |
TimeFilter
Filters events that fall within a specified time period in each day.
|
Modifier and Type | Class and Description |
---|---|
class |
DatePatternConverter
Converts and formats the event's date in a StringBuilder.
|
class |
EncodingPatternConverter
Converter that encodes the output from a pattern using a specified format.
|
class |
EndOfBatchPatternConverter
Formats the EndOfBatch.
|
class |
EqualsBaseReplacementConverter
Equals pattern converter.
|
class |
EqualsIgnoreCaseReplacementConverter
Equals ignore case pattern converter.
|
class |
EqualsReplacementConverter
Equals pattern converter.
|
class |
FileDatePatternConverter
Formats a date by delegating to
DatePatternConverter . |
class |
FormattingInfo
Modifies the output of a pattern converter for a specified minimum and maximum width and alignment.
|
class |
HighlightConverter
Highlight pattern converter.
|
class |
IntegerPatternConverter
Formats an integer.
|
class |
LevelPatternConverter
Returns the event's level in a StringBuilder.
|
class |
LineSeparatorPatternConverter
Formats a line separator.
|
class |
LiteralPatternConverter
Formats a string literal.
|
class |
LoggerFqcnPatternConverter
Formats the Logger FQCN.
|
class |
LoggerPatternConverter
Formats a logger name.
|
class |
MarkerPatternConverter
Returns events' full marker string in a StringBuilder.
|
class |
MarkerSimpleNamePatternConverter
Appends an event's maker name to a StringBuilder.
|
class |
MaxLengthConverter
Max length pattern converter.
|
class |
MdcPatternConverter
Able to handle the contents of the LogEvent's MDC and either
output the entire contents of the properties in a similar format to the
java.util.Hashtable.toString(), or to output the value of a specific key
within the property bundle
when this pattern converter has the option set.
|
class |
MessagePatternConverter
Returns the event's rendered message in a StringBuilder.
|
class |
NameAbbreviator
NameAbbreviator generates abbreviated logger and class names.
|
class |
NamePatternConverter
Abstract base class for other pattern converters which can return only parts of their name.
|
class |
NanoTimePatternConverter
Converts and formats the event's nanoTime in a StringBuilder.
|
class |
RelativeTimePatternConverter
Returns the relative time in milliseconds since JVM Startup.
|
class |
RepeatPatternConverter
Equals pattern converter.
|
class |
SequenceNumberPatternConverter
Formats the event sequence number.
|
class |
StyleConverter
Style pattern converter.
|
class |
ThreadIdPatternConverter
Formats the event thread ID.
|
class |
ThreadNamePatternConverter
Formats the event thread name.
|
class |
ThreadPriorityPatternConverter
Formats the event thread priority.
|
class |
VariablesNotEmptyReplacementConverter
VariablesNotEmpty pattern converter.
|
Modifier and Type | Method and Description |
---|---|
void |
AbstractStyleNameConverter.format(LogEvent event,
StringBuilder toAppendTo)
Formats an event into a string buffer.
|
void |
NdcPatternConverter.format(LogEvent event,
StringBuilder toAppendTo) |
Modifier and Type | Class and Description |
---|---|
class |
MutableInstant
An instantaneous point on the time line, used for high-precision log event timestamps.
|
Modifier and Type | Class and Description |
---|---|
class |
MapMessage<M extends MapMessage<M,V>,V>
Represents a Message that consists of a Map.
|
interface |
ParameterVisitable
Allows message parameters to be iterated over without any allocation
or memory copies.
|
interface |
ReusableMessage
Messages implementing this interface are reused between logging calls.
|
class |
ReusableMessageFactory
Implementation of the
MessageFactory interface that avoids allocating temporary objects where possible. |
class |
ReusableObjectMessage
Mutable Message wrapper around an Object message.
|
class |
ReusableParameterizedMessage
Reusable parameterized message.
|
class |
ReusableSimpleMessage
Mutable Message wrapper around a String message.
|
class |
StringMapMessage
A
StringMapMessage typed to String -only values. |
Modifier and Type | Class and Description |
---|---|
class |
Unbox
Utility for preventing primitive parameter values from being auto-boxed.
|
Modifier and Type | Method and Description |
---|---|
static StringBuilder |
Unbox.box(boolean value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static StringBuilder |
Unbox.box(byte value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static StringBuilder |
Unbox.box(char value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static StringBuilder |
Unbox.box(double value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static StringBuilder |
Unbox.box(float value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static StringBuilder |
Unbox.box(int value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static StringBuilder |
Unbox.box(long value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static StringBuilder |
Unbox.box(short value)
Returns a
StringBuilder containing the text representation of the specified primitive value. |
static Class<?> |
StackLocatorUtil.getCallerClass(Class<?> anchor) |
Class<?> |
StackLocator.getCallerClass(Class<?> anchor) |
static Class<?> |
StackLocatorUtil.getCallerClass(Class<?> sentinelClass,
Predicate<Class<?>> callerPredicate)
Search for a calling class.
|
Class<?> |
StackLocator.getCallerClass(Class<?> sentinelClass,
Predicate<Class<?>> callerPredicate) |
static Class<?> |
StackLocatorUtil.getCallerClass(int depth) |
Class<?> |
StackLocator.getCallerClass(int depth)
Gets the Class of the method that called this method at the location up the call stack by the given stack
frame depth.
|
static Class<?> |
StackLocatorUtil.getCallerClass(String fqcn)
Equivalent to
StackLocatorUtil.getCallerClass(String, String) with an empty pkg . |
static Class<?> |
StackLocatorUtil.getCallerClass(String fqcn,
String pkg)
Search for a calling class.
|
Class<?> |
StackLocator.getCallerClass(String fqcn,
String pkg) |
static ClassLoader |
StackLocatorUtil.getCallerClassLoader(int depth)
Gets the ClassLoader of the class that called this method at the location up the call stack by the given
stack frame depth.
|
static Deque<Class<?>> |
StackLocatorUtil.getCurrentStackTrace() |
Deque<Class<?>> |
StackLocator.getCurrentStackTrace() |
Copyright © 1999-2023 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.