org.w3c.util
Class TimeFormatter

java.lang.Object
  extended by org.w3c.util.TimeFormatter

public class TimeFormatter
extends java.lang.Object

This class does date formatting using the same format strings accepted by the strftime(3) UNIX call. This class has static methods only.


Constructor Summary
TimeFormatter()
           
 
Method Summary
static java.lang.String format(java.util.Date date, java.lang.String format)
          Format the given date as a string, according to the given format string.
static void main(java.lang.String[] args)
          For testing purposes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimeFormatter

public TimeFormatter()
Method Detail

format

public static java.lang.String format(java.util.Date date,
                                      java.lang.String format)
Format the given date as a string, according to the given format string. The format string is of the form used by the strftime(3) UNIX call.

Parameters:
date - The date to format
format - The formatting string
Returns:
the String with the formatted date.

main

public static void main(java.lang.String[] args)
For testing purposes