public class InstantTypeSerializer extends AbstractDateTimeSerializer<Instant>
Instant type.UTCcustomization| Constructor | Description |
|---|---|
InstantTypeSerializer(Customization customization) |
Creates a new instance.
|
| Modifier and Type | Method | Description |
|---|---|---|
protected String |
formatDefault(Instant value,
Locale locale) |
Format with default formatter for a given
java.time date object. |
protected String |
formatStrictIJson(Instant value) |
Format date object as strict IJson date format.
|
protected String |
formatWithFormatter(Instant value,
DateTimeFormatter formatter) |
Format date object with given formatter
|
protected Instant |
toInstant(Instant value) |
Convert java.time object to epoch milliseconds instant.
|
getJsonbDateFormatter, getZonedFormatter, serialize, serialize, toJson, toTemporalAccessorpublic InstantTypeSerializer(Customization customization)
customization - Model customization.protected Instant toInstant(Instant value)
AbstractDateTimeSerializertoInstant in class AbstractDateTimeSerializer<Instant>value - date object to convertprotected String formatDefault(Instant value, Locale locale)
AbstractDateTimeSerializerjava.time date object.
Different default formatter for each date object type is used.formatDefault in class AbstractDateTimeSerializer<Instant>value - date objectlocale - locale from annotation / default not nullprotected String formatWithFormatter(Instant value, DateTimeFormatter formatter)
AbstractDateTimeSerializerformatWithFormatter in class AbstractDateTimeSerializer<Instant>value - date object to formatformatter - formatter to format withprotected String formatStrictIJson(Instant value)
AbstractDateTimeSerializerformatStrictIJson in class AbstractDateTimeSerializer<Instant>value - value to formatCopyright © 2018 Oracle Corporation. All rights reserved.