Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

oracle.ide.db.dialogs
Interface DBEditorFactory

All Known Implementing Classes:
BaseDBEditorFactory

public interface DBEditorFactory

A DBEditorFactory is responsible for creating and editing Database Objects in a DBObjectProvider.

Since:
11.0

Method Summary
 boolean canCreateDBObject(DBObjectTypeNode node)
          Whether this DBEditorFactory will be able to create a new database object under the given node.
 boolean canCreateDBObject(Schema schema, DBObjectProvider pro, java.lang.String dbObjectType)
          Whether this DBEditorFactory will be able to create a new dabtabase object of a specific type in a specific context.
 boolean canEditDBObject(DBObject obj, DBObjectProvider pro)
          Whether this DBEditorFactory will be able to edit an existing provider object of a specific type in a specific context.
 boolean canEditDBObject(DBObjectNode node)
          Deprecated. No longer needed. This check is done automatically if you use DBEditorFactoryRegistry.getEditFactory(DBObjectNode).
 boolean canEditDBObject(SchemaObject obj, DBObjectProvider pro)
           
 boolean createDBObject(DBObject newObj, DBObjectProvider pro)
          Deprecated. use launchDialog(DBEditorConfig)
 boolean createDBObject(DBObject newObj, DBObjectProvider pro, boolean commitToProvider)
          Deprecated. use launchDialog(DBEditorConfig)
 DBObject createDBObject(DBObjectNode node, java.lang.String dbObjectType)
          Deprecated. use launchDialog(DBEditorConfig)
<T extends DBObject>
T
createDBObject(DBObjectProvider pro, T template, DBObject parent, boolean commitToProvider)
          Deprecated. use launchDialog(DBEditorConfig)
 SchemaObject createDBObject(DBObjectTypeNode node)
          Deprecated. use launchDialog(DBEditorConfig)
 SchemaObject createDBObject(Schema schema, DBObjectProvider pro, java.lang.String dbObjectType)
          Deprecated. use launchDialog(DBEditorConfig)
 DBObject createDBObject(Schema schema, DBObjectProvider pro, java.lang.String dbObjectType, DBObject parent, boolean commitToProvider)
          Deprecated. use launchDialog(DBEditorConfig)
<T extends SystemObject>
T
createDBObject(Schema schema, DBObjectProvider pro, T template, boolean commitToProvider)
          Deprecated. use launchDialog(DBEditorConfig)
 boolean editDBObject(DBObject obj, DBObjectProvider pro)
          Deprecated. use launchDialog(DBEditorConfig)
 boolean editDBObject(DBObject obj, DBObjectProvider pro, boolean commitToProvider)
          Deprecated. use launchDialog(DBEditorConfig)
 boolean editDBObject(DBObject obj, DBObjectProvider pro, DBObject child)
          Deprecated. use launchDialog(DBEditorConfig)
 boolean editDBObject(DBObject obj, DBObjectProvider pro, DBObject child, boolean commitToProvider)
          Deprecated. use launchDialog(DBEditorConfig)
 boolean editDBObject(DBObjectNode node)
          Edits and existing database object in a provider.
 boolean editDBObject(SchemaObject obj, DBObjectProvider pro)
          Deprecated. use launchDialog(DBEditorConfig)
 java.lang.String getCreateLabel(java.lang.String dbObjectType)
          Retrieves the menu label for creating new objects of the specified type.
 boolean isCreateSupported(java.lang.String dbObjectType)
          Whether this DBEditorFactory supports the creation of objects of the specified type.
 void launchDialog(DBEditorConfig config)
          Launches a create or edit dialog appropriate to the given DBEditorConfig.
 java.lang.String[] listSupportedTypes()
          Lists all the types that create/edit is supported for.
 

Method Detail

isCreateSupported

boolean isCreateSupported(java.lang.String dbObjectType)
Whether this DBEditorFactory supports the creation of objects of the specified type. This is primarily used to determine whether a context menu item should be added for the type; the menu may or may not be enabled depending on whether the factory can create objects in a particular context.

Parameters:
dbObjectType - the type of object
Returns:
whether the 'New' menu item should be added
See Also:
DBObject.getType()

listSupportedTypes

java.lang.String[] listSupportedTypes()
Lists all the types that create/edit is supported for.

Returns:
an array of the types edit dialogs are available for.
See Also:
DBObject.getType()

getCreateLabel

java.lang.String getCreateLabel(java.lang.String dbObjectType)
Retrieves the menu label for creating new objects of the specified type.

Parameters:
dbObjectType - the type of object
Returns:
the menu label
See Also:
DBObject.getType()

canCreateDBObject

boolean canCreateDBObject(Schema schema,
                          DBObjectProvider pro,
                          java.lang.String dbObjectType)
Whether this DBEditorFactory will be able to create a new dabtabase object of a specific type in a specific context.

Parameters:
schema - The schema to create the object in
pro - The DBObjectProvider instance to create the object in
dbObjectType - The type of database object to create
See Also:
DBObjectProvider, DBObject.getType()

canCreateDBObject

boolean canCreateDBObject(DBObjectTypeNode node)
Whether this DBEditorFactory will be able to create a new database object under the given node.


canEditDBObject

boolean canEditDBObject(DBObject obj,
                        DBObjectProvider pro)
Whether this DBEditorFactory will be able to edit an existing provider object of a specific type in a specific context.

Parameters:
obj - The SchemaObject to be edited
pro - The DBObjectProvider instance to create the object in
child - a specific child object to edit

canEditDBObject

boolean canEditDBObject(SchemaObject obj,
                        DBObjectProvider pro)
See Also:
canEditDBObject(DBObject,DBObjectProvider)

canEditDBObject

@Deprecated
boolean canEditDBObject(DBObjectNode node)
Deprecated. No longer needed. This check is done automatically if you use DBEditorFactoryRegistry.getEditFactory(DBObjectNode).


launchDialog

void launchDialog(DBEditorConfig config)
Launches a create or edit dialog appropriate to the given DBEditorConfig. To be notified of the completion of the dialog, add a listener to the config.

Parameters:
config - the configuration for launching the dialog

createDBObject

@Deprecated
SchemaObject createDBObject(Schema schema,
                                       DBObjectProvider pro,
                                       java.lang.String dbObjectType)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new database object of a specific type in the given schema and provider.

Parameters:
schema - The schema to create the object in
pro - The DBObjectProvider instance to create the object in
dbObjectType - The type of database object to create
Returns:
the new object if it was successfully created
See Also:
DBObjectProvider, DBObject.getType()

createDBObject

@Deprecated
SchemaObject createDBObject(DBObjectTypeNode node)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new database object. The type, schema and provider are all taken from the given node.

Parameters:
node - the node describing the schema, type and provider
Returns:
the new object if it was successfully created

createDBObject

@Deprecated
DBObject createDBObject(Schema schema,
                                   DBObjectProvider pro,
                                   java.lang.String dbObjectType,
                                   DBObject parent,
                                   boolean commitToProvider)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new database object of a specific type in the given schema and provider using the given parent object.

Parameters:
schema - The schema to create the object in
pro - The DBObjectProvider instance to create the object in
dbObjectType - The type of database object to create
parent - the owning object of the object to be created (e.g. Table for a new Index)
commitToProvider - whether the dialog should commit the change back to the DBObjectProvider as well as the parent object. This allows a dialog to be fired from within another editor context (e.g. the modeler) and the edit absorbed into the edit of the parent (e.g. editing a Table, create a new Index as part of the edit and commit the whole lot together later).
Returns:
the new object if it was successfully created
See Also:
DBObjectProvider, DBObject.getType()

createDBObject

@Deprecated
<T extends SystemObject> T createDBObject(Schema schema,
                                                     DBObjectProvider pro,
                                                     T template,
                                                     boolean commitToProvider)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new database object using the given object as a template in the given schema and provider using the given parent object.

Parameters:
schema - The schema to create the object in
pro - The DBObjectProvider instance to create the object in
template - An object to use as a template for the new object
commitToProvider - whether the dialog should commit the change back to the DBObjectProvider as well as the parent object. This allows a dialog to be fired from within another editor context (e.g. the modeler) and the edit absorbed into the edit of the parent (e.g. editing a Table, create a new Index as part of the edit and commit the whole lot together later).
Returns:
the new object if it was successfully created
See Also:
DBObjectProvider, DBObject.getType()

createDBObject

@Deprecated
<T extends DBObject> T createDBObject(DBObjectProvider pro,
                                                 T template,
                                                 DBObject parent,
                                                 boolean commitToProvider)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new database object using the given template.

Parameters:
pro - The DBObjectProvider instance to create the object in
template - the template for the new object
parent - the owning object of the object to be created (e.g. Table for a new Index)
commitToProvider - whether the dialog should commit the change back to the DBObjectProvider as well as the parent object. This allows a dialog to be fired from within another editor context (e.g. the modeler) and the edit absorbed into the edit of the parent (e.g. editing a Table, create a new Index as part of the edit and commit the whole lot together later).
Returns:
the new object if it was successfully created
See Also:
DBObjectProvider, DBObject.getType()

