|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.emf.common.util.BasicMonitor
public class BasicMonitor
The most basic implementation of a task monitor.
Nested Class Summary | |
---|---|
static class |
BasicMonitor.Delegating
A simple monitor that delegates to another monitor. |
static class |
BasicMonitor.EclipseSubProgress
An Eclipse subprogress monitor that directly implements the monitor API. |
static class |
BasicMonitor.Printing
A simple monitor that prints progress to a print stream. |
Field Summary |
---|
Fields inherited from interface org.eclipse.emf.common.util.Monitor |
---|
UNKNOWN |
Constructor Summary | |
---|---|
BasicMonitor()
|
Method Summary | |
---|---|
void |
beginTask(java.lang.String name,
int totalWork)
Called once per instance to indicate the name of the task and its expected duration. |
void |
clearBlocked()
Clears the reason for the activity being blocked. |
void |
done()
Called to indicate the task is complete. |
Diagnostic |
getBlockedReason()
Returns the current reason for task being blocked, or null . |
void |
internalWorked(double work)
Called by subprogress monitors to do fractional work. |
boolean |
isCanceled()
Returns whether the activity has been canceled. |
void |
setBlocked(Diagnostic reason)
Sets the reason for the activity being blocked. |
void |
setCanceled(boolean isCanceled)
Sets whether the active should be canceled. |
void |
setTaskName(java.lang.String name)
Update the task name. |
void |
subTask(java.lang.String name)
Sets the current subtask of the overall task. |
static IProgressMonitor |
toIProgressMonitor(Monitor monitor)
Creates a delegating wrapper that allows the monitor to be used in a context requiring an instance implementing the Eclipse API. |
static IProgressMonitorWithBlocking |
toIProgressMonitorWithBlocking(Monitor monitor)
Creates a delegating wrapper that allows the monitor to be used in a context requiring an instance implementing the Eclipse API. |
static Monitor |
toMonitor(IProgressMonitor progressMonitor)
Creates a delegating wrapper that allows the Eclipse progress monitor to be used in a context requiring an instance implementing the monitor API. |
static Monitor |
toMonitor(IProgressMonitorWithBlocking progressMonitor)
Creates a delegating wrapper that allows the Eclipse progress monitor to be used in a context requiring an instance implementing the monitor API. |
void |
worked(int work)
Called to indicate the amount or progress on the task. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BasicMonitor()
Method Detail |
---|
public boolean isCanceled()
Monitor
isCanceled
in interface Monitor
public void setCanceled(boolean isCanceled)
Monitor
setCanceled
in interface Monitor
public Diagnostic getBlockedReason()
null
.
public void setBlocked(Diagnostic reason)
Monitor
setBlocked
in interface Monitor
public void clearBlocked()
Monitor
clearBlocked
in interface Monitor
public void beginTask(java.lang.String name, int totalWork)
Monitor
beginTask
in interface Monitor
public void setTaskName(java.lang.String name)
Monitor
setTaskName
in interface Monitor
public void subTask(java.lang.String name)
Monitor
subTask
in interface Monitor
public void worked(int work)
Monitor
worked
in interface Monitor
public void internalWorked(double work)
Monitor
internalWorked
in interface Monitor
public void done()
Monitor
done
in interface Monitor
public static IProgressMonitor toIProgressMonitor(Monitor monitor)
public static IProgressMonitorWithBlocking toIProgressMonitorWithBlocking(Monitor monitor)
public static Monitor toMonitor(IProgressMonitorWithBlocking progressMonitor)
public static Monitor toMonitor(IProgressMonitor progressMonitor)
|
Copyright 2001-2012 IBM Corporation and others. All Rights Reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |