Package io.quarkus.scheduler.runtime
Class SimpleScheduler.CronTrigger
- java.lang.Object
-
- io.quarkus.scheduler.runtime.SimpleScheduler.SimpleTrigger
-
- io.quarkus.scheduler.runtime.SimpleScheduler.CronTrigger
-
- All Implemented Interfaces:
Trigger
- Enclosing class:
- SimpleScheduler
static class SimpleScheduler.CronTrigger extends SimpleScheduler.SimpleTrigger
-
-
Field Summary
-
Fields inherited from class io.quarkus.scheduler.runtime.SimpleScheduler.SimpleTrigger
start
-
-
Constructor Summary
Constructors Constructor Description CronTrigger(String id, ZonedDateTime start, com.cronutils.model.Cron cron)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) ZonedDateTime
evaluate(ZonedDateTime now)
Instant
getNextFireTime()
Instant
getPreviousFireTime()
String
toString()
-
Methods inherited from class io.quarkus.scheduler.runtime.SimpleScheduler.SimpleTrigger
getId, isRunning, setRunning
-
-
-
-
Constructor Detail
-
CronTrigger
public CronTrigger(String id, ZonedDateTime start, com.cronutils.model.Cron cron)
-
-
Method Detail
-
getNextFireTime
public Instant getNextFireTime()
- Returns:
- the next time at which the trigger is scheduled to fire, or
null
if it will not fire again
-
getPreviousFireTime
public Instant getPreviousFireTime()
- Returns:
- the previous time at which the trigger fired, or
null
if it has not fired yet
-
evaluate
ZonedDateTime evaluate(ZonedDateTime now)
- Specified by:
evaluate
in classSimpleScheduler.SimpleTrigger
- Returns:
- the scheduled time if fired,
null
otherwise
-
-