org.crosswire.common.util
Class PatternFormatter
java.lang.Object
java.util.logging.Formatter
org.crosswire.common.util.PatternFormatter
public class PatternFormatter
- extends Formatter
Formats a log entry by pattern.
- {0} is the Date
- {1} is the name of the logger
- {2} is the level of the record
- {3} is the message
- {4} is the throwable
- {5} is the class name (typically the same as the logger's name)
- {6} is the method name
- {7} is the line number
- {8} is the system supplied new line
Distribution Licence:
JSword is free software; you can redistribute it
and/or modify it under the terms of the GNU General Public License,
version 2 as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
The License is available on the internet
here, or by writing to:
Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
MA 02111-1307, USA
The copyright to this program is held by it's authors.
|
- Version:
- $Id: PatternFormatter.java,v 1.3 2004/10/02 23:50:53 joe Exp $
- Author:
- DM Smith [dmsmith555 at yahoo dot com], Joe Walker [joe at eireneh dot com]
- See Also:
Licence
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
dat
private Date dat
DEFAULT_FORMAT
private static final String DEFAULT_FORMAT
- See Also:
- Constant Field Values
formatter
private MessageFormat formatter
lineSeparator
private String lineSeparator
PatternFormatter
public PatternFormatter()
format
public String format(LogRecord record)
- Format the given LogRecord.
- Specified by:
format
in class Formatter
- Parameters:
record
- the log record to be formatted.
- Returns:
- a formatted log record