Package com.nomagic.magicdraw.ui
Class ProgressMonitorAdapter
- java.lang.Object
-
- com.nomagic.magicdraw.ui.ProgressMonitorAdapter
-
- All Implemented Interfaces:
org.eclipse.core.runtime.IProgressMonitor
@OpenApi public class ProgressMonitorAdapter extends java.lang.Object implements org.eclipse.core.runtime.IProgressMonitor
An implementation ofProgressStatus
mapper toIProgressMonitor
.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) double
current
private static boolean
log
private ProgressStatus
mStatus
-
Constructor Summary
Constructors Constructor Description ProgressMonitorAdapter(ProgressStatus status)
Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
beginTask(java.lang.String s, int max)
void
done()
void
internalWorked(double v)
boolean
isCanceled()
void
setCanceled(boolean b)
void
setTaskName(java.lang.String s)
void
subTask(java.lang.String s)
static org.eclipse.core.runtime.IProgressMonitor
toProgressMonitor(ProgressStatus status)
MapsProgressStatus
toIProgressMonitor
.static ProgressStatus
toProgressStatus(org.eclipse.core.runtime.IProgressMonitor monitor)
MapsIProgressMonitor
toProgressStatus
.void
worked(int i)
-
-
-
Field Detail
-
log
private static final boolean log
- See Also:
- Constant Field Values
-
mStatus
private final ProgressStatus mStatus
-
current
double current
-
-
Constructor Detail
-
ProgressMonitorAdapter
public ProgressMonitorAdapter(ProgressStatus status)
Constructor- Parameters:
status
- status
-
-
Method Detail
-
toProgressMonitor
@OpenApi public static org.eclipse.core.runtime.IProgressMonitor toProgressMonitor(@CheckForNull ProgressStatus status)
MapsProgressStatus
toIProgressMonitor
.- Parameters:
status
- status to map.- Returns:
- mapped monitor.
-
toProgressStatus
@OpenApi public static ProgressStatus toProgressStatus(@CheckForNull org.eclipse.core.runtime.IProgressMonitor monitor)
MapsIProgressMonitor
toProgressStatus
.- Parameters:
monitor
- monitor to map.- Returns:
- mapped status.
-
beginTask
public void beginTask(java.lang.String s, int max)
- Specified by:
beginTask
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
done
public void done()
- Specified by:
done
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
isCanceled
public boolean isCanceled()
- Specified by:
isCanceled
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
setCanceled
public void setCanceled(boolean b)
- Specified by:
setCanceled
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
setTaskName
public void setTaskName(java.lang.String s)
- Specified by:
setTaskName
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
subTask
public void subTask(java.lang.String s)
- Specified by:
subTask
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
internalWorked
public void internalWorked(double v)
- Specified by:
internalWorked
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
worked
public void worked(int i)
- Specified by:
worked
in interfaceorg.eclipse.core.runtime.IProgressMonitor
-
-