Package ai.tock.nlp.entity.date
Class DateIntervalEntityValue
-
- All Implemented Interfaces:
-
ai.tock.nlp.entity.Value,ai.tock.nlp.entity.date.DateEntityRange
public final class DateIntervalEntityValue implements DateEntityRange
Date interval definition.
-
-
Field Summary
Fields Modifier and Type Field Description private final DateEntityValuedateprivate final DateEntityValuetoDate
-
Constructor Summary
Constructors Constructor Description DateIntervalEntityValue(DateEntityValue date, DateEntityValue toDate)
-
Method Summary
Modifier and Type Method Description final DateEntityValuegetDate()final DateEntityValuegetToDate()ZonedDateTimestart()Returns the start inclusive date. ZonedDateTimeinclusiveEnd(ZoneId zoneId)Returns the end inclusive date. ZonedDateTimeend(ZoneId zoneId)Returns the end exclusive date. Durationduration()-
-
Constructor Detail
-
DateIntervalEntityValue
DateIntervalEntityValue(DateEntityValue date, DateEntityValue toDate)
-
-
Method Detail
-
getDate
final DateEntityValue getDate()
-
getToDate
final DateEntityValue getToDate()
-
start
ZonedDateTime start()
Returns the start inclusive date. Ie
9h -> 9h
from 9h to 10h -> 9h
-
inclusiveEnd
ZonedDateTime inclusiveEnd(ZoneId zoneId)
Returns the end inclusive date. Ie:
from 9h to 10h -> 10h
from 9h to 10h00 -> 10h
9h -> 10h
this morning (4h to 12h) -> 12h
-
end
ZonedDateTime end(ZoneId zoneId)
Returns the end exclusive date. Ie:
from 9h to 10h -> 11h
from 9h to 10h00 -> 10h01
9h -> 10h
-
-
-
-