Package de.mhus.lib.core.schedule
Class IntervalWithStartTimeJob
- java.lang.Object
-
- java.util.TimerTask
-
- de.mhus.lib.core.MTimerTask
-
- de.mhus.lib.core.schedule.SchedulerJob
-
- de.mhus.lib.core.schedule.IntervalWithStartTimeJob
-
- All Implemented Interfaces:
de.mhus.lib.basics.Named,ITimerTask,MutableSchedulerJob,Operation,MNlsProvider,Nls,Runnable
public class IntervalWithStartTimeJob extends SchedulerJob implements MutableSchedulerJob
Executes the task every 'interval' milliseconds after execution finished.- Author:
- mikehummel
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class de.mhus.lib.core.schedule.SchedulerJob
SchedulerJob.MyTaskContext
-
-
Field Summary
-
Fields inherited from class de.mhus.lib.core.schedule.SchedulerJob
CALCULATE_NEXT, context, DISABLED_TIME, log, REMOVE_TIME
-
Fields inherited from class de.mhus.lib.core.MTimerTask
CANCELLED, environment, EXECUTED, SCHEDULED, UNKNOWN, VIRGIN
-
-
Constructor Summary
Constructors Constructor Description IntervalWithStartTimeJob(long start, long interval, ITimerTask task)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddoCaclulateNextExecution()Calculate the next executionTime and store it into nextExecutionTimebooleandoReconfigure(String config)Reconfigure the scheduler.voiddoReschedule(Scheduler queue, long time)voidsetDone(boolean done)voidsetScheduledTime(long scheduledTime)StringtoString()-
Methods inherited from class de.mhus.lib.core.schedule.SchedulerJob
canExecute, doError, doExecute, doExecute2, doit, doSchedule, doTick, doTimeoutReached, getDescription, getInfo, getIntercepter, getLastExecutionStart, getLastExecutionStop, getLogTrailConfig, getNextExecutionTime, getNls, getOwner, getScheduledTime, getTask, getThread, getTimeoutInMinutes, getUuid, hasAccess, isBusy, isDone, isExecutionTimeReached, nls, releaseBusy, setBusy, setInfo, setIntercepter, setLogTrailConfig, setNextExecutionTime, setTask, setTimeoutInMinutes
-
Methods inherited from class de.mhus.lib.core.MTimerTask
cancel, getName, getStatus, isCanceled, onError, onFinal, run, run, setCanceled, setName
-
Methods inherited from class java.util.TimerTask
scheduledExecutionTime
-
-
-
-
Constructor Detail
-
IntervalWithStartTimeJob
public IntervalWithStartTimeJob(long start, long interval, ITimerTask task)
-
-
Method Detail
-
doCaclulateNextExecution
public void doCaclulateNextExecution()
Description copied from class:SchedulerJobCalculate the next executionTime and store it into nextExecutionTime- Specified by:
doCaclulateNextExecutionin classSchedulerJob
-
toString
public String toString()
- Overrides:
toStringin classSchedulerJob
-
doReschedule
public void doReschedule(Scheduler queue, long time)
- Specified by:
doReschedulein interfaceMutableSchedulerJob- Overrides:
doReschedulein classSchedulerJob
-
setDone
public void setDone(boolean done)
- Specified by:
setDonein interfaceMutableSchedulerJob- Overrides:
setDonein classSchedulerJob
-
doReconfigure
public boolean doReconfigure(String config)
Description copied from interface:MutableSchedulerJobReconfigure the scheduler. Returns true if it was successful.- Specified by:
doReconfigurein interfaceMutableSchedulerJob- Returns:
- true if successful
-
setScheduledTime
public void setScheduledTime(long scheduledTime)
- Specified by:
setScheduledTimein interfaceMutableSchedulerJob- Overrides:
setScheduledTimein classSchedulerJob
-
-