public final class DateFormat
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static com.google.gwt.i18n.client.DateTimeFormat |
DATE_FORMAT_STR_ISO8601
Defines a commonly used date format that conforms
to ISO-8601 date formatting standard, when it includes basic undecorated
timezone definition
|
static com.google.gwt.i18n.client.DateTimeFormat |
DATE_FORMAT_STR_ISO8601_Z
Same as 'regular' 8601, but handles 'Z' as an alias for "+0000"
(or "GMT")
|
static com.google.gwt.i18n.client.DateTimeFormat |
DATE_FORMAT_STR_PLAIN
ISO-8601 with just the Date part, no time
|
static com.google.gwt.i18n.client.DateTimeFormat |
DATE_FORMAT_STR_RFC1123
This constant defines the date format specified by
RFC 1123 / RFC 822.
|
static com.google.gwt.i18n.client.TimeZone |
UTC_TIMEZONE
UTC TimeZone
|
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
format(java.util.Date date)
Format a date using
DATE_FORMAT_STR_ISO8601 and UTC_TIMEZONE |
static java.lang.String |
format(com.google.gwt.i18n.client.DateTimeFormat format,
java.util.Date date)
Format a date using the
DateTimeFormat given in parameter and UTC_TIMEZONE. |
static java.lang.String |
format(com.google.gwt.i18n.client.DateTimeFormat format,
com.google.gwt.i18n.client.TimeZone timeZone,
java.util.Date date)
Format a date using the
DateTimeFormat and TimeZone given in
parameters |
static java.lang.String |
format(JsonSerializerParameters params,
java.util.Date date)
Format a date using
JsonSerializerParameters or default values : DATE_FORMAT_STR_ISO8601 and UTC_TIMEZONE |
static java.lang.String |
format(com.google.gwt.i18n.client.TimeZone timeZone,
java.util.Date date)
Format a date using
DATE_FORMAT_STR_ISO8601 and TimeZone given in parameter |
static java.util.Date |
parse(com.google.gwt.i18n.client.DateTimeFormat format,
java.lang.String date)
Parse a date using the
DateTimeFormat given in
parameter and the browser timezone. |
static java.util.Date |
parse(java.lang.String date)
Parse a date using
DATE_FORMAT_STR_ISO8601 and the browser timezone. |
static java.util.Date |
parse(java.lang.String pattern,
java.lang.String date)
Parse a date using the pattern given in parameter or
DATE_FORMAT_STR_ISO8601 and the browser timezone. |
public static final com.google.gwt.i18n.client.DateTimeFormat DATE_FORMAT_STR_ISO8601
public static final com.google.gwt.i18n.client.DateTimeFormat DATE_FORMAT_STR_ISO8601_Z
public static final com.google.gwt.i18n.client.DateTimeFormat DATE_FORMAT_STR_PLAIN
public static final com.google.gwt.i18n.client.DateTimeFormat DATE_FORMAT_STR_RFC1123
public static final com.google.gwt.i18n.client.TimeZone UTC_TIMEZONE
public static java.lang.String format(java.util.Date date)
DATE_FORMAT_STR_ISO8601 and UTC_TIMEZONEdate - date to formatpublic static java.lang.String format(JsonSerializerParameters params, java.util.Date date)
JsonSerializerParameters or default values : DATE_FORMAT_STR_ISO8601 and UTC_TIMEZONEdate - date to formatpublic static java.lang.String format(com.google.gwt.i18n.client.DateTimeFormat format,
java.util.Date date)
DateTimeFormat given in parameter and UTC_TIMEZONE.format - format to usedate - date to formatpublic static java.lang.String format(com.google.gwt.i18n.client.TimeZone timeZone,
java.util.Date date)
DATE_FORMAT_STR_ISO8601 and TimeZone given in parametertimeZone - timezone to usedate - date to formatpublic static java.lang.String format(com.google.gwt.i18n.client.DateTimeFormat format,
com.google.gwt.i18n.client.TimeZone timeZone,
java.util.Date date)
DateTimeFormat and TimeZone given in
parametersformat - format to usetimeZone - timezone to usedate - date to formatpublic static java.util.Date parse(java.lang.String date)
DATE_FORMAT_STR_ISO8601 and the browser timezone.date - date to parsepublic static java.util.Date parse(java.lang.String pattern,
java.lang.String date)
DATE_FORMAT_STR_ISO8601 and the browser timezone.pattern - pattern to use. If null, DATE_FORMAT_STR_ISO8601 will be used.date - date to parsepublic static java.util.Date parse(com.google.gwt.i18n.client.DateTimeFormat format,
java.lang.String date)
DateTimeFormat given in
parameter and the browser timezone.format - format to usedate - date to parseCopyright © 2015. All Rights Reserved.