Class AbstractWorkspaceHandler
- java.lang.Object
-
- org.eclipse.core.commands.common.EventManager
-
- org.eclipse.core.commands.AbstractHandler
-
- org.eclipse.emf.ecp.cdo.internal.ui.handlers.AbstractWorkspaceHandler
-
- All Implemented Interfaces:
org.eclipse.core.commands.IHandler
,org.eclipse.core.commands.IHandler2
- Direct Known Subclasses:
CheckinHandler
,UpdateHandler
public abstract class AbstractWorkspaceHandler extends org.eclipse.core.commands.AbstractHandler
Abstract Handler for executing commands.- Author:
- Eike Stepper
-
-
Constructor Summary
Constructors Constructor Description AbstractWorkspaceHandler(java.lang.String jobName)
Constructor.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description java.lang.Object
execute(org.eclipse.core.commands.ExecutionEvent event)
protected abstract void
execute(org.eclipse.core.commands.ExecutionEvent event, org.eclipse.emf.cdo.workspace.CDOWorkspace workspace, org.eclipse.core.runtime.IProgressMonitor monitor)
Execute the given event.java.lang.String
getJobName()
Get the display name of the current job.protected static void
refreshDirtyState(org.eclipse.core.commands.ExecutionEvent event)
Refresh the dirty state of theCDOWorkspace
.-
Methods inherited from class org.eclipse.core.commands.AbstractHandler
addHandlerListener, dispose, fireHandlerChanged, hasListeners, isEnabled, isHandled, removeHandlerListener, setBaseEnabled, setEnabled
-
-
-
-
Method Detail
-
getJobName
public final java.lang.String getJobName()
Get the display name of the current job.- Returns:
- the name
-
execute
public final java.lang.Object execute(org.eclipse.core.commands.ExecutionEvent event) throws org.eclipse.core.commands.ExecutionException
- Throws:
org.eclipse.core.commands.ExecutionException
- See Also:
IHandler.execute(org.eclipse.core.commands.ExecutionEvent)
-
execute
protected abstract void execute(org.eclipse.core.commands.ExecutionEvent event, org.eclipse.emf.cdo.workspace.CDOWorkspace workspace, org.eclipse.core.runtime.IProgressMonitor monitor) throws org.eclipse.core.commands.ExecutionException
Execute the given event.- Parameters:
event
- the eventworkspace
- theCDOWorkspace
monitor
- a progress monitor- Throws:
org.eclipse.core.commands.ExecutionException
- if execution fails
-
refreshDirtyState
protected static void refreshDirtyState(org.eclipse.core.commands.ExecutionEvent event) throws org.eclipse.core.commands.ExecutionException
Refresh the dirty state of theCDOWorkspace
.- Parameters:
event
- the event- Throws:
org.eclipse.core.commands.ExecutionException
- if refresh fails
-
-