Class DateTrigger<C extends DateTriggerConfig>
java.lang.Object
net.datenwerke.scheduler.service.scheduler.entities.AbstractTrigger
net.datenwerke.scheduler.service.scheduler.triggers.complex.DateTrigger<C>
- Direct Known Subclasses:
DailyNthdayTrigger,DailyWorkdayTrigger,MonthlyNamedDayTrigger,MonthlyNthDayMthMonthTrigger,WeeklyTrigger,YearlyAtDateTrigger,YearlyNamedDayTrigger
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncomputeNextFireTime(Date afterTime) booleanconsumes(DateTriggerConfig config) getFinalFireTime(Date lastFireTime) intreturns how many times the trigger fires in one dayReturns the given date with the time component set to the time of the first execution of the trigger at this day.getLastFireTimeOfDay(Date day) Sets the time component of the supplied date to the time, the trigger fires the last time at this date.getNextScheduleTimes(int times) getNthFireTimeOfDay(Date day, int n) returns the given date with the time part set to the time of the nth execution.getNthFireTimeOfDayAfter(Date day, int n) Returns the supplied date, with its time component set to the time of the nth execution of the trigger after the time given Does not check if the trigger fires at allvoidMethods inherited from class net.datenwerke.scheduler.service.scheduler.entities.AbstractTrigger
computeFirstFireTime, confirmExecution, equals, getFirstFireTime, getId, getMisfireInstruction, getNextScheduledFireTime, getNrOfFailedExecutions, getNrOfSuccessfulExecutions, getNrOfVetoedExecutions, getVersion, hashCode, initialize, isDone, isExecuteOnce, isInitialized, setDone, setExecuteOnce, setFirstFireTime, setId, setMisfireInstruction, setNextScheduledFireTime, setNrOfFailedExecutions, setNrOfSuccessfulExecutions, setNrOfVetoedExecutions, setVersion, updateStateAfterFailedExecution, updateStateAfterSuccessfulExecution, updateStateAfterVetoedExecution
-
Constructor Details
-
DateTrigger
public DateTrigger() -
DateTrigger
-
-
Method Details
-
setConfig
-
getConfig
-
getFirstFireTimeOfDay
Returns the given date with the time component set to the time of the first execution of the trigger at this day. Does not check if the trigger does fire at this day at all.- Parameters:
day-
-
getLastFireTimeOfDay
Sets the time component of the supplied date to the time, the trigger fires the last time at this date. Does not check, if the trigger fires at this dayat all- Parameters:
day-
-
getNthFireTimeOfDayAfter
Returns the supplied date, with its time component set to the time of the nth execution of the trigger after the time given Does not check if the trigger fires at all- Parameters:
day-n-- Throws:
IllegalArgumentException
-
getNthFireTimeOfDay
returns the given date with the time part set to the time of the nth execution.- Parameters:
day-n-
-
getFiringsPerDay
public int getFiringsPerDay()returns how many times the trigger fires in one day -
consumes
-
getFinalFireTime
-
getFinalFireTime
-
computeNextFireTime
- Specified by:
computeNextFireTimein classAbstractTrigger
-
getNextScheduleTimes
- Overrides:
getNextScheduleTimesin classAbstractTrigger
-