Interface TimeSchedule
- All Superinterfaces:
Serializable
A time schedule states when something is due: at a first time and, if it has a period, again and
again. The period counts either from the previous due time (fixed rate), so that the due times
are the first time plus a multiple of the period, or from the end of the previous occurrence
(fixed delay). What an occurrence is and when it ends depends on what the schedule triggers; the
schedule knows nothing about it.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final longThe default serial version UID. -
Method Summary
Modifier and TypeMethodDescriptiongetDate()Gets the first due time of this schedule.Gets the period of this schedule, aDurationfor a fixed length of time, such as minutes or hours, or aPeriodfor calendar days, weeks or months.booleanGets whether the period of this schedule counts from the previous due time (fixed rate) or from the end of the previous occurrence (fixed delay).
-
Field Details
-
serialVersionUID
static final long serialVersionUIDThe default serial version UID.- See Also:
-
-
Method Details
-
getDate
ZonedDateTime getDate()Gets the first due time of this schedule.- Returns:
- The first due time of this schedule.
-
getPeriod
TemporalAmount getPeriod()Gets the period of this schedule, aDurationfor a fixed length of time, such as minutes or hours, or aPeriodfor calendar days, weeks or months.- Returns:
- The period of this schedule or
nullif it is due only once.
-
isFixedRate
boolean isFixedRate()Gets whether the period of this schedule counts from the previous due time (fixed rate) or from the end of the previous occurrence (fixed delay).- Returns:
- Whether the period of this schedule counts from the previous due time. This is
falsefor a schedule without a period.
-