| java.lang.Object com.jamonapi.JAMonBufferListener com.jamonapi.log4j.Log4jBufferListener
Log4jBufferListener | public class Log4jBufferListener extends JAMonBufferListener (Code) | |
This class can act as a standard JAMonBufferListener/FIFOBuffer or more
interestingly if used with log4j it will put in the Buffer data that although
designed to work as a Buffer that displays details unique to log4j, if the
monitor does not have a Log4jMonKey, it will fallback to Standard
JAMonBufferListener behaviour. This makes it so no problems exist if someone
inadvertently assigns a Log4jBufferListener to a non log4j entity.
author: steve souza |
Method Summary | |
public JAMonListener | copy() | protected String[] | getDefaultHeader() | public String[] | getHeader() | public void | processEvent(Monitor mon) When this event is fired the monitor will be added to the rolling buffer.
If it is a log4j monitor the buffer will be specific to log4j fields
(i.e.LoggingEvent info such as threadname, formattedmessage, exception
stack trace and a few others. | protected Object[] | toArray(LoggingEvent event, Monitor mon) method that returns an array to use in the Buffer. |
Log4jBufferListener | public Log4jBufferListener()(Code) | | Constructor that creaates this object with its default name (the class
name)
|
Log4jBufferListener | public Log4jBufferListener(String name)(Code) | | Pass in the jamonListener name
|
Log4jBufferListener | public Log4jBufferListener(String name, BufferList list)(Code) | | Name the listener and pass in the jamon BufferList to use
|
getHeader | public String[] getHeader()(Code) | | Returns the valid header for display of this buffer
|
processEvent | public void processEvent(Monitor mon)(Code) | | When this event is fired the monitor will be added to the rolling buffer.
If it is a log4j monitor the buffer will be specific to log4j fields
(i.e.LoggingEvent info such as threadname, formattedmessage, exception
stack trace and a few others. If it is not then the super class's
processEvent is called.
|
toArray | protected Object[] toArray(LoggingEvent event, Monitor mon)(Code) | | method that returns an array to use in the Buffer. It can return any
sortable objects as long as they match what is returned in the
getHeader() method.
Parameters: event - Parameters: mon - |
|
|