public class Date extends AbstractDate
LOGGER| Constructor and Description |
|---|
Date(long epochMilli,
DateType type)
Simple constructor that requires all mandatory fields.
|
Date(String dateString,
DateType type)
Simple constructor that requires all mandatory fields.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getValue()
Returns the date as ISO-8601-compliant String.
|
void |
setDate(Instant date)
Changes the date value using an Instant that marks a date.
|
void |
setDate(long epochMilli)
Changes the date value using the amount of milliseconds that passed
from 01/01/1970 00:00:00 until this date.
|
void |
setValue(String stringValue)
Tries to set the date by parsing an ISO 8601 compliant String.
|
getDateInformation, getType, setDateInformation, setType, stringToInstant, unixTimestampToInstantpublic Date(String dateString, DateType type)
dateString - a ISO-8601-compliant date stringtype - the event that is marked by this datepublic Date(long epochMilli,
DateType type)
epochMilli - milliseconds that passed since 01/01/1970 00:00:00type - the event that is marked by this datepublic String getValue()
getValue in class AbstractDatepublic void setValue(String stringValue)
setValue in class AbstractDatestringValue - the String that is to be parsedpublic void setDate(long epochMilli)
epochMilli - the amount of milliseconds between 01/01/1970 00:00:00 and this dateCopyright © 2017–2018. All rights reserved.