Class FocessTask

  • All Implemented Interfaces:
    Task

    public class FocessTask
    extends Object
    implements Task
    • Method Detail

      • setNativeTask

        public void setNativeTask​(ComparableTask nativeTask)
      • clear

        public void clear()
      • isSingleThread

        public boolean isSingleThread()
      • cancel

        public boolean cancel​(boolean mayInterruptIfRunning)
        Description copied from interface: Task
        Cancel this task
        Specified by:
        cancel in interface Task
        Parameters:
        mayInterruptIfRunning - must be false
        Returns:
        true if it is cancelled, false otherwise
      • isRunning

        public boolean isRunning()
        Description copied from interface: Task
        Indicate whether this task is running or not
        Specified by:
        isRunning in interface Task
        Returns:
        true if the task is running, false otherwise
      • getPlugin

        public Plugin getPlugin()
        Description copied from interface: Task
        Get the plugin it belongs to
        Specified by:
        getPlugin in interface Task
        Returns:
        the plugin it belongs to
      • getScheduler

        public Scheduler getScheduler()
        Description copied from interface: Task
        Get the scheduler it belongs to
        Specified by:
        getScheduler in interface Task
        Returns:
        the scheduler it belongs to
      • getName

        public String getName()
        Description copied from interface: Task
        Get the name of the task
        Specified by:
        getName in interface Task
        Returns:
        the name of the task
      • isPeriod

        public boolean isPeriod()
        Description copied from interface: Task
        Indicate whether this task is a period-task or not
        Specified by:
        isPeriod in interface Task
        Returns:
        true if it is a period-task, false otherwise
      • isFinished

        public boolean isFinished()
        Description copied from interface: Task
        Indicate whether this task is finished or not
        Specified by:
        isFinished in interface Task
        Returns:
        true if this task is finished, false otherwise
      • isCancelled

        public boolean isCancelled()
        Description copied from interface: Task
        Indicate whether this task is cancelled or not
        Specified by:
        isCancelled in interface Task
        Returns:
        true if it is cancelled, false otherwise
      • run

        public void run()
      • getPeriod

        public java.time.Duration getPeriod()
      • cancel0

        public default void cancel0()