Class SimpleLiteralPatternConverter
java.lang.Object
org.apache.logging.log4j.core.pattern.AbstractPatternConverter
org.apache.logging.log4j.core.pattern.LogEventPatternConverter
org.apache.logging.log4j.core.pattern.SimpleLiteralPatternConverter
- All Implemented Interfaces:
ArrayPatternConverter
,PatternConverter
- Direct Known Subclasses:
SimpleLiteralPatternConverter.Noop
,SimpleLiteralPatternConverter.Space
,SimpleLiteralPatternConverter.StringValue
abstract class SimpleLiteralPatternConverter
extends LogEventPatternConverter
implements ArrayPatternConverter
Formats a string literal without substitution.
This is an effectively-sealed internal type.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static final class
private static final class
private static final class
-
Field Summary
Fields inherited from class org.apache.logging.log4j.core.pattern.AbstractPatternConverter
LOGGER
Fields inherited from interface org.apache.logging.log4j.core.pattern.PatternConverter
CATEGORY
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal void
format
(Object ignored, StringBuilder output) Formats an object into a string buffer.(package private) abstract void
format
(StringBuilder output) final void
format
(StringBuilder output, Object... args) Formats an array of Objects.final void
format
(LogEvent ignored, StringBuilder output) Formats an event into a string buffer.final boolean
Normally pattern converters are not meant to handle Exceptions although few pattern converters might.final boolean
(package private) static LogEventPatternConverter
(package private) static LogEventPatternConverter
Methods inherited from class org.apache.logging.log4j.core.pattern.AbstractPatternConverter
getName, getStyleClass
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.logging.log4j.core.pattern.PatternConverter
getName, getStyleClass
-
Constructor Details
-
SimpleLiteralPatternConverter
private SimpleLiteralPatternConverter()
-
-
Method Details
-
of
-
of
-
format
Formats an event into a string buffer.- Specified by:
format
in classLogEventPatternConverter
- Parameters:
ignored
- event to format, may not be null.output
- string buffer to which the formatted event will be appended. May not be null.
-
format
Formats an object into a string buffer.- Specified by:
format
in interfacePatternConverter
- Overrides:
format
in classLogEventPatternConverter
- Parameters:
ignored
- event to format, may not be null.output
- string buffer to which the formatted event will be appended. May not be null.
-
format
Formats an array of Objects.- Specified by:
format
in interfaceArrayPatternConverter
- Parameters:
output
- The StringBuilder to add the content to.args
- The Object array.
-
format
-
isVariable
public final boolean isVariable()- Overrides:
isVariable
in classLogEventPatternConverter
-
handlesThrowable
public final boolean handlesThrowable()Description copied from class:LogEventPatternConverter
Normally pattern converters are not meant to handle Exceptions although few pattern converters might.By examining the return values for this method, the containing layout will determine whether it handles throwables or not.
- Overrides:
handlesThrowable
in classLogEventPatternConverter
- Returns:
- true if this PatternConverter handles throwables
-