|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.oddjob.schedules.AbstractSchedule
org.oddjob.schedules.schedules.DateSchedule
public final class DateSchedule
The dates must be of the form yyyy-MM-dd where the format is as specified by the Java Date Format.
<schedules:date on="2004-12-25" xmlns:schedules="http://rgordon.co.uk/oddjob/schedules"/>
Constructor Summary | |
---|---|
DateSchedule()
|
Method Summary | |
---|---|
String |
getFrom()
Get the from Date as a String. |
String |
getTo()
Return the to date as a string. |
ScheduleResult |
nextDue(ScheduleContext context)
For a given date a schedule will provide the interval this schedule should next be scheduled in. |
void |
setFrom(String startDateString)
|
void |
setOn(String on)
|
void |
setTo(String endDateString)
|
String |
toString()
Override toString. |
Methods inherited from class org.oddjob.schedules.AbstractSchedule |
---|
getRefinement, setRefinement |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DateSchedule()
Method Detail |
---|
public void setFrom(String startDateString)
Property: from
Description: The from date for the schedule. Defaults to along time ago.
Required: No.
startDateString
- The from date. May be null.
ParseException
- If the String isn't a Date.public String getFrom()
public void setTo(String endDateString)
Property: to
Description: The to date for the schedule. This date is inclusive, the defined interval is up to and including the last millisecond of this date. This defaults to a long time away.
Required: No.
endDateString
- The end date. May be null.
ParseException
- If the string isn't a valid date.public String getTo()
public void setOn(String on)
Property: on
Description: A specific date on which to schedule something.
Required: No.
in
- The on text.
ParseException
- If the string isn't a date.public ScheduleResult nextDue(ScheduleContext context)
Schedule
If the schedule is never due again for the given date, null is returned.
nextDue
in interface Schedule
public String toString()
toString
in class Object
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |