Class TriggerTask

java.lang.Object
org.springframework.scheduling.config.Task
org.springframework.scheduling.config.TriggerTask
Direct Known Subclasses:
CronTask

public class TriggerTask extends Task
Task implementation defining a Runnable to be executed according to a given Trigger.
Since:
3.2
Author:
Chris Beams
See Also:
  • Constructor Details

    • TriggerTask

      public TriggerTask(Runnable runnable, Trigger trigger)
      Create a new TriggerTask.
      Parameters:
      runnable - the underlying task to execute
      trigger - specifies when the task should be executed
  • Method Details

    • getTrigger

      public Trigger getTrigger()
      Return the associated trigger.