com.ibm.di.util
Class Schedule
java.lang.Object
com.ibm.di.util.Schedule
public class Schedule
- extends Object
Class used to compute the next date a Scheduler will be run
Method Summary |
Date |
getNext(Date current)
Computes the next date after the given date. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Schedule
public Schedule(String schedule)
throws Exception
- Constructor.
The schedule parameter must be similar to crontab format,
with 6 fields, separated by space.
- Parameters:
schedule
-
- Throws:
Exception
getNext
public Date getNext(Date current)
throws Exception
- Computes the next date after the given date.
- Parameters:
current
- - If null, uses current date instead.
- Returns:
-
- Throws:
Exception
- If no date can be found.