|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.datatools.sqltools.schemaobjecteditor.ui.util.SchemaObjectEditorUtils
public class SchemaObjectEditorUtils
Contains some static utility methods for schama object editor.
Constructor Summary | |
---|---|
SchemaObjectEditorUtils()
|
Method Summary | |
---|---|
static void |
expandNode(SQLObject obj)
Expand the tree node and reveal the editing object after refresh For editor, we do not know the status of the tree in the DSE when editing, so we have to expand every node on the path from the root to the editing object. |
static org.eclipse.swt.widgets.TreeItem |
findAndExpandObjectNode(org.eclipse.swt.widgets.TreeItem item,
SQLObject obj,
org.eclipse.ui.navigator.CommonViewer viewer)
|
static org.eclipse.swt.widgets.TreeItem |
findAndExpandVirtualNode(org.eclipse.swt.widgets.TreeItem item,
java.lang.String NodeType,
org.eclipse.ui.navigator.CommonViewer viewer)
|
static IEditorDescriptor |
getEditorById(java.lang.String editorId)
Returns the editor given the editor id, there may be several editors with the same id, we always return the first one |
static IEditorDescriptor |
getEditorByObjectType(java.lang.String dbName,
java.lang.String dbVersion,
org.eclipse.emf.ecore.EClass objectType)
Returns the editor instance containing extension information given the database object of the given database type. |
static IEditorDescriptor[] |
getEditorsByName(java.lang.String editorName)
Returns the editors of the given name |
static IEditorDescriptor[] |
getEditorsByVendorName(java.lang.String vendorName)
Returns the editors for the given database |
static java.util.Map |
getEditorsCatalogedByDBDefinition()
Returns all the defined editors, cataloged by db definition |
static org.eclipse.ui.IEditorPart |
openEditor(java.lang.String editorId,
ISchemaObjectEditModel modelObject,
org.eclipse.datatools.sqltools.core.DatabaseIdentifier databaseIdentifier)
Opens the editor given the editor id |
static org.eclipse.ui.IEditorPart |
openEditor(java.lang.String dbName,
java.lang.String dbVersion,
java.lang.String objectTypeId,
ISchemaObjectEditModel modelObject,
org.eclipse.datatools.sqltools.core.DatabaseIdentifier databaseIdentifier)
Opens the editor for the given database object of the given database type. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SchemaObjectEditorUtils()
Method Detail |
---|
public static org.eclipse.ui.IEditorPart openEditor(java.lang.String dbName, java.lang.String dbVersion, java.lang.String objectTypeId, ISchemaObjectEditModel modelObject, org.eclipse.datatools.sqltools.core.DatabaseIdentifier databaseIdentifier)
dbName
- the name of the databasedbVersion
- the version of the databaseobjectTypeId
- the id of the database object
IEditorPart
instance if succeeded, null
otherwisepublic static org.eclipse.ui.IEditorPart openEditor(java.lang.String editorId, ISchemaObjectEditModel modelObject, org.eclipse.datatools.sqltools.core.DatabaseIdentifier databaseIdentifier)
editorId
- the id of the editormodelObject
- the modeldatabaseIdentifier
-
public static IEditorDescriptor getEditorByObjectType(java.lang.String dbName, java.lang.String dbVersion, org.eclipse.emf.ecore.EClass objectType)
dbName
- the database namedbVersion
- the database versionobjectType
- the database object type to be edit
null
if
the extension can not be foundpublic static IEditorDescriptor getEditorById(java.lang.String editorId)
editorId
-
public static IEditorDescriptor[] getEditorsByName(java.lang.String editorName)
editorName
-
public static IEditorDescriptor[] getEditorsByVendorName(java.lang.String vendorName)
vendorName
-
public static java.util.Map getEditorsCatalogedByDBDefinition()
public static void expandNode(SQLObject obj)
public static org.eclipse.swt.widgets.TreeItem findAndExpandVirtualNode(org.eclipse.swt.widgets.TreeItem item, java.lang.String NodeType, org.eclipse.ui.navigator.CommonViewer viewer)
public static org.eclipse.swt.widgets.TreeItem findAndExpandObjectNode(org.eclipse.swt.widgets.TreeItem item, SQLObject obj, org.eclipse.ui.navigator.CommonViewer viewer)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |