com.mindtree.techworks.insight.spi
Class LogEvent

java.lang.Object
  extended by org.apache.log4j.spi.LoggingEvent
      extended by com.mindtree.techworks.insight.spi.LogEvent
All Implemented Interfaces:
java.io.Serializable

public class LogEvent
extends org.apache.log4j.spi.LoggingEvent

The LogEvent class is a derivative of the Apache log4j LoggingEvent class. Provides constructors to support creating LoggingEvent instances from log4j-like log files.

Version:
1.0, 04/11/26
Author:
Regunath B
See Also:
LoggingEvent, Serialized Form

Field Summary
 
Fields inherited from class org.apache.log4j.spi.LoggingEvent
categoryName, fqnOfCategoryClass, level, timeStamp
 
Constructor Summary
LogEvent()
          No args constructor for this class
LogEvent(org.apache.log4j.spi.LoggingEvent event)
          Constructor for this class.
LogEvent(java.lang.Object message)
          Constructor for this class.
 
Method Summary
 java.lang.String getExceptionName()
           
 LogNamespace getNamespace()
           
 long getRelativeTime()
           
 java.lang.String[] getThrowableStrRepresentation()
          Returns the Throwable information contained in this LogEvent as a String array
 void setExceptionName(java.lang.String exceptionName)
           
 void setNamespace(LogNamespace namespace)
          Sets the namespace information for this LogEvent
 void setRelativeTime(long relativeTime)
           
 
Methods inherited from class org.apache.log4j.spi.LoggingEvent
equals, getFQNOfLoggerClass, getLevel, getLocationInformation, getLogger, getLoggerName, getMDC, getMDCCopy, getMessage, getNDC, getProperties, getProperty, getPropertyKeySet, getRenderedMessage, getSequenceCount, getSequenceNumber, getStartTime, getThreadName, getThrowableInformation, getThrowableStrRep, getTimeStamp, hashCode, initializeProperties, locationInformationExists, prepareForDeferredProcessing, setFQNOfLoggerClass, setLevel, setLocationInformation, setLogger, setLoggerName, setMessage, setNDC, setProperties, setProperty, setRenderedMessage, setSequenceNumber, setThreadName, setThrowableInformation, setTimeStamp
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LogEvent

public LogEvent()
No args constructor for this class


LogEvent

public LogEvent(java.lang.Object message)
Constructor for this class.

Parameters:
message - non-null message string for this LogEvent

LogEvent

public LogEvent(org.apache.log4j.spi.LoggingEvent event)
Constructor for this class. Creates an instance of this class from a Apache log4j LoggingEvent instance

Parameters:
event - the LoggingEvent instance to use for creating an instance of this class
Method Detail

getThrowableStrRepresentation

public java.lang.String[] getThrowableStrRepresentation()
Returns the Throwable information contained in this LogEvent as a String array

Returns:
String[] that contains the stack trace of the Throwable

getNamespace

public LogNamespace getNamespace()
Returns:
Returns the namespace.

setNamespace

public void setNamespace(LogNamespace namespace)
Sets the namespace information for this LogEvent

Parameters:
namespace - The namespace to set.

getExceptionName

public java.lang.String getExceptionName()
Returns:
Returns the exceptionName.

setExceptionName

public void setExceptionName(java.lang.String exceptionName)
Parameters:
exceptionName - The exceptionName to set.

getRelativeTime

public long getRelativeTime()
Returns:
Returns the relativeTime.

setRelativeTime

public void setRelativeTime(long relativeTime)
Parameters:
relativeTime - The relativeTime to set.


Copyright © 2003-2008 MindTree Consulting Ltd.. All Rights Reserved.