Top Description Interfaces Classes Enums
[default module]

Package org.apache.logging.log4j.spi

Annotations
@Export
@Version:2.20.1
Imports
org.osgi.annotation.bundle.Export, org.osgi.annotation.versioning.Version

Internal interfaces and classes to be used by authors of logging implementations or for internal use by API classes.

Interface Summary

Modifier and TypeInterface and Description
public interface
CleanableThreadContextMap

Extension service provider interface to implement additional custom MDC behavior for org.apache.logging.log4j.ThreadContext.

public interface
CopyOnWrite

Marker interface indicating that the implementing class is a copy-on-write data structure.

public interface
ExtendedLogger

Extends the Logger interface with methods that facilitate implementing or extending Loggers.

public interface
LocationAwareLogger

Logger that accepts the location of the caller.

public interface
LoggerAdapter<
the external logger class for this registry (e.g., org.slf4j.Logger)
L
>

A basic registry for LoggerContext objects and their associated external Logger classes.

public interface
LoggerContext

Anchor point for logging implementations.

public interface
LoggerContextFactory

Implemented by factories that create LoggerContext objects.

public interface
LoggerContextShutdownAware

Interface allowing interested classes to know when a LoggerContext has shutdown - if the LoggerContext implementation provides a way to register listeners.

public interface
LoggerContextShutdownEnabled

LoggerContexts implementing this are able register LoggerContextShutdownAware classes.

public interface
ObjectThreadContextMap

Extension service provider interface to allow putting Object values in the org.apache.logging.log4j.ThreadContext.

public interface
ReadOnlyThreadContextMap

Read-only view of the data structure that implements MDC behavior for org.apache.logging.log4j.ThreadContext.

public interface
Terminable

Interface to be implemented by LoggerContext's that provide a shutdown method.

public interface
ThreadContextMap

Service provider interface to implement custom MDC behavior for org.apache.logging.log4j.ThreadContext.

public interface
ThreadContextMap2

Extension service provider interface to implement additional custom MDC behavior for org.apache.logging.log4j.ThreadContext.

public interface
ThreadContextStack

Service provider interface to implement custom NDC behavior for ThreadContext.

Class Summary

Modifier and TypeClass and Description
public abstract class
AbstractLogger

Base implementation of a Logger.

public abstract class
AbstractLoggerAdapter<
the Logger class to adapt
L
>

Provides an abstract base class to use for implementing LoggerAdapter.

pack-priv class
CopyOnWriteSortedArrayThreadContextMap

SortedArrayStringMap-based implementation of the ThreadContextMap interface that creates a copy of the data structure on every modification.

public class
DefaultThreadContextMap

The actual ThreadContext Map.

public class
DefaultThreadContextStack

A copy-on-write thread-safe variant of org.apache.logging.log4j.spi.ThreadContextStack in which all mutative operations (add, pop, and so on) are implemented by making a fresh copy of the underlying list.

public class
ExtendedLoggerWrapper

Wrapper class that exposes the protected AbstractLogger methods to support wrapped loggers.

pack-priv class
GarbageFreeSortedArrayThreadContextMap

SortedArrayStringMap-based implementation of the ThreadContextMap interface that attempts not to create temporary objects.

public class
LoggerContextKey

Deprecated with no replacement - no longer used
Creates keys used in maps for use in LoggerContext implementations.
public class
LoggerRegistry<T extends ExtendedLogger>

Convenience class to be used by LoggerContext implementations.

public class
MessageFactory2Adapter

Adapts a legacy MessageFactory to the new MessageFactory2 interface.

public class
public class
NoOpThreadContextMap

ThreadContextMap implementation used when either of system properties disableThreadContextMap or .

public class
Provider

Model class for a Log4j 2 provider.

public class
ThreadContextMapFactory

Creates the ThreadContextMap instance used by the ThreadContext.

Enum Summary

Modifier and TypeEnum and Description
public enum
StandardLevel

Standard Logging Levels as an enumeration for use internally.