Class Scheduler

  • All Implemented Interfaces:
    java.lang.Runnable

    public class Scheduler
    extends java.lang.Thread
    This class schedules an AssemblyLine to be run, either at specified times, or as soon as the previous run finishes.
    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.lang.Thread

        java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
    • Field Summary

      • Fields inherited from class java.lang.Thread

        MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
    • Constructor Summary

      Constructors 
      Constructor Description
      Scheduler​(RS rs, SchedulerConfig config)
      The constructor for the class.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Map<java.lang.String,​java.lang.Object> getInfo()
      Returns information about this Scheduler.
      RS getRS()
      Returns the RS that started this Scheduler
      int hashCode()  
      boolean isPaused()
      Returns true if this Scheduler is paused.
      void pauseScheduler()
      Pauses the Scheduler.
      void resumeScheduler()
      Resumes the Scheduler.
      void run()  
      void shutdown()
      Shuts down the Scheduler.
      • Methods inherited from class java.lang.Thread

        activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • Scheduler

        public Scheduler​(RS rs,
                         SchedulerConfig config)
        The constructor for the class.
        Parameters:
        rs - The RS this belongs to.
        config - The SchedulerConfig to use.
    • Method Detail

      • run

        public void run()
        Specified by:
        run in interface java.lang.Runnable
        Overrides:
        run in class java.lang.Thread
      • shutdown

        public void shutdown()
        Shuts down the Scheduler. The running AssemblyLine will continue
      • pauseScheduler

        public void pauseScheduler()
        Pauses the Scheduler. The running AssemblyLine will continue
      • resumeScheduler

        public void resumeScheduler()
        Resumes the Scheduler.
      • isPaused

        public boolean isPaused()
        Returns true if this Scheduler is paused.
        Returns:
        true if this Scheduler is paused.
      • getInfo

        public java.util.Map<java.lang.String,​java.lang.Object> getInfo()
        Returns information about this Scheduler. The following keys may be present in the map:
        schedulerName - The name of this Scheduler
        assemblyLineName - The name of the AssemblyLine/Sequence
        serverName - The Server where the AssemblyLine is run
        configID - The name of the Config Instance
        isPaused - Has the value "true" if this Scheduler is paused
        isKeepAlive - Has the value "true" if this Scheduler keeps the AL alive
        nextRun - The java.util.Date for the next run of the AssemblyLine
        Returns:
      • getRS

        public RS getRS()
        Returns the RS that started this Scheduler
        Returns:
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object