org.log5j.format
Class XmlFormat

java.lang.Object
  extended by org.log5j.format.XmlFormat
All Implemented Interfaces:
Format

public final class XmlFormat
extends java.lang.Object
implements Format

An XML format for log messages.

XmlFormat has two configuration properties:

Author:
Bruce Ashton

Constructor Summary
XmlFormat(java.util.Properties properties)
          The standard constructor takes as arguments the properties that may affect how SimpleFormat formats log lines.
 
Method Summary
 java.lang.String format(java.lang.String logName, java.lang.String levelName, java.lang.Object... objects)
          Return a formatted String derived from a number of objects or primitives to append to a logger output stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XmlFormat

public XmlFormat(java.util.Properties properties)
The standard constructor takes as arguments the properties that may affect how SimpleFormat formats log lines.

XmlFormat recognises the following properties;

Parameters:
properties - the properties of this format object.
Method Detail

format

public java.lang.String format(java.lang.String logName,
                               java.lang.String levelName,
                               java.lang.Object... objects)
Description copied from interface: Format
Return a formatted String derived from a number of objects or primitives to append to a logger output stream.

Specified by:
format in interface Format
Parameters:
logName - the name of the logger
levelName - the logging level name
objects - the array of objects or primitives providing Strings to log