public class WorkbenchService extends java.lang.Object implements IWorkbenchService
Constructor and Description |
---|
WorkbenchService() |
Modifier and Type | Method and Description |
---|---|
IWorkbenchWindow |
getActiveOrFirstWorkbenchWindow() |
IStatusLineManager |
getActiveStatusLineManager()
Method returns the current
StatusLineManager . |
Shell |
getShell()
Returns the shell of the active workbench window.
|
IDiagramContainer |
openDiagramEditor(Diagram diagram)
Opens the given diagram in the diagram editor.
|
IDiagramContainer |
openDiagramEditor(Diagram diagram,
java.lang.String providerId)
Opens the given diagram in the diagram editor.
|
IDiagramContainer |
openDiagramEditor(Diagram diagram,
java.lang.String providerId,
java.lang.String editorId)
Opens the given diagram in the diagram editor with the given id.
|
public IStatusLineManager getActiveStatusLineManager()
IWorkbenchService
StatusLineManager
. If no
StatusLineManager is available, a new StatusLineManager will be created
and returned. In most cases this will not have any effect and will not be
able to display status info, but it makes null pointer checks when
calling the method obsoletegetActiveStatusLineManager
in interface IWorkbenchService
public IWorkbenchWindow getActiveOrFirstWorkbenchWindow()
getActiveOrFirstWorkbenchWindow
in interface IWorkbenchService
public IDiagramContainer openDiagramEditor(Diagram diagram)
openDiagramEditor
in interface IWorkbenchService
diagram
- which should be openeddomain
- public IDiagramContainer openDiagramEditor(Diagram diagram, java.lang.String providerId)
openDiagramEditor
in interface IWorkbenchService
diagram
- which should be openeddomain
- providerId
- the unique provider id of a diagram type provider which will
be used by the editor.public IDiagramContainer openDiagramEditor(Diagram diagram, java.lang.String providerId, java.lang.String editorId)
openDiagramEditor
in interface IWorkbenchService
diagram
- which should be openeddomain
- providerId
- the unique provider id of a diagram type provider which will
be used by the editor.editorId
- the unique Eclipse editor id of the diagram editor to open.
This id must belong to a subclass of IDiagramContainerUI
.public Shell getShell()
IWorkbenchService
getShell
in interface IWorkbenchService