Formatter implementation for a JSR-310 java.time.Instant ,
following JSR-310's parsing rules for an Instant (that is, not using a
configurable java.time.format.DateTimeFormatter ): accepting the
default ISO_INSTANT format as well as RFC_1123_DATE_TIME
(which is commonly used for HTTP date header values), as of Spring 4.3.
java.time.Instant#parse , java.time.format.DateTimeFormatter#ISO_INSTANT , java.time.format.DateTimeFormatter#RFC_1123_DATE_TIME
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public Instant | parse(String
the text string text, Locale the current user locale locale)Implements org. |
| public String | print(Instant
the instance to print object, Locale the current user locale locale)Implements org. |
| InstantFormatter | back to summary |
|---|---|
| public InstantFormatter() | |
| parse | back to summary |
|---|---|
| public Instant parse(String text, Locale locale) throws ParseException Implements org. Doc from org. Parse a text String to produce a T.
| |
| back to summary | |
|---|---|
| public String print(Instant object, Locale locale) Implements org. Doc from org. Print the object of type T for display. | |