jgroup.util.log
Class Eventlogger

java.lang.Object
  extended by jgroup.util.log.Eventlogger

public class Eventlogger
extends java.lang.Object

The event logger class provides methods used for logging specific events to a disk file. It uses a simple memory based buffer, which is flushed to disk after a given number of log events, or on demand. Also, it should flush and close the file on "clean" system exits, using the shutdown hook mechanism.

Since:
Jgroup 3.0
Author:
Rune Vestvik, Hein Meling

Field Summary
static boolean ENABLED
          True if the measurement function should be activated.
static java.lang.String PREFIX
          The filename prefix for the event logs
 
Constructor Summary
Eventlogger()
           
 
Method Summary
static void close()
           
static void flushMem()
           
static void logEvent(Event event)
          Log any event type.
static void logEvent(EventType type, java.lang.String description)
          Log event with both type and description.
static void logEvent(java.lang.String description)
          Log simple event.
static void logEventFlush(Event event)
          Log any event type and flush to disk.
static void logEventFlush(EventType type, java.lang.String description)
          Log event with both type and description and flush to disk.
static void logEventFlush(java.lang.String description)
          Log simple event and flush to disk.
static void logEventNoSysTime(java.lang.String description)
          Log the given event, ignoring system time and group identifier.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PREFIX

public static final java.lang.String PREFIX
The filename prefix for the event logs

See Also:
Constant Field Values

ENABLED

public static final boolean ENABLED
True if the measurement function should be activated.

Constructor Detail

Eventlogger

public Eventlogger()
Method Detail

logEvent

public static void logEvent(java.lang.String description)
Log simple event.


logEvent

public static void logEvent(EventType type,
                            java.lang.String description)
Log event with both type and description.


logEvent

public static void logEvent(Event event)
Log any event type.


logEventFlush

public static void logEventFlush(java.lang.String description)
Log simple event and flush to disk.


logEventFlush

public static void logEventFlush(EventType type,
                                 java.lang.String description)
Log event with both type and description and flush to disk.


logEventFlush

public static void logEventFlush(Event event)
Log any event type and flush to disk.


logEventNoSysTime

public static void logEventNoSysTime(java.lang.String description)
Log the given event, ignoring system time and group identifier.


flushMem

public static void flushMem()

close

public static void close()


Copyright © 1998-2006 The Jgroup/ARM development team. All Rights Reserved.