|
SWT LPEX v3.0.5 |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.ui.part.WorkbenchPart
org.eclipse.ui.part.EditorPart
com.ibm.lpex.alef.LpexAbstractTextEditor
com.ibm.lpex.alef.LpexStatusTextEditor
A line-oriented, LPEX-based version of StatusTextEditor. A status text editor is capable of handling input elements that have an associated status.
Field Summary |
---|
Fields inherited from class com.ibm.lpex.alef.LpexAbstractTextEditor |
---|
ACTION_MAP, DEFAULT_EDITOR_CONTEXT_MENU_ID, DEFAULT_RULER_CONTEXT_MENU_ID, fErrorLabel, VERTICAL_RULER_WIDTH |
Fields inherited from interface org.eclipse.ui.IEditorPart |
---|
PROP_DIRTY, PROP_INPUT |
Fields inherited from interface org.eclipse.ui.IWorkbenchPart |
---|
PROP_TITLE |
Constructor Summary | |
---|---|
LpexStatusTextEditor()
|
Method Summary | |
---|---|
void |
createPartControl(Composite parent)
Creates the SWT controls for this workbench part. |
protected Control |
createStatusControl(Composite parent,
IStatus status)
Creates the status control for the given status. |
void |
doRevertToSaved()
Abandons all modifications applied to the editor's input element's textual presentation since the last save operation. |
protected void |
doSetInput(IEditorInput input)
Internal processing of setting/changing the input to this editor. |
protected String |
getStatusBanner(IStatus status)
Returns a banner for the given status. |
protected String |
getStatusHeader(IStatus status)
Returns a header for the given status. |
protected String |
getStatusMessage(IStatus status)
Returns a message for the given status. |
protected boolean |
isErrorStatus(IStatus status)
Returns whether the given status indicates an error. |
protected void |
sanityCheckState(IEditorInput input)
Checks the state of the given editor input. |
void |
updatePartControl(IEditorInput input)
Checks whether the status of the given input is OK. |
protected void |
updateStatusField(String category)
Updates the Eclipse status field for the given category. |
Methods inherited from class org.eclipse.ui.part.EditorPart |
---|
getEditorInput, getEditorSite, getTitleToolTip, setContentDescription, setInitializationData, setPartName |
Methods inherited from class org.eclipse.ui.part.WorkbenchPart |
---|
addPropertyListener, getConfigurationElement, getContentDescription, getDefaultImage, getPartName, getSite, getTitle, getTitleImage, removePropertyListener, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eclipse.ui.IEditorPart |
---|
getEditorInput, getEditorSite |
Methods inherited from interface org.eclipse.ui.IWorkbenchPart |
---|
addPropertyListener, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener |
Constructor Detail |
public LpexStatusTextEditor()
Method Detail |
public void createPartControl(Composite parent)
For implementors, this is a multi-step process: 1. Create one or more controls within the parent; 2. Set the parent layout as needed; 3. Register any global actions with the IActionService; 4. Register any popup menus with the IActionService; 5. Register a selection provider with the ISelectionService (optional).
createPartControl
in interface IWorkbenchPart
createPartControl
in class LpexAbstractTextEditor
parent
- the parent controlIWorkbenchPart.createPartControl(org.eclipse.swt.widgets.Composite)
public void updatePartControl(IEditorInput input)
input
- the editor input whose status is checkedprotected boolean isErrorStatus(IStatus status)
status
- the status to be checked
true
if the status indicates an error, or false
otherwiseprotected Control createStatusControl(Composite parent, IStatus status)
parent
- the parent controlstatus
- the status
protected String getStatusHeader(IStatus status)
status
- the status whose message is returned
protected String getStatusBanner(IStatus status)
status
- the status whose message is returned
protected String getStatusMessage(IStatus status)
status
- the status whose message is returned
protected void updateStatusField(String category)
LpexAbstractTextEditor
updateStatusField
in class LpexAbstractTextEditor
category
- the status categoryprotected void doSetInput(IEditorInput input) throws CoreException
LpexAbstractTextEditor
This method does the actual setting of the editor input. It closes the editor
if input
is null
. It disconnects from any previous
editor input and its document provider, and connects to the new one.
Subclasses may extend.
doSetInput
in class LpexAbstractTextEditor
input
- the (new) input to be set;
if null
, this text editor is being closed
CoreException
- if the input cannot be connected to the document
provider (i.e., it is not understood by this part)public void doRevertToSaved()
LpexAbstractTextEditor
The implementation of this ITextEditor
method may be
extended by subclasses.
doRevertToSaved
in interface ITextEditor
doRevertToSaved
in class LpexAbstractTextEditor
ITextEditor.doRevertToSaved()
protected void sanityCheckState(IEditorInput input)
LpexAbstractTextEditor
sanityCheckState
in class LpexAbstractTextEditor
input
- the editor input whose state is to be checked
|
SWT LPEX v3.0.5 |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |