It can be configured to use one of three variants: date,
time or datetime and one of four styles: long, full, medium or short.
Alternatively, a formatting pattern can be used. This can either be a locale-dependent
or locale-independent formatting pattern. When looking up a formatting pattern, a mechansim
similar to resource bundle lookup is used. Suppose the locale is nl-BE, then first a formatting
pattern for nl-BE will be sought, then one for nl, and if that is not
found, finally the locale-independent formatting pattern will be used.
NOTE: the earlier statement about the fact that this class uses java.text.SimpleDateFormat
is not entirely correct. In fact, it uses a small wrapper class that will either delegate to
java.text.SimpleDateFormat or com.ibm.icu.text.SimpleDateFormat. The com.ibm version will automatically
be used if it is present on the classpath, otherwise the java.text version will be used.