Schnittstelle JobEntry

Alle Superschnittstellen:
Comparable<JobEntry>
Alle bekannten Implementierungsklassen:
AbstractJobEntry, BaseJobEntryTorque, JobEntryNonPersistent, JobEntryQuartz, JobEntryTorque

public interface JobEntry extends Comparable<JobEntry>
This is a interface for a scheduled job. It does not specify how to configure when to run, that is left to subclasses. See the JobEntryTorque for an example of a JobEntry backed by Torque objects.
Version:
$Id$
Autor:
Eric Pugh, Dave Bryson, Quinton McCombs
  • Methodenübersicht

    Modifizierer und Typ
    Methode
    Beschreibung
    void
    Calculate how long before the next runtime.
    int
    Get the value of jobId.
    Get the next runtime for this job as a String.
    Gets the next runtime as a date
    long
    Get the next runtime for this job as a long.
    Get the Task
    boolean
    Check to see if job is currently active/running
    boolean
    Check to see if job is new
    void
    setActive(boolean isActive)
    Sets whether the job is running.
    void
    setJobId(int v)
    Set the value of jobId.
    void
    Set the value of Task

    Von Schnittstelle geerbte Methoden java.lang.Comparable

    compareTo
  • Methodendetails

    • setActive

      void setActive(boolean isActive)
      Sets whether the job is running.
      Parameter:
      isActive - Whether the job is running.
    • isActive

      boolean isActive()
      Check to see if job is currently active/running
      Gibt zurück:
      true if job is currently being run by the worker thread, otherwise false
    • isNew

      boolean isNew()
      Check to see if job is new
      Gibt zurück:
      true if job is not yet saved, otherwise false
    • getJobId

      int getJobId()
      Get the value of jobId.
      Gibt zurück:
      int
    • setJobId

      void setJobId(int v)
      Set the value of jobId.
      Parameter:
      v - new value
    • getTask

      Get the Task
      Gibt zurück:
      String
    • setTask

      void setTask(String v)
      Set the value of Task
      Parameter:
      v - new value
    • getNextRuntime

      Get the next runtime for this job as a long.
      Gibt zurück:
      The next run time as a long.
    • getNextRunDate

      Gets the next runtime as a date
      Gibt zurück:
      Next run date
    • getNextRunAsString

      Get the next runtime for this job as a String.
      Gibt zurück:
      The next run time as a String.
    • calcRunTime

      Calculate how long before the next runtime.
      The runtime determines it's position in the job queue. Here's the logic:
      1. Create a date the represents when this job is to run.
      2. If this date has expired, them "roll" appropriate date fields forward to the next date.
      3. Calculate the diff in time between the current time and the next run time.
      Löst aus:
      TurbineException - a generic exception.