vocleditor.editor
Class AbstractEditorPage

java.lang.Object
  extended by org.eclipse.ui.part.WorkbenchPart
      extended by org.eclipse.ui.part.EditorPart
          extended by vocleditor.editor.AbstractEditorPage
All Implemented Interfaces:
org.eclipse.core.runtime.IAdaptable, org.eclipse.core.runtime.IExecutableExtension, org.eclipse.ui.IEditorPart, org.eclipse.ui.ISaveablePart, org.eclipse.ui.IWorkbenchPart, org.eclipse.ui.IWorkbenchPart2, org.eclipse.ui.part.IWorkbenchPartOrientation
Direct Known Subclasses:
VOCLPage

public abstract class AbstractEditorPage
extends org.eclipse.ui.part.EditorPart

An abstract base class for all editor pages used in the VOCLEditor.

It provides basic support for typical GEF handling like CommandStacks, GraphicalViewers, a Palette and so on.


Field Summary
 
Fields inherited from interface org.eclipse.ui.IEditorPart
PROP_DIRTY, PROP_INPUT
 
Fields inherited from interface org.eclipse.ui.IWorkbenchPart
PROP_TITLE
 
Constructor Summary
AbstractEditorPage(VOCLEditor parent, org.eclipse.gef.EditDomain domain)
          Creates a new AbstractEditorPage instance.
 
Method Summary
 void createPartControl(org.eclipse.swt.widgets.Composite parent)
           
 void doSave(org.eclipse.core.runtime.IProgressMonitor monitor)
           
 void doSaveAs()
           
 org.eclipse.gef.EditDomain getEditDomain()
          Returns the edit domain this editor page uses.
 void gotoMarker(org.eclipse.core.resources.IMarker marker)
           
 void init(org.eclipse.ui.IEditorSite site, org.eclipse.ui.IEditorInput input)
           
 boolean isDirty()
           
 boolean isSaveAsAllowed()
           
 void setFocus()
           
 
Methods inherited from class org.eclipse.ui.part.EditorPart
getEditorInput, getEditorSite, getTitleToolTip, isSaveOnCloseNeeded, setInitializationData
 
Methods inherited from class org.eclipse.ui.part.WorkbenchPart
addPropertyListener, dispose, getAdapter, getContentDescription, getOrientation, getPartName, getSite, getTitle, getTitleImage, removePropertyListener, showBusy
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.ui.IWorkbenchPart
addPropertyListener, dispose, getSite, getTitle, getTitleImage, removePropertyListener
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 

Constructor Detail

AbstractEditorPage

public AbstractEditorPage(VOCLEditor parent,
                          org.eclipse.gef.EditDomain domain)
Creates a new AbstractEditorPage instance.

Parameters:
parent - the parent multi page editor
domain - the edit domain
Method Detail

doSave

public final void doSave(org.eclipse.core.runtime.IProgressMonitor monitor)
Specified by:
doSave in interface org.eclipse.ui.ISaveablePart
Specified by:
doSave in class org.eclipse.ui.part.EditorPart
See Also:
ISaveablePart.doSave(org.eclipse.core.runtime.IProgressMonitor)

doSaveAs

public final void doSaveAs()
Specified by:
doSaveAs in interface org.eclipse.ui.ISaveablePart
Specified by:
doSaveAs in class org.eclipse.ui.part.EditorPart
See Also:
ISaveablePart.doSaveAs()

gotoMarker

public void gotoMarker(org.eclipse.core.resources.IMarker marker)
See Also:
org.eclipse.ui.IEditorPart#gotoMarker(org.eclipse.core.resources.IMarker)

init

public void init(org.eclipse.ui.IEditorSite site,
                 org.eclipse.ui.IEditorInput input)
          throws org.eclipse.ui.PartInitException
Specified by:
init in interface org.eclipse.ui.IEditorPart
Specified by:
init in class org.eclipse.ui.part.EditorPart
Throws:
org.eclipse.ui.PartInitException
See Also:
IEditorPart.init(org.eclipse.ui.IEditorSite, org.eclipse.ui.IEditorInput)

isDirty

public final boolean isDirty()
Specified by:
isDirty in interface org.eclipse.ui.ISaveablePart
Specified by:
isDirty in class org.eclipse.ui.part.EditorPart
See Also:
ISaveablePart.isDirty()

isSaveAsAllowed

public final boolean isSaveAsAllowed()
Specified by:
isSaveAsAllowed in interface org.eclipse.ui.ISaveablePart
Specified by:
isSaveAsAllowed in class org.eclipse.ui.part.EditorPart
See Also:
ISaveablePart.isSaveAsAllowed()

setFocus

public void setFocus()
Specified by:
setFocus in interface org.eclipse.ui.IWorkbenchPart
Specified by:
setFocus in class org.eclipse.ui.part.WorkbenchPart
See Also:
IWorkbenchPart.setFocus()

createPartControl

public final void createPartControl(org.eclipse.swt.widgets.Composite parent)
Specified by:
createPartControl in interface org.eclipse.ui.IWorkbenchPart
Specified by:
createPartControl in class org.eclipse.ui.part.WorkbenchPart
See Also:
IWorkbenchPart.createPartControl(org.eclipse.swt.widgets.Composite)

getEditDomain

public final org.eclipse.gef.EditDomain getEditDomain()
Returns the edit domain this editor page uses.

Returns:
the edit domain this editor page uses