Java in a Nutshell Online Quick Reference for Java 1.1

CLASS java.text.DateFormat

Availability: JDK 1.1

public abstract class DateFormat extends Format implements Cloneable {
   // Protected Constructor
      protected DateFormat();
   // Constants
      public static final int AM_PM_FIELD;
      public static final int DATE_FIELD;
      public static final int DAY_OF_WEEK_FIELD;
      public static final int DAY_OF_WEEK_IN_MONTH_FIELD;
      public static final int DAY_OF_YEAR_FIELD;
      public static final int DEFAULT;
      public static final int ERA_FIELD;
      public static final int FULL;
      public static final int HOUR0_FIELD;
      public static final int HOUR1_FIELD;
      public static final int HOUR_OF_DAY0_FIELD;
      public static final int HOUR_OF_DAY1_FIELD;
      public static final int LONG;
      public static final int MEDIUM;
      public static final int MILLISECOND_FIELD;
      public static final int MINUTE_FIELD;
      public static final int MONTH_FIELD;
      public static final int SECOND_FIELD;
      public static final int SHORT;
      public static final int TIMEZONE_FIELD;
      public static final int WEEK_OF_MONTH_FIELD;
      public static final int WEEK_OF_YEAR_FIELD;
      public static final int YEAR_FIELD;
   // Protected Instance Variables
      protected Calendar calendar;
      protected NumberFormat numberFormat;
   // Class Methods
      public static Locale[] getAvailableLocales();
      public static final DateFormat getDateInstance();
      public static final DateFormat getDateInstance(int style);
      public static final DateFormat getDateInstance(int style, Locale aLocale);
      public static final DateFormat getDateTimeInstance();
      public static final DateFormat getDateTimeInstance(int dateStyle, int timeStyle);
      public static final DateFormat getDateTimeInstance(int dateStyle, int timeStyle, Locale aLocale);
      public static final DateFormat getInstance();
      public static final DateFormat getTimeInstance();
      public static final DateFormat getTimeInstance(int style);
      public static final DateFormat getTimeInstance(int style, Locale aLocale);
   // Public Instance Methods
      public Object clone();  // Overrides Format.clone()
      public boolean equals(Object obj);  // Overrides Object.equals()
      public final StringBuffer format(Object obj, StringBuffer toAppendTo, FieldPosition fieldPosition);  // Defines Format.format()
      public abstract StringBuffer format(Date date, StringBuffer toAppendTo, FieldPosition fieldPosition);
      public final String format(Date date);
      public Calendar getCalendar();
      public NumberFormat getNumberFormat();
      public TimeZone getTimeZone();
      public int hashCode();  // Overrides Object.hashCode()
      public boolean isLenient();
      public Date parse(String text) throws ParseException;
      public abstract Date parse(String text, ParsePosition pos);
      public Object parseObject(String source, ParsePosition pos);  // Defines Format.parseObject()
      public void setCalendar(Calendar newCalendar);
      public void setLenient(boolean lenient);
      public void setNumberFormat(NumberFormat newNumberFormat);
      public void setTimeZone(TimeZone zone);
}

Java in a Nutshell Online Quick Reference for Java 1.1
Created by David Flanagan. Copyright © 1997 by O'Reilly & Associates.