|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.logging.log4j.core.impl.Log4jLogEvent
public class Log4jLogEvent
Implementation of a LogEvent.
Constructor Summary | |
---|---|
Log4jLogEvent(String loggerName,
Marker marker,
String fqcn,
Level level,
Message message,
Throwable t)
Constructor. |
|
Log4jLogEvent(String loggerName,
Marker marker,
String fqcn,
Level level,
Message message,
Throwable t,
Map<String,String> mdc,
Stack<String> ndc,
String threadName,
StackTraceElement location,
long timestamp)
Constructor. |
Method Summary | |
---|---|
static Log4jLogEvent |
deserialize(Serializable event)
|
Map<String,String> |
getContextMap()
Get the MDC data. |
Stack<String> |
getContextStack()
Get the NDC data. |
String |
getFQCN()
The fully qualified class name of the class that was called by the caller. |
Level |
getLevel()
Returns the logging Level. |
String |
getLoggerName()
Return the name of the Logger used to generate the event. |
Marker |
getMarker()
Return the Marker associated with the event, or null. |
Message |
getMessage()
Return the Message associated with the event. |
long |
getMillis()
Return the time in milliseconds from the epoch when the event occurred. |
StackTraceElement |
getSource()
Return the StackTraceElement for the caller. |
String |
getThreadName()
Return the name of the Thread on which the event was generated. |
Throwable |
getThrown()
Return the Throwable associated with the event, or null. |
static Serializable |
serialize(Log4jLogEvent event)
|
String |
toString()
|
protected Object |
writeReplace()
Creates a LogEventProxy that can be serialized. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Log4jLogEvent(String loggerName, Marker marker, String fqcn, Level level, Message message, Throwable t)
loggerName
- The name of the Logger.marker
- The Marker or null.fqcn
- The fully qualified class name of the caller.level
- The logging Level.message
- The Message.t
- A Throwable or null.public Log4jLogEvent(String loggerName, Marker marker, String fqcn, Level level, Message message, Throwable t, Map<String,String> mdc, Stack<String> ndc, String threadName, StackTraceElement location, long timestamp)
loggerName
- The name of the Logger.marker
- The Marker or null.fqcn
- The fully qualified class name of the caller.level
- The logging Level.message
- The Message.t
- A Throwable or null.mdc
- The mapped diagnostic context.ndc
- the nested diagnostic context.threadName
- The name of the thread.location
- The locations of the caller.timestamp
- The timestamp of the event.Method Detail |
---|
public Level getLevel()
getLevel
in interface LogEvent
public String getLoggerName()
getLoggerName
in interface LogEvent
public Message getMessage()
getMessage
in interface LogEvent
public String getThreadName()
getThreadName
in interface LogEvent
public long getMillis()
getMillis
in interface LogEvent
public Throwable getThrown()
getThrown
in interface LogEvent
public Marker getMarker()
getMarker
in interface LogEvent
public String getFQCN()
getFQCN
in interface LogEvent
public Map<String,String> getContextMap()
LogEvent
getContextMap
in interface LogEvent
public Stack<String> getContextStack()
LogEvent
getContextStack
in interface LogEvent
public StackTraceElement getSource()
getSource
in interface LogEvent
protected Object writeReplace()
public static Serializable serialize(Log4jLogEvent event)
public static Log4jLogEvent deserialize(Serializable event)
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |