Package ghidra.util

Class TaskUtilities

java.lang.Object
ghidra.util.TaskUtilities

public class TaskUtilities extends Object
  • Constructor Details

    • TaskUtilities

      public TaskUtilities()
  • Method Details

    • addTrackedTaskListener

      public static void addTrackedTaskListener(TrackedTaskListener listener)
      Adds a listener that will be notified when tasks are tracked (when they are added and removed from tracking).
      Parameters:
      listener - The listener to add.
    • removeTrackedTaskListener

      public static void removeTrackedTaskListener(TrackedTaskListener listener)
      Removes the given listener added via addTrackedTask(Task,TaskMonitor).
      Parameters:
      listener - The listener that needs to be removed.
    • addTrackedTask

      public static void addTrackedTask(Task task, TaskMonitor monitor)
      Adds a Task to the list of tasks that have not yet finished running.

      Note: it is safe to add the same task more than once, as it will not be repeatedly tracked.

      Parameters:
      task - The task to watch
      monitor - the task monitor for the given task
    • removeTrackedTask

      public static void removeTrackedTask(Task task)
      Removes the Task to the list of tasks that have not yet finished running.
      Parameters:
      task - The task to stop watching.
    • isExecutingTasks

      public static boolean isExecutingTasks()
      Returns true if there are tasks that are running or need to be run.
      Returns:
      true if there are tasks that are running or need to be run.
    • isTaskRunning

      public static boolean isTaskRunning(String title)
      Returns true if the task with the indicated title is running.
      Parameters:
      title - the title of the desired task
      Returns:
      true if the task with the indicated title is running.