logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mattsic...@apache.org
Subject svn commit: r1615858 - /logging/log4j/log4j2/trunk/log4j-core/src/main/java/org/apache/logging/log4j/core/LogEvent.java
Date Tue, 05 Aug 2014 02:58:23 GMT
Author: mattsicker
Date: Tue Aug  5 02:58:22 2014
New Revision: 1615858

URL: http://svn.apache.org/r1615858
Log:
Add javadoc intro.

Modified:
    logging/log4j/log4j2/trunk/log4j-core/src/main/java/org/apache/logging/log4j/core/LogEvent.java

Modified: logging/log4j/log4j2/trunk/log4j-core/src/main/java/org/apache/logging/log4j/core/LogEvent.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/log4j-core/src/main/java/org/apache/logging/log4j/core/LogEvent.java?rev=1615858&r1=1615857&r2=1615858&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/log4j-core/src/main/java/org/apache/logging/log4j/core/LogEvent.java
(original)
+++ logging/log4j/log4j2/trunk/log4j-core/src/main/java/org/apache/logging/log4j/core/LogEvent.java
Tue Aug  5 02:58:22 2014
@@ -27,7 +27,17 @@ import org.apache.logging.log4j.core.imp
 import org.apache.logging.log4j.message.Message;
 
 /**
- *
+ * Provides contextual information about a logged message. A LogEvent must be {@link java.io.Serializable}
so that it
+ * may be transmitted over a network connection, output in a
+ * {@link org.apache.logging.log4j.core.layout.SerializedLayout}, and many other uses. Besides
containing a
+ * {@link org.apache.logging.log4j.message.Message}, a LogEvent has a corresponding
+ * {@link org.apache.logging.log4j.Level} that the message was logged at. If a
+ * {@link org.apache.logging.log4j.Marker} was used, then it is included here. The contents
of the
+ * {@link org.apache.logging.log4j.ThreadContext} at the time of the log call are provided
via
+ * {@link #getContextMap()} and {@link #getContextStack()}. If a {@link java.lang.Throwable}
was included in the log
+ * call, then it is provided via {@link #getThrown()}. When this class is serialized, the
attached Throwable will
+ * be wrapped into a {@link org.apache.logging.log4j.core.impl.ThrowableProxy} so that it
may be safely serialized
+ * and deserialized properly without causing problems if the exception class is not available
on the other end.
  */
 public interface LogEvent extends Serializable {
 
@@ -62,14 +72,14 @@ public interface LogEvent extends Serial
     /**
      * Gets the logger name.
      * 
-     * @return logger name, may be null.
+     * @return logger name, may be {@code null}.
      */
     String getLoggerName();
 
     /**
      * Gets the Marker associated with the event.
      * 
-     * @return Marker
+     * @return Marker or {@code null} if no Marker was defined on this LogEvent
      */
     Marker getMarker();
 



Mime
View raw message