org.openmdx.kernel.log.impl
Class LogFormatterStandard

java.lang.Object
  extended by org.openmdx.kernel.log.impl.LogFormatterStandard
All Implemented Interfaces:
LogFormatter

public class LogFormatterStandard
extends Object
implements LogFormatter

This class provides a simple formatter for log events


Field Summary
static String DEFAULT_FORMAT
          The log event format for standard log events
static String DEFAULT_FORMAT_STATISTICS
          The log event format for statistics log events
 
Fields inherited from interface org.openmdx.kernel.log.LogFormatter
formatSpecifierPrefix, multiLineMarker
 
Constructor Summary
LogFormatterStandard(String aFormat)
          Constructor.
 
Method Summary
 String format(LogEvent event)
          Returns a String representation for the LogEvent object.
 String getFormat()
          Returns the currently set format string.
 String getLogFileSpecifier()
          Returns log file format specifier.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_FORMAT

public static final String DEFAULT_FORMAT
The log event format for standard log events

See Also:
Constant Field Values

DEFAULT_FORMAT_STATISTICS

public static final String DEFAULT_FORMAT_STATISTICS
The log event format for statistics log events

See Also:
Constant Field Values
Constructor Detail

LogFormatterStandard

public LogFormatterStandard(String aFormat)
Constructor.

Method Detail

format

public String format(LogEvent event)
Returns a String representation for the LogEvent object. Uses the standard format.

This operation is not threadsafe.

Specified by:
format in interface LogFormatter
Returns:
a String representation

getFormat

public String getFormat()
Returns the currently set format string.

Specified by:
getFormat in interface LogFormatter
Returns:
A log format string

getLogFileSpecifier

public String getLogFileSpecifier()
Returns log file format specifier. This specifier is written to the first line of each log file.

Specified by:
getLogFileSpecifier in interface LogFormatter
Returns:
A log format specifier string


This software is published under the BSD license. Copyright © 2003-2007, OMEX AG, Switzerland, All rights reserved. Use is subject to license terms.