createDBObject

@Deprecated
DBObject createDBObject(DBObjectNode node,
                                   java.lang.String dbObjectType)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new database object of given type using the given node's object as a parent. So, for example, if the node is a Table node and dbObjectType is Index.TYPE this will fire the new Index dialog using the Table as a base.

Parameters:
node - the node for the parent object
dbObjectType - the type of child object to be created
Returns:
the newly object if it was successfully created

createDBObject

@Deprecated
boolean createDBObject(DBObject newObj,
                                  DBObjectProvider pro)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new schema object using the given starting object in the given provider.

Parameters:
newObj - the new object being created
pro - The DBObjectProvider instance to create the object in
Returns:
whether the object was sucessfully created.
See Also:
DBObjectProvider

createDBObject

@Deprecated
boolean createDBObject(DBObject newObj,
                                  DBObjectProvider pro,
                                  boolean commitToProvider)
Deprecated. use launchDialog(DBEditorConfig)

Creates a new schema object using the given starting object in the given provider.

Parameters:
newObj - the new object being created
pro - The DBObjectProvider instance to create the object in
commitToProvider - whether the dialog should commit the change back to the DBObjectProvider as well as the parent object. This allows a dialog to be fired from within another editor context (e.g. the modeler) and the edit absorbed into the edit of the parent (e.g. editing a Table, create a new Index as part of the edit and commit the whole lot together later).
Returns:
whether the object was sucessfully created.
See Also:
DBObjectProvider

editDBObject

@Deprecated
boolean editDBObject(DBObject obj,
                                DBObjectProvider pro)
Deprecated. use launchDialog(DBEditorConfig)

Edits an existing database object in a provider.

Parameters:
obj - The SchemaObject to be edited
pro - The DBObjectProvider instance to create the object in
Returns:
whether the object was sucessfully edited.

editDBObject

@Deprecated
boolean editDBObject(SchemaObject obj,
                                DBObjectProvider pro)
Deprecated. use launchDialog(DBEditorConfig)

See Also:
editDBObject(DBObject,DBObjectProvider)

editDBObject

@Deprecated
boolean editDBObject(DBObject obj,
                                DBObjectProvider pro,
                                boolean commitToProvider)
Deprecated. use launchDialog(DBEditorConfig)

Edits an existing database object in a provider.

Parameters:
obj - The SchemaObject to be edited
pro - The DBObjectProvider instance to create the object in
commitToProvider - whether the dialog should commit the change back to the DBObjectProvider as well as the parent object. This allows a dialog to be fired from within another editor context (e.g. the modeler) and the edit absorbed into the edit of the parent (e.g. editing a Table, edit an Index as part of the table edit and commit the whole lot together later).
Returns:
whether the object was sucessfully edited.

editDBObject

@Deprecated
boolean editDBObject(DBObject obj,
                                DBObjectProvider pro,
                                DBObject child)
Deprecated. use launchDialog(DBEditorConfig)

Edits an existing database object in a provider.

Parameters:
obj - The SchemaObject to be edited
pro - The DBObjectProvider instance to create the object in
child - a specific child object to edit
Returns:
whether the object was sucessfully edited.

editDBObject

boolean editDBObject(DBObjectNode node)
Edits and existing database object in a provider. The object to edit is represented by the given node.

Parameters:
node - the node representing the object to edit.
Returns:
whether the object was sucessfully edited.
See Also:
#launchDialog(DBEditorConfig)}

editDBObject

@Deprecated
boolean editDBObject(DBObject obj,
                                DBObjectProvider pro,
                                DBObject child,
                                boolean commitToProvider)
Deprecated. use launchDialog(DBEditorConfig)

Edits an existing database object in a provider.

Parameters:
obj - The SchemaObject to be edited
pro - The DBObjectProvider instance to create the object in
child - a specific child object to edit
commitToProvider - whether the dialog should commit the change back to the DBObjectProvider as well as the parent object. This allows a dialog to be fired from within another editor context (e.g. the modeler) and the edit absorbed into the edit of the parent (e.g. editing a Table, edit an Index as part of the table edit and commit the whole lot together later).
Returns:
whether the object was sucessfully edited.

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

Copyright © 1997, 2011, Oracle. All rights reserved.