public class DatabaseEditor extends PropEditorPart implements ISaveableEditor, org.eclipse.datatools.sqltools.sqlbuilder.IContentChangeListener, org.eclipse.datatools.sqltools.sqlbuilder.IExecuteSQLListener
PropEditorPart.DragSourceDelegator
Modifier and Type | Field and Description |
---|---|
static String |
ID
The Part ID.
|
appUI, copyAction, copyFullPathAction, copyReferenceAction, cutAction, deleteAction, dslPaste, editedPropCnr, EMPTY, filePropCnr, fileResource, globalActionBars, ir, linkAction, moveAction, partSelection, pasteAction, pasteAfterAction, pasteBeforeAction, pasteLinkAction, printAction, propEventListener, redoAction, renameAction, restoreMemento, revertAction, rootPropCnr, saveAction, selectAllAction, selectionEnabler, tiPaste, toolBar, toolBar2, undoAction, updateSelectionAndStatesRunner
PROP_TITLE
PROP_DIRTY, PROP_INPUT
Constructor and Description |
---|
DatabaseEditor()
Eclipse constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
createEditorComposite(Composite parent)
Creates the Editor Main Composite.
|
void |
dispose()
Called to dispose.
|
boolean |
doOpen(GProp<?>[] props)
Opens the property by selecting it in focus.
|
boolean |
doOpen(GProp<?> prop,
int index,
String childName)
Opens the property by selecting it in focus.
|
void |
executedSQL()
Called when SQL has been executed in SQL Builder.
|
org.eclipse.datatools.sqltools.sqlbuilder.actions.SQLBuilderActionBarContributor |
getActionBarContributor()
Gets the action bar contributor.
|
<T> T |
getAdapter(Class<T> key)
Checks for outline page match (IContentOutlinePage), handled by SQLBuilder.
|
EditorDatabaseProps |
getDatabaseProps()
Gets the database properties.
|
CustomSQLBuilder |
getSQLBuilder()
Gets the instance of the SQL Builder.
|
protected void |
initEditor(PropCnr cnr)
The initialize editor method.
|
boolean |
isAdditionalDataDirty()
Checks the dirty state of additional data.
|
void |
notifyContentChange()
Notifies that content changed from SQLBuilder, called from the SWT thread.
|
void |
onClose()
Called when the part is being closed but is not yet disposed but hidden.
|
void |
onSetFocus()
Sets focus to this part.
|
protected void |
performPrint()
Performs Print.
|
protected void |
restoreMemento()
Restores this editor's state using the given memento.
|
void |
saveAdditionalData(IProgressMonitor monitor)
Saves the additional data.
|
protected void |
saveStateImpl(IMemento memento)
Saves the state of the object in the given memento.
|
protected void |
selectionChangedEx(SelectionChangedEvent event)
Selection changes in the tree.
|
void |
setActionBarContributor(CustomSQLBuilderActionBarContributor contributor)
Sets the action contributor associated with this editor.
|
protected void |
updateStatesEx()
Update states.
|
addForDisposalAtDispose, addListener, addOpenFile, addSelectionChangedListener, addToolbar2PushButton, addToolbar2PushButton, addToolbar2Separator, addToolbarPushButton, addToolbarPushButton, addToolbarPushButton, addToolbarPushButton, addToolbarPushButton, addToolbarPushButton, addToolbarPushButton, addToolbarSeparator, addToolbarSeparator, closeFile, createCommonViewer, createEmptyNavigationLocation, createFilteredCommonViewer, createFilteredCommonViewer, createLicenseExceptionComposite, createMenu, createMenu, createNavigationLocation, createPartControl, doSave, doSaveAs, fireSelectionAndStates, getActiveEditor, getActiveEditor, getActivePart, getActiveSaveables, getCurrentTreeViewer, getEditors, getExtension, getLicenseException, getModuleModel, getMultiSelectionProvider, getPartComposite, getPartName, getRedoAction, getSaveables, getSelection, getSelectionEnabler, getShell, getSyntClipboardSelection, getTargetViewer, getTitleImage, getTitleToolTip, getTitleToolTip, getTopmostEditor, getUndoAction, getUndoContext, getUndoRedo, gotoMarker, hasInitError, init, invalidLicense, isDirty, isDisposed, isDragging, isSaveAsAllowed, isSaveOnCloseNeeded, onActivated, onCloseProject, onComponentFocus, onDragBegin, onDragEnd, onEditedPropertyChangedForVerify, onEditorActivated, onEditorReady, onFileClosed, onPartRenamed, onUpdateStates, performCollapseAll, performCopy, performCopyFullPath, performCopyReference, performCut, performDelete, performExpandAll, performLink, performMove, performPaste, performPasteAfter, performPasteBefore, performPasteLink, performRedo, performRename, performRevert, performSave, performSelectAll, performUndo, postAsyncUpdateStates, proceedInit, proceedInitProperty, refreshViewers, registerFormControl, registerViewer, registerViewer, removeListener, removePropertyValue, removeSelectionChangedListener, restoreState, saveState, selectionChanged, setActionsUndoContext, setBlockViewerFocus, setFocus, setFocus, setInput, setPropertyAttrFlag, setPropertyError, setPropertyValue, setSelection, setTargetViewer, supportsCopyFullPath, supportsCopyReference, updateAllStates, updateStates, updateStatesPasteBeforeAfter, updateTitle, usePasteBeforeAfter, verifyDirtyStateChanged
checkSite, getEditorInput, getEditorSite, setContentDescription, setInitializationData, setInputWithNotify, setPartName
addPartPropertyListener, addPropertyListener, firePartPropertyChanged, firePropertyChange, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
onComponentFocused
addPropertyListener, getSite, getTitle, removePropertyListener
public static final String ID
protected void initEditor(PropCnr cnr) throws PartInitException
Subclasses may override this method.
initEditor
in class PropEditorPart
cnr
- The property container being edited. Note: the real name of the
property is in the parent FilePropCnr Atom.PartInitException
- For initialization failures.public org.eclipse.datatools.sqltools.sqlbuilder.actions.SQLBuilderActionBarContributor getActionBarContributor()
public void setActionBarContributor(CustomSQLBuilderActionBarContributor contributor)
contributor
- Assigns the contributor.public CustomSQLBuilder getSQLBuilder()
public EditorDatabaseProps getDatabaseProps()
public void onClose()
onClose
in interface IActivationListener
onClose
in class PropEditorPart
public void dispose()
dispose
in interface IWorkbenchPart
dispose
in class PropEditorPart
protected void restoreMemento()
restoreMemento
in class PropEditorPart
protected void saveStateImpl(IMemento memento)
saveStateImpl
in class PropEditorPart
memento
- The storage area for object's state.public boolean isAdditionalDataDirty()
isAdditionalDataDirty
in interface ISaveableEditor
public void saveAdditionalData(IProgressMonitor monitor)
saveAdditionalData
in interface ISaveableEditor
monitor
- The progress monitor.public void notifyContentChange()
notifyContentChange
in interface org.eclipse.datatools.sqltools.sqlbuilder.IContentChangeListener
public <T> T getAdapter(Class<T> key)
getAdapter
in interface IAdaptable
getAdapter
in class PropEditorPart
protected void createEditorComposite(Composite parent)
createEditorComposite
in class PropEditorPart
parent
- The empty parent composite without initialized layout, with the
widget background color.public void onSetFocus()
onSetFocus
in class PropEditorPart
protected void selectionChangedEx(SelectionChangedEvent event)
selectionChangedEx
in class PropEditorPart
protected void updateStatesEx()
updateStatesEx
in class PropEditorPart
public boolean doOpen(GProp<?>[] props)
doOpen
in class PropEditorPart
public boolean doOpen(GProp<?> prop, int index, String childName)
doOpen
in class PropEditorPart
prop
- The property to focus.index
- The index in a multi-property.childName
- The child property name or null.protected void performPrint()
performPrint
in class PropEditorPart
public void executedSQL()
executedSQL
in interface org.eclipse.datatools.sqltools.sqlbuilder.IExecuteSQLListener
iizi® is a registered trademark of Mindus SARL. © Copyright Mindus SARL, 2020. All rights reserved.