public class NullProgressMonitor extends Object implements ProgressMonitor
setCanceled.| Constructor and Description |
|---|
NullProgressMonitor() |
| Modifier and Type | Method and Description |
|---|---|
void |
beginTask(String label,
int totalWork)
Informs the progress monitor that a new task has been started, with a given number of expected steps.
|
void |
done()
Informs the progress monitor that all is completed.
|
boolean |
isCanceled()
Typically used by the (long-running) process to determine whether the user has requested cancellation.
|
void |
setCanceled(boolean value)
Typically called from a parallel thread triggered by the user, this informs the progress monitor that it needs to
return
true for isCanceled. |
void |
setTaskName(String value)
Changes the name or label of the current task.
|
void |
subTask(String label)
Sets the label that serves as sub-task, typically printed under the main task name.
|
void |
worked(int amount)
Informs the progress monitor that one or more steps have been completed towards the current task (see
beginTask). |
public boolean isCanceled()
ProgressMonitorisCanceled in interface ProgressMonitorpublic void beginTask(String label, int totalWork)
ProgressMonitorbeginTask in interface ProgressMonitorlabel - the name of the tasktotalWork - the number of steps (see worked) that is expected to be needed to complete the taskpublic void done()
ProgressMonitordone in interface ProgressMonitorpublic void setCanceled(boolean value)
ProgressMonitortrue for isCanceled.
Once a process has been canceled, it should not be un-canceled.setCanceled in interface ProgressMonitorvalue - true if canceledpublic void setTaskName(String value)
ProgressMonitorsetTaskName in interface ProgressMonitorpublic void subTask(String label)
ProgressMonitorsubTask in interface ProgressMonitorlabel - the subtask labelpublic void worked(int amount)
ProgressMonitorbeginTask).worked in interface ProgressMonitoramount - the number of steps completedCopyright © 2019 TopQuadrant, Inc.. All rights reserved.