public class DateFormatter extends java.lang.Object implements ArgumentFormatter<java.util.Date>
Date
values.
This formatter simply delegates to a SimpleDateFormat
.
Constructor and Description |
---|
DateFormatter() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
format(java.util.Date date,
java.lang.String... args)
A
SimpleDateFormat pattern is expected as first argument.An optional second argument can be set to specify a locale as an ISO 639 language code. |
public java.lang.String format(java.util.Date date, java.lang.String... args)
SimpleDateFormat
pattern is expected as first argument.format
in interface ArgumentFormatter<java.util.Date>
date
- the object to formatargs
- optional arguments for the formatter to control the formatting.