Package ch.qos.logback.classic
Class PatternLayout
- java.lang.Object
-
- ch.qos.logback.core.spi.ContextAwareBase
-
- ch.qos.logback.core.LayoutBase<E>
-
- ch.qos.logback.core.pattern.PatternLayoutBase<ILoggingEvent>
-
- ch.qos.logback.classic.PatternLayout
-
- All Implemented Interfaces:
Layout<ILoggingEvent>,ContextAware,LifeCycle
@Deprecated(since="2022-01-27") public class PatternLayout extends PatternLayoutBase<ILoggingEvent>
Deprecated.A flexible layout configurable with pattern string. The goal of this class is to
formataILoggingEventand return the results in a {#link String}. The format of the result depends on the conversion pattern.For more information about this layout, please refer to the online manual at http://logback.qos.ch/manual/layouts.html#PatternLayout
-
-
Field Summary
Fields Modifier and Type Field Description static java.util.Map<java.lang.String,java.lang.String>CONVERTER_CLASS_TO_KEY_MAPDeprecated.static java.util.Map<java.lang.String,java.lang.String>DEFAULT_CONVERTER_MAPDeprecated.static java.util.Map<java.lang.String,java.lang.String>defaultConverterMapDeprecated.replaced by DEFAULT_CONVERTER_MAPstatic java.lang.StringHEADER_PREFIXDeprecated.
-
Constructor Summary
Constructors Constructor Description PatternLayout()Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.lang.StringdoLayout(ILoggingEvent event)Deprecated.Transform an event (of type Object) and return it as a String after appropriate formatting.java.util.Map<java.lang.String,java.lang.String>getDefaultConverterMap()Deprecated.Concrete implementations of this class are responsible for elaborating the mapping between pattern words and converters.-
Methods inherited from class ch.qos.logback.core.pattern.PatternLayoutBase
getEffectiveConverterMap, getInstanceConverterMap, getPattern, getPresentationHeader, isOutputPatternAsHeader, setOutputPatternAsHeader, setPattern, setPostCompileProcessor, start, toString
-
Methods inherited from class ch.qos.logback.core.LayoutBase
getContentType, getContext, getFileFooter, getFileHeader, getPresentationFooter, isStarted, setContext, setFileFooter, setFileHeader, setPresentationFooter, setPresentationHeader, stop
-
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getStatusManager
-
-
-
-
Field Detail
-
DEFAULT_CONVERTER_MAP
public static final java.util.Map<java.lang.String,java.lang.String> DEFAULT_CONVERTER_MAP
Deprecated.
-
CONVERTER_CLASS_TO_KEY_MAP
public static final java.util.Map<java.lang.String,java.lang.String> CONVERTER_CLASS_TO_KEY_MAP
Deprecated.
-
defaultConverterMap
public static final java.util.Map<java.lang.String,java.lang.String> defaultConverterMap
Deprecated.replaced by DEFAULT_CONVERTER_MAP
-
HEADER_PREFIX
public static final java.lang.String HEADER_PREFIX
Deprecated.- See Also:
- Constant Field Values
-
-
Method Detail
-
getDefaultConverterMap
public java.util.Map<java.lang.String,java.lang.String> getDefaultConverterMap()
Deprecated.Description copied from class:PatternLayoutBaseConcrete implementations of this class are responsible for elaborating the mapping between pattern words and converters.- Specified by:
getDefaultConverterMapin classPatternLayoutBase<ILoggingEvent>- Returns:
- A map associating pattern words to the names of converter classes
-
doLayout
public java.lang.String doLayout(ILoggingEvent event)
Deprecated.Description copied from interface:LayoutTransform an event (of type Object) and return it as a String after appropriate formatting.Taking in an object and returning a String is the least sophisticated way of formatting events. However, it is remarkably CPU-effective.
- Parameters:
event- The event to format- Returns:
- the event formatted as a String
-
-