## org.eclipse.datatools.connectivity.oda.flatfile.util
Class DateFormatFactory

    java.lang.Object
      org.eclipse.datatools.connectivity.oda.flatfile.util.DateFormatFactory

    public class DateFormatFactory

extends java.lang.Object

Manages per-thread storage of locale-specific DateFormat instances. Use this factory to obtain DateFormat instances to address two issues: (1) Reduce cost of on-the-fly construction of DateFormat instances. The factory uses cached instances whenever possible. (2) MT-safety issue related to use of shared DateFormat instances across threads

Constructor Summary
`DateFormatFactory()`

Method Summary
`static com.ibm.icu.text.DateFormat` `getDateInstance(int dateStyle, com.ibm.icu.util.ULocale locale)` Gets DateFormat instance allocated to the current thread for the given date style, timestyle and locale.
`static com.ibm.icu.text.DateFormat` `getDateTimeInstance(int dateStyle, int timeStyle, com.ibm.icu.util.ULocale locale)` Gets DateFormat instance allocated to the current thread for the given date style, timestyle and locale.
`static com.ibm.icu.text.SimpleDateFormat` `getPatternInstance(org.eclipse.datatools.connectivity.oda.flatfile.util.PatternKey pattern)` Gets DateFormat instance allocated to the current thread for the given pattern.

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DateFormatFactory

    public DateFormatFactory()

Method Detail

### getDateTimeInstance

    public static com.ibm.icu.text.DateFormat getDateTimeInstance(int dateStyle,
                                                                  int timeStyle,
                                                                  com.ibm.icu.util.ULocale locale)

  Gets DateFormat instance allocated to the current thread for the given date style, timestyle and locale. Returned instance is safe to use

### getDateInstance

    public static com.ibm.icu.text.DateFormat getDateInstance(int dateStyle,
                                                              com.ibm.icu.util.ULocale locale)

  Gets DateFormat instance allocated to the current thread for the given date style, timestyle and locale. Returned instance is safe to use

### getPatternInstance

    public static com.ibm.icu.text.SimpleDateFormat getPatternInstance(org.eclipse.datatools.connectivity.oda.flatfile.util.PatternKey pattern)

  Gets DateFormat instance allocated to the current thread for the given pattern. Returned instance is safe to use