Log4j 0.9.1

org.log4j.nt
Class NTEventLogAppender

java.lang.Object
  |
  +--org.log4j.AppenderSkeleton
        |
        +--org.log4j.nt.NTEventLogAppender
All Implemented Interfaces:
Appender, OptionHandler

public class NTEventLogAppender
extends AppenderSkeleton

Append to the NT event log system.

WARNING This appender can only be installed and used on a Windows system.

Do not forget to place the file NTEventLogAppender.dll in a directory that is on the PATH of the Windows system. Otherwise, you will get a java.lang.UnsatisfiedLinkError.

Author:
Chris Taylor, Jim Cakalic

Fields inherited from class org.log4j.AppenderSkeleton
closed, errorHandler, headFilter, layout, name, tailFilter, threshold, THRESHOLD_OPTION
 
Constructor Summary
NTEventLogAppender()
           
NTEventLogAppender(Layout layout)
           
NTEventLogAppender(String source)
           
NTEventLogAppender(String source, Layout layout)
           
NTEventLogAppender(String server, String source)
           
NTEventLogAppender(String server, String source, Layout layout)
           
 
Method Summary
 void append(LoggingEvent event)
          Subclasses of AppenderSkeleton should imlement this method to perform actual logging.
 void close()
          Release any resources allocated within the appender such as file handles, network connections, etc.
 void finalize()
          Finalize this appender by calling the imlenentation's close method.
 boolean requiresLayout()
          The NTEventLogAppender requires a layout.
 
Methods inherited from class org.log4j.AppenderSkeleton
activateOptions, addFilter, clearFilters, doAppend, getErrorHandler, getFirstFilter, getName, getOptionStrings, isAsSevereAsThreshold, setErrorHandler, setLayout, setName, setOption, setThreshold
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NTEventLogAppender

public NTEventLogAppender()

NTEventLogAppender

public NTEventLogAppender(String source)

NTEventLogAppender

public NTEventLogAppender(String server,
                          String source)

NTEventLogAppender

public NTEventLogAppender(Layout layout)

NTEventLogAppender

public NTEventLogAppender(String source,
                          Layout layout)

NTEventLogAppender

public NTEventLogAppender(String server,
                          String source,
                          Layout layout)
Method Detail

close

public void close()
Description copied from interface: Appender
Release any resources allocated within the appender such as file handles, network connections, etc.

It is a programming error to append to a closed appender.


append

public void append(LoggingEvent event)
Description copied from class: AppenderSkeleton
Subclasses of AppenderSkeleton should imlement this method to perform actual logging. See also AppenderSkeleton.doAppend method.
Overrides:
append in class AppenderSkeleton

finalize

public void finalize()
Description copied from class: AppenderSkeleton
Finalize this appender by calling the imlenentation's close method.
Overrides:
finalize in class AppenderSkeleton

requiresLayout

public boolean requiresLayout()
The NTEventLogAppender requires a layout. Hence, this method always returns true.

Log4j 0.9.1

Please notify me about new log4j releases.