Package rs.baselib.util
Class CronSchedule.TimeRange
java.lang.Object
rs.baselib.util.CronSchedule.AbstractTimeValue
rs.baselib.util.CronSchedule.TimeRange
- All Implemented Interfaces:
Serializable
- Enclosing class:
- CronSchedule
Represents a time range, e.g. 5-9
- Author:
- ralph
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
int
boolean
matches
(int timeValue) Returns true when given time value falls in range.void
setEndValue
(int endValue) void
setStartValue
(int startValue) toString()
Returns cron-like string of this definition.
-
Constructor Details
-
TimeRange
public TimeRange(int startValue, int endValue) -
TimeRange
-
-
Method Details
-
getEndValue
public int getEndValue()- Returns:
- the endValue
-
setEndValue
public void setEndValue(int endValue) - Parameters:
endValue
- the endValue to set
-
getStartValue
public int getStartValue()- Returns:
- the startValue
-
setStartValue
public void setStartValue(int startValue) - Parameters:
startValue
- the startValue to set
-
matches
public boolean matches(int timeValue) Returns true when given time value falls in range.- Specified by:
matches
in classCronSchedule.AbstractTimeValue
- Parameters:
timeValue
- - time value to evaluate- Returns:
- true when time falls in range
-
toString
Returns cron-like string of this definition.
-