org.media.mn8.util.cron
Class CronTrigger
java.lang.Object
|
+--org.media.mn8.util.cron.CronTrigger
- All Implemented Interfaces:
- Trigger
- public class CronTrigger
- extends Object
- implements Trigger
Constructor Summary |
CronTrigger(int minute,
int hour,
int day,
int month,
int year,
boolean isDayOfWeek)
Constructor for Cron. |
m_minute
protected final int m_minute
m_hour
protected final int m_hour
m_dayOfMonth
protected final int m_dayOfMonth
m_month
protected final int m_month
m_dayOfWeek
protected final int m_dayOfWeek
m_year
protected final int m_year
CronTrigger
public CronTrigger(int minute,
int hour,
int day,
int month,
int year,
boolean isDayOfWeek)
- Constructor for Cron.
Day is either day of week or day of month depending on value of isDayOfWeek.
if (isDayOfWeek == true) then valid values are 1-7 otherwise the values
are 1-31
- Parameters:
minute
- the minute at which job is scheduled. (0-59)hour
- hour at which job is scheduled. (0-23 or -1 for every hour)month
- the month at which job is scheduled. (0-11 or -1 for every month)year
- the year when job is scheduled (-1 implies every year)day
- the dayisDayOfWeek
- true if day is a day of week or false if day is day of month
getTimeAfter
public long getTimeAfter(long time)
- Retrieve the next time at which this trigger activates.
- Specified by:
getTimeAfter
in interface Trigger
- Returns:
- the time at which the trigger will activate
reset
public void reset()
- Reset the cron-trigger.
- Specified by:
reset
in interface Trigger
toString
public String toString()
- Overrides:
toString
in class Object
"Copyright © 2000-2002 Internet Multicasting Services, media.org & noLimits Technologies. All Rights Reserved."