Package ghidra.feature.vt.gui.task
Class VtTask
java.lang.Object
ghidra.util.task.Task
ghidra.feature.vt.gui.task.VtTask
- All Implemented Interfaces:
ghidra.util.task.MonitoredRunnable
- Direct Known Subclasses:
AcceptMatchTask
,ApplyBlockedMatchTask
,ApplyMarkupAtDestinationAddressTask
,ApplyMarkupItemTask
,ApplyMatchTask
,ClearMarkupItemConsideredStatusTask
,ClearMatchTask
,CreateImpliedMatchesTask
,CreateManualMatchTask
,RejectMatchTask
,RemoveMatchTask
,SetMarkupItemDestinationAddressTask
,TagMarkupItemTask
,UnapplyMarkupItemTask
public abstract class VtTask
extends ghidra.util.task.Task
-
Field Summary
Fields inherited from class ghidra.util.task.Task
taskMonitor, waitForTaskCompleted
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
protected abstract boolean
doWork
(ghidra.util.task.TaskMonitor monitor) Returns an HTML formated error messageprotected String
boolean
returns true if the task did not successfully complete due to an errorprotected void
final void
run
(ghidra.util.task.TaskMonitor monitor) protected boolean
Determine if session events should be suspended during task execution.void
boolean
Returns true if this task was cancelled.boolean
Returns true if the Task executed successfully.Methods inherited from class ghidra.util.task.Task
addTaskListener, canCancel, cancel, getStatusTextAlignment, getTaskTitle, getWaitForTaskCompleted, hasProgress, isCancelled, isModal, monitoredRun, notifyTaskListeners, setHasProgress
-
Field Details
-
session
-
-
Constructor Details
-
VtTask
-
-
Method Details
-
run
public final void run(ghidra.util.task.TaskMonitor monitor) - Specified by:
run
in classghidra.util.task.Task
-
shouldSuspendSessionEvents
protected boolean shouldSuspendSessionEvents()Determine if session events should be suspended during task execution. This can improve performance during task execution at the expense of bulk table updates at task completion. Method return false by default. If not constructed with a session this method is not used.- Returns:
- true if events should be suspended
-
doWork
- Throws:
Exception
-
wasCancelled
public boolean wasCancelled()Returns true if this task was cancelled.- Returns:
- true if this task was cancelled.
-
wasSuccessfull
public boolean wasSuccessfull()Returns true if the Task executed successfully.Note: this method only makes sense if called after the task has executed. If called before, it will always return false;
- Returns:
- true if the Task executed successfully.
-
hasErrors
public boolean hasErrors()returns true if the task did not successfully complete due to an error- Returns:
- true if the task did not successfully complete due to an error
-
showErrors
public void showErrors() -
getErrorHeader
-
getErrorDetails
Returns an HTML formated error message- Returns:
- an HTML formatted error message
-
reportError
-
addErrors
-