org.apache.log4j.helpers

Class RelativeTimeDateFormat


public class RelativeTimeDateFormat
extends DateFormat

Formats a Date by printing the number of milliseconds elapsed since the start of the application. This is the fastest printing DateFormat in the package.
Author:
Ceki Gülcü
Since:
0.7.5

Field Summary

protected long
startTime

Constructor Summary

RelativeTimeDateFormat()

Method Summary

StringBuffer
format(Date date, StringBuffer sbuf, FieldPosition fieldPosition)
Appends to sbuf the number of milliseconds elapsed since the start of the application.
Date
parse(String s, ParsePosition pos)
This method does not do anything but return null.

Field Details

startTime

protected final long startTime

Constructor Details

RelativeTimeDateFormat

public RelativeTimeDateFormat()

Method Details

format

public StringBuffer format(Date date,
                           StringBuffer sbuf,
                           FieldPosition fieldPosition)
Appends to sbuf the number of milliseconds elapsed since the start of the application.
Since:
0.7.5

parse

public Date parse(String s,
                  ParsePosition pos)
This method does not do anything but return null.

Copyright 2000-2005 Apache Software Foundation.