Uses of Interface
org.apache.logging.log4j.message.MessageFactory
Packages that use MessageFactory
Package
Description
Public API for Log4j 2.
Implementation of Log4j 2.
Provides Asynchronous Logger classes and interfaces for low-latency logging.
Public Message Types used for Log4j 2.
Simple logging implementation.
Internal interfaces and classes to be used by authors of logging implementations or for internal use by
API classes.
Status API for Log4j 2.
Classes (JSP tags) to enable logging in JSPs without using Java scripting.
Java JDK java.util.logging (JUL) bridge.
Internal utility classes for the Log4j 2 API.
SLF4J support.
-
Uses of MessageFactory in org.apache.logging.log4j
Methods in org.apache.logging.log4j with type parameters of type MessageFactoryModifier and TypeMethodDescription<MF extends MessageFactory>
MFLogger.getMessageFactory()
Gets the message factory used to convert message Objects and Strings/CharSequences into actual log Messages.Methods in org.apache.logging.log4j with parameters of type MessageFactoryModifier and TypeMethodDescriptionstatic Logger
LogManager.getLogger
(Class<?> clazz, MessageFactory messageFactory) Returns a Logger using the fully qualified name of the Class as the Logger name.static Logger
LogManager.getLogger
(Object value, MessageFactory messageFactory) Returns a Logger using the fully qualified class name of the value as the Logger name.static Logger
LogManager.getLogger
(String name, MessageFactory messageFactory) Returns a Logger with the specified name.static Logger
LogManager.getLogger
(MessageFactory messageFactory) Returns a Logger with the name of the calling class. -
Uses of MessageFactory in org.apache.logging.log4j.core
Fields in org.apache.logging.log4j.core declared as MessageFactoryMethods in org.apache.logging.log4j.core with parameters of type MessageFactoryModifier and TypeMethodDescriptionLoggerContext.getLogger
(String name, MessageFactory messageFactory) Obtains a Logger from the Context.boolean
LoggerContext.hasLogger
(String name, MessageFactory messageFactory) Determines if the specified Logger exists.protected Logger
LoggerContext.newInstance
(LoggerContext ctx, String name, MessageFactory messageFactory) Method parameters in org.apache.logging.log4j.core with type arguments of type MessageFactoryModifier and TypeMethodDescriptionboolean
LoggerContext.hasLogger
(String name, Class<? extends MessageFactory> messageFactoryClass) Determines if the specified Logger exists.Constructors in org.apache.logging.log4j.core with parameters of type MessageFactoryModifierConstructorDescriptionprotected
Logger
(LoggerContext context, String name, MessageFactory messageFactory) The constructor.LoggerProxy
(String name, MessageFactory messageFactory) -
Uses of MessageFactory in org.apache.logging.log4j.core.async
Methods in org.apache.logging.log4j.core.async with parameters of type MessageFactoryModifier and TypeMethodDescriptionprotected Logger
AsyncLoggerContext.newInstance
(LoggerContext ctx, String name, MessageFactory messageFactory) Constructors in org.apache.logging.log4j.core.async with parameters of type MessageFactoryModifierConstructorDescriptionAsyncLogger
(LoggerContext context, String name, MessageFactory messageFactory, AsyncLoggerDisruptor loggerDisruptor) Constructs anAsyncLogger
with the specified context, name and message factory. -
Uses of MessageFactory in org.apache.logging.log4j.jul
Fields in org.apache.logging.log4j.jul declared as MessageFactoryModifier and TypeFieldDescriptionprivate static final MessageFactory
ApiLoggerAdapter.MESSAGE_FACTORY
private static final MessageFactory
CoreLoggerAdapter.MESSAGE_FACTORY
-
Uses of MessageFactory in org.apache.logging.log4j.message
Subinterfaces of MessageFactory in org.apache.logging.log4j.messageClasses in org.apache.logging.log4j.message that implement MessageFactoryModifier and TypeClassDescriptionclass
Provides an abstract superclass forMessageFactory2
implementations with default implementations (and forMessageFactory
by extension).class
class
class
final class
final class
final class
Implementation of theMessageFactory
interface that avoids allocating temporary objects where possible.final class
final class
-
Uses of MessageFactory in org.apache.logging.log4j.simple
Methods in org.apache.logging.log4j.simple with parameters of type MessageFactoryModifier and TypeMethodDescriptionSimpleLoggerContext.getLogger
(String name, MessageFactory messageFactory) boolean
SimpleLoggerContext.hasLogger
(String name, MessageFactory messageFactory) Method parameters in org.apache.logging.log4j.simple with type arguments of type MessageFactoryModifier and TypeMethodDescriptionboolean
SimpleLoggerContext.hasLogger
(String name, Class<? extends MessageFactory> messageFactoryClass) Constructors in org.apache.logging.log4j.simple with parameters of type MessageFactoryModifierConstructorDescriptionSimpleLogger
(String name, Level defaultLevel, boolean showLogName, boolean showShortLogName, boolean showDateTime, boolean showContextMap, String dateTimeFormat, MessageFactory messageFactory, PropertiesUtil props, PrintStream stream) -
Uses of MessageFactory in org.apache.logging.log4j.spi
Classes in org.apache.logging.log4j.spi that implement MessageFactoryModifier and TypeClassDescriptionclass
Adapts a legacy MessageFactory to the new MessageFactory2 interface.Fields in org.apache.logging.log4j.spi declared as MessageFactoryFields in org.apache.logging.log4j.spi with type parameters of type MessageFactoryModifier and TypeFieldDescriptionstatic final Class<? extends MessageFactory>
AbstractLogger.DEFAULT_MESSAGE_FACTORY_CLASS
The default MessageFactory class.Methods in org.apache.logging.log4j.spi with type parameters of type MessageFactoryModifier and TypeMethodDescription<MF extends MessageFactory>
MFAbstractLogger.getMessageFactory()
Methods in org.apache.logging.log4j.spi that return MessageFactoryMethods in org.apache.logging.log4j.spi that return types with arguments of type MessageFactoryModifier and TypeMethodDescriptionprivate static Class<? extends MessageFactory>
AbstractLogger.createClassForProperty
(String property, Class<ReusableMessageFactory> reusableParameterizedMessageFactoryClass, Class<ParameterizedMessageFactory> parameterizedMessageFactoryClass) Methods in org.apache.logging.log4j.spi with parameters of type MessageFactoryModifier and TypeMethodDescriptionstatic void
AbstractLogger.checkMessageFactory
(ExtendedLogger logger, MessageFactory messageFactory) Checks that the message factory a logger was created with is the same as the given messageFactory.static String
LoggerContextKey.create
(String name, MessageFactory messageFactory) Deprecated.private static String
LoggerRegistry.factoryKey
(MessageFactory messageFactory) default ExtendedLogger
LoggerContext.getLogger
(Class<?> cls, MessageFactory messageFactory) Gets an ExtendedLogger using the fully qualified name of the Class as the Logger name.LoggerContext.getLogger
(String name, MessageFactory messageFactory) Gets an ExtendedLogger.LoggerRegistry.getLogger
(String name, MessageFactory messageFactory) Returns an ExtendedLogger.boolean
LoggerContext.hasLogger
(String name, MessageFactory messageFactory) Tests if a Logger with the specified name and MessageFactory exists.boolean
LoggerRegistry.hasLogger
(String name, MessageFactory messageFactory) Detects if a Logger with the specified name and MessageFactory exists.private static MessageFactory2
AbstractLogger.narrow
(MessageFactory result) void
LoggerRegistry.putIfAbsent
(String name, MessageFactory messageFactory, T logger) Method parameters in org.apache.logging.log4j.spi with type arguments of type MessageFactoryModifier and TypeMethodDescriptionstatic String
LoggerContextKey.create
(String name, Class<? extends MessageFactory> messageFactoryClass) Deprecated.private static String
LoggerRegistry.factoryClassKey
(Class<? extends MessageFactory> messageFactoryClass) boolean
LoggerContext.hasLogger
(String name, Class<? extends MessageFactory> messageFactoryClass) Tests if a Logger with the specified name and MessageFactory type exists.boolean
LoggerRegistry.hasLogger
(String name, Class<? extends MessageFactory> messageFactoryClass) Detects if a Logger with the specified name and MessageFactory type exists.Constructors in org.apache.logging.log4j.spi with parameters of type MessageFactoryModifierConstructorDescriptionAbstractLogger
(String name, MessageFactory messageFactory) Creates a new named logger with a particularMessageFactory
.ExtendedLoggerWrapper
(ExtendedLogger logger, String name, MessageFactory messageFactory) Constructor that wraps and existing Logger.MessageFactory2Adapter
(MessageFactory wrapped) -
Uses of MessageFactory in org.apache.logging.log4j.status
Constructors in org.apache.logging.log4j.status with parameters of type MessageFactoryModifierConstructorDescriptionprivate
StatusLogger
(String name, MessageFactory messageFactory) Constructs the singleton instance for the STATUS_LOGGER constant. -
Uses of MessageFactory in org.apache.logging.log4j.taglib
Fields in org.apache.logging.log4j.taglib declared as MessageFactoryMethods in org.apache.logging.log4j.taglib with parameters of type MessageFactoryModifier and TypeMethodDescriptionLog4jTaglibLoggerContext.getLogger
(String name, MessageFactory messageFactory) private static Log4jTaglibLogger
TagUtils.getLogger
(Log4jTaglibLoggerContext context, String name, MessageFactory factory) boolean
Log4jTaglibLoggerContext.hasLogger
(String name, MessageFactory messageFactory) (package private) static Log4jTaglibLogger
TagUtils.resolveLogger
(Log4jTaglibLoggerContext context, Object logger, MessageFactory factory) void
SetLoggerTag.setFactory
(MessageFactory factory) Method parameters in org.apache.logging.log4j.taglib with type arguments of type MessageFactoryModifier and TypeMethodDescriptionboolean
Log4jTaglibLoggerContext.hasLogger
(String name, Class<? extends MessageFactory> messageFactoryClass) Constructors in org.apache.logging.log4j.taglib with parameters of type MessageFactoryModifierConstructorDescriptionLog4jTaglibLogger
(ExtendedLogger logger, String name, MessageFactory messageFactory) -
Uses of MessageFactory in org.apache.logging.log4j.tojul
Methods in org.apache.logging.log4j.tojul with parameters of type MessageFactoryModifier and TypeMethodDescriptionJULLoggerContext.getLogger
(String name, MessageFactory messageFactory) boolean
JULLoggerContext.hasLogger
(String name, MessageFactory messageFactory) Method parameters in org.apache.logging.log4j.tojul with type arguments of type MessageFactoryModifier and TypeMethodDescriptionboolean
JULLoggerContext.hasLogger
(String name, Class<? extends MessageFactory> messageFactoryClass) Constructors in org.apache.logging.log4j.tojul with parameters of type MessageFactoryModifierConstructorDescriptionJULLogger
(String name, MessageFactory messageFactory, Logger logger) -
Uses of MessageFactory in org.apache.logging.log4j.util
Methods in org.apache.logging.log4j.util with parameters of type MessageFactoryModifier and TypeMethodDescriptionstatic Message
LambdaUtil.getMessage
(Supplier<?> supplier, MessageFactory messageFactory) Returns a Message, either the value supplied by the specified function, or a new Message created by the specified Factory. -
Uses of MessageFactory in org.apache.logging.slf4j
Methods in org.apache.logging.slf4j with parameters of type MessageFactoryModifier and TypeMethodDescriptionSLF4JLoggerContext.getLogger
(String name, MessageFactory messageFactory) boolean
SLF4JLoggerContext.hasLogger
(String name, MessageFactory messageFactory) Method parameters in org.apache.logging.slf4j with type arguments of type MessageFactoryModifier and TypeMethodDescriptionboolean
SLF4JLoggerContext.hasLogger
(String name, Class<? extends MessageFactory> messageFactoryClass) Constructors in org.apache.logging.slf4j with parameters of type MessageFactoryModifierConstructorDescriptionSLF4JLogger
(String name, MessageFactory messageFactory, org.slf4j.Logger logger)