Class Log4jLogEvent.Builder
java.lang.Object
org.apache.logging.log4j.core.impl.Log4jLogEvent.Builder
- Enclosing class:
Log4jLogEvent
LogEvent Builder helper class.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate StringMap
private ThreadContext.ContextStack
private boolean
private boolean
private final MutableInstant
private Level
private String
private String
private Marker
private Message
private long
private StackTraceElement
private long
private String
private int
private Throwable
private ThrowableProxy
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the object after all configuration has been set.private void
setContextData
(StringMap contextData) setContextMap
(Map<String, String> contextMap) Deprecated.setContextStack
(ThreadContext.ContextStack contextStack) setEndOfBatch
(boolean endOfBatch) setIncludeLocation
(boolean includeLocation) setInstant
(Instant instant) setLoggerFqcn
(String loggerFqcn) setLoggerName
(String loggerName) setMessage
(Message message) setNanoTime
(long nanoTime) Sets the nano time for the event.setSource
(StackTraceElement source) setThreadId
(long threadId) setThreadName
(String threadName) setThreadPriority
(int threadPriority) setThrownProxy
(ThrowableProxy thrownProxy) setTimeMillis
(long timeMillis) 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.util.Builder
getErrorPrefix, isValid
-
Field Details
-
loggerFqcn
-
marker
-
level
-
loggerName
-
message
-
thrown
-
instant
-
thrownProxy
-
contextData
-
contextStack
-
threadId
private long threadId -
threadName
-
threadPriority
private int threadPriority -
source
-
includeLocation
private boolean includeLocation -
endOfBatch
private boolean endOfBatch -
nanoTime
private long nanoTime
-
-
Constructor Details
-
Builder
public Builder() -
Builder
-
-
Method Details
-
setLevel
-
setLoggerFqcn
-
setLoggerName
-
setMarker
-
setMessage
-
setThrown
-
setTimeMillis
-
setInstant
-
setThrownProxy
-
setContextMap
Deprecated. -
setContextData
-
setContextStack
-
setThreadId
-
setThreadName
-
setThreadPriority
-
setSource
-
setIncludeLocation
-
setEndOfBatch
-
setNanoTime
Sets the nano time for the event.- Parameters:
nanoTime
- The value of the running Java Virtual Machine's high-resolution time source when the event was created.- Returns:
- this builder
-
build
Description copied from interface:Builder
Builds the object after all configuration has been set. This will use default values for any unspecified attributes for the object. -
initTimeFields
private void initTimeFields()
-