Package org.apache.uima.caseditor.editor
Class CasEditorView
java.lang.Object
org.eclipse.core.commands.common.EventManager
org.eclipse.ui.part.WorkbenchPart
org.eclipse.ui.part.ViewPart
org.eclipse.ui.part.PageBookView
org.apache.uima.caseditor.editor.CasEditorView
- All Implemented Interfaces:
org.eclipse.core.runtime.IAdaptable,org.eclipse.core.runtime.IExecutableExtension,org.eclipse.ui.IPartListener,org.eclipse.ui.IPersistable,org.eclipse.ui.IViewPart,org.eclipse.ui.IWorkbenchPart,org.eclipse.ui.IWorkbenchPart2,org.eclipse.ui.IWorkbenchPart3,org.eclipse.ui.part.IWorkbenchPartOrientation
- Direct Known Subclasses:
AnnotationStyleView,EditView,FeatureStructureBrowserView
public abstract class CasEditorView
extends org.eclipse.ui.part.PageBookView
Base class for views which show information about the
CAS opened in the editor.
The view page created with doCreatePage(ICasEditor) will be disposed and re-created on
every Cas Editor input change or CAS view change.
In the case the view should no be re-created on a CAS view change
isRecreatePageOnCASViewSwitch() must be overridden and return false.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.ui.part.PageBookView
org.eclipse.ui.part.PageBookView.PageRec, org.eclipse.ui.part.PageBookView.SelectionProvider -
Field Summary
Fields inherited from interface org.eclipse.ui.IWorkbenchPart
PROP_TITLE -
Constructor Summary
ConstructorsConstructorDescriptionCasEditorView(String editorNotAvailableMessage) Instantiates a new cas editor view. -
Method Summary
Modifier and TypeMethodDescriptionprotected org.eclipse.ui.part.IPagecreateDefaultPage(org.eclipse.ui.part.PageBook book) voiddispose()protected abstract org.eclipse.ui.part.IPageBookViewPagedoCreatePage(ICasEditor editor) Do create page.protected final org.eclipse.ui.part.PageBookView.PageRecdoCreatePage(org.eclipse.ui.IWorkbenchPart part) protected voiddoDestroyPage(org.eclipse.ui.IWorkbenchPart part, org.eclipse.ui.part.PageBookView.PageRec pageRecord) protected org.eclipse.ui.IWorkbenchPartprotected booleanisImportant(org.eclipse.ui.IWorkbenchPart part) protected booleanImplementors should overwrite if they want that.voidpartBroughtToTop(org.eclipse.ui.IWorkbenchPart part) Look atIPartListener.partBroughtToTop(IWorkbenchPart).Methods inherited from class org.eclipse.ui.part.PageBookView
createPartControl, doesPageExist, getAdapter, getCurrentContributingPart, getCurrentPage, getDefaultPage, getPageBook, getPageRec, getPageRec, getPageSite, getSelectionProvider, getViewAdapter, init, initPage, partActivated, partClosed, partDeactivated, partHidden, partOpened, partVisible, setFocus, showPageRecMethods inherited from class org.eclipse.ui.part.ViewPart
checkSite, getViewSite, init, saveState, setContentDescription, setInitializationData, setPartNameMethods inherited from class org.eclipse.ui.part.WorkbenchPart
addPartPropertyListener, addPropertyListener, firePartPropertyChanged, firePropertyChange, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, getTitleToolTip, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusyMethods inherited from class org.eclipse.core.commands.common.EventManager
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObjectMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.eclipse.ui.IWorkbenchPart
addPropertyListener, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener
-
Constructor Details
-
CasEditorView
Instantiates a new cas editor view.- Parameters:
editorNotAvailableMessage- the editor not available message
-
-
Method Details
-
isRecreatePageOnCASViewSwitch
protected boolean isRecreatePageOnCASViewSwitch()Implementors should overwrite if they want that. Default is false.Note:
The implementation uses the ICasDocumentListener.viewChanged event to recognize view changes. If the view implementation also listens for this event the view might already be disposed when the listener is called. It is therefore strongly recommended either to listen for the event and update the view or don't list for the event and rely on a page re-creation.- Returns:
- true if page should be disposed/re-created on CAS view change, or false if not.
-
createDefaultPage
protected org.eclipse.ui.part.IPage createDefaultPage(org.eclipse.ui.part.PageBook book) - Specified by:
createDefaultPagein classorg.eclipse.ui.part.PageBookView
-
doCreatePage
Do create page.- Parameters:
editor- the editor- Returns:
- the i page book view page
-
doCreatePage
protected final org.eclipse.ui.part.PageBookView.PageRec doCreatePage(org.eclipse.ui.IWorkbenchPart part) - Specified by:
doCreatePagein classorg.eclipse.ui.part.PageBookView
-
getBootstrapPart
protected org.eclipse.ui.IWorkbenchPart getBootstrapPart()- Specified by:
getBootstrapPartin classorg.eclipse.ui.part.PageBookView
-
doDestroyPage
protected void doDestroyPage(org.eclipse.ui.IWorkbenchPart part, org.eclipse.ui.part.PageBookView.PageRec pageRecord) - Specified by:
doDestroyPagein classorg.eclipse.ui.part.PageBookView
-
isImportant
protected boolean isImportant(org.eclipse.ui.IWorkbenchPart part) - Specified by:
isImportantin classorg.eclipse.ui.part.PageBookView
-
partBroughtToTop
public void partBroughtToTop(org.eclipse.ui.IWorkbenchPart part) Look atIPartListener.partBroughtToTop(IWorkbenchPart).- Specified by:
partBroughtToTopin interfaceorg.eclipse.ui.IPartListener- Overrides:
partBroughtToTopin classorg.eclipse.ui.part.PageBookView- Parameters:
part- the part
-
dispose
public void dispose()- Specified by:
disposein interfaceorg.eclipse.ui.IWorkbenchPart- Overrides:
disposein classorg.eclipse.ui.part.PageBookView
-