Class AbstractCycleWorker

    • Constructor Detail

      • AbstractCycleWorker

        public AbstractCycleWorker()
    • Method Detail

      • activate

        public void activate​(java.lang.String name)
        Description copied from class: AbstractWorker
        Initializes the worker and starts the worker thread.
        activate in class AbstractWorker
        name - the name of the worker thread
      • getCycleTime

        protected final int getCycleTime()
        Description copied from class: AbstractWorker
        Gets the cycleTime of this worker in [ms].
        • > 0 sets the minimum execution time of one Cycle
        • = 0 never wait between two consecutive executions of forever()
        • < 0 causes the Cycle to sleep forever until 'triggerNextRun()' is called
        Specified by:
        getCycleTime in class AbstractWorker
        the cycleTime
      • forever

        protected abstract void forever()
                                 throws java.lang.Throwable
        Description copied from class: AbstractWorker
        This method is called in a loop forever until the Thread gets interrupted.
        Specified by:
        forever in class AbstractWorker