public class DateRange extends AbstractDate
LOGGER| Constructor and Description |
|---|
DateRange(long epochMilliSince,
long epochMilliUntil,
DateType type)
Simple constructor that requires all mandatory fields.
|
DateRange(String dateString,
DateType type)
Simple constructor that requires all mandatory fields.
|
DateRange(String rangeFrom,
String rangeUntil,
DateType type)
Simple constructor that requires all mandatory fields.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getValue()
Returns the date as a Dublin-Core-compliant String.
|
void |
setRangeFrom(long epochMilli)
Changes the since-value using the amount of milliseconds that passed
from 01/01/1970 00:00:00 until this date.
|
void |
setRangeFrom(String stringValue)
Changes the since-value by parsing a date-string.
|
void |
setRangeUntil(long epochMilli)
Changes the until-value using the amount of milliseconds that passed
from 01/01/1970 00:00:00 until this date.
|
void |
setRangeUntil(String stringValue)
Changes the since-value by parsing a date-string.
|
void |
setValue(String stringValue)
Tries to set the date by parsing a Dublin-Core-compliant String.
|
getDateInformation, getType, setDateInformation, setType, stringToInstant, unixTimestampToInstantpublic DateRange(String dateString, DateType type)
dateString - a Dublin-Core-compliant Stringtype - the event that is marked by this date rangepublic DateRange(long epochMilliSince,
long epochMilliUntil,
DateType type)
epochMilliSince - milliseconds that passed since 01/01/1970 00:00:00 until the beginning of the rangeepochMilliUntil - milliseconds that passed since 01/01/1970 00:00:00 until the end of the rangetype - the event that is marked by this date rangepublic DateRange(String rangeFrom, String rangeUntil, DateType type)
rangeFrom - a Dublin-Core-compliant String that marks the beginning of the range, or null if there is no beginningrangeUntil - a Dublin-Core-compliant String that marks the end of the range, or null if ther is no endtype - the event that is marked by this date rangepublic String getValue()
getValue in class AbstractDatepublic void setValue(String stringValue)
setValue in class AbstractDatestringValue - the String that is to be parsedpublic void setRangeFrom(long epochMilli)
epochMilli - the amount of milliseconds between 01/01/1970 00:00:00 and this datepublic void setRangeFrom(String stringValue)
stringValue - a date string that represents the start-datepublic void setRangeUntil(long epochMilli)
epochMilli - the amount of milliseconds between 01/01/1970 00:00:00 and this datepublic void setRangeUntil(String stringValue)
stringValue - a date string that represents the end-dateCopyright © 2017–2018. All rights reserved.