|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.7.2) E13403-10 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.ide.db.model.DBObjectNodeUtil
public final class DBObjectNodeUtil
Utility methods for dealing with DBObjectNode instances. The various methods can make the job of handling DnD of nodes easier by providing quick test methods to see if the object in question is a valid node that matches a given object type. Specific tests are also provided for Relations as they could be objects of a number of types.
Method Summary | ||
---|---|---|
static java.lang.String |
decode(java.lang.String name, boolean store) Decodes the given String to get out the connection name (or alternatively store name). |
|
static java.lang.String |
getConnectionName(java.lang.Object node) Returns the name of the connection if it is retrievable from the given object (node). |
|
static
|
getElementOfType(Element elem, java.lang.Class<T> clz) Tests the given element to see if it is of the given element class and returns it. |
|
static Schema |
getSchema(DBObjectTypeNode node, boolean defaultIfNone) Gets the schema for the given node. |
|
static
|
getSelectedElement(Context context, java.lang.Class<T> clz) Inspects the selection of the given context. |
|
static java.lang.String |
getStoreName(java.lang.Object node) Returns the name of the store if it is retrievable from the given object (node). |
|
static boolean |
isNodeOfType(java.lang.String type, java.lang.Object node) Returns true if the given object is a valid DBObjectNode that contains an object with the given type. |
|
static boolean |
isOnlineNode(java.lang.Object node) Returns true if the given object is a valid DBObjectNode that has come from a live (online) database connection. |
|
static boolean |
isOnlineNodeOfType(java.lang.String type, java.lang.Object node) Returns true if the given object is a valid DBObjectNode that contains an object with the given type AND that object has come from a live (online) database connection. |
|
static boolean |
isOnlineRelationNode(java.lang.Object node) Returns true if the given object is a valid DBObjectNode that contains a Relation object (i.e. |
|
static boolean |
isOnlineRelationNode(java.lang.Object node, boolean unwrapSynonym) Returns true if the given object is a valid DBObjectNode that contains a Relation object (i.e. |
|
static boolean |
isRelationNode(java.lang.Object node) Returns true if the given object is a valid DBObjectNode that contains a Relation object (i.e. |
|
static boolean |
isRelationNode(java.lang.Object node, boolean unwrapSynonym) Returns true if the given object is a valid DBObjectNode that contains a Relation object (i.e. |
|
static boolean |
isSynonymNode(java.lang.Object node) |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static boolean isNodeOfType(java.lang.String type, java.lang.Object node)
type
- the type of object we're looking fornode
- the node to test for the objectpublic static boolean isOnlineNodeOfType(java.lang.String type, java.lang.Object node)
type
- the type of object we're looking fornode
- the node to test for the objectpublic static boolean isOnlineNode(java.lang.Object node)
node
- the node to test for the objectpublic static boolean isRelationNode(java.lang.Object node)
node
- the node to test for a RelationisNodeOfType(java.lang.String, java.lang.Object)
public static boolean isRelationNode(java.lang.Object node, boolean unwrapSynonym)
node
- the node to test for a RelationunwrapSynonym
- resolve referenced object for SynonymsisNodeOfType(java.lang.String, java.lang.Object)
public static boolean isSynonymNode(java.lang.Object node)
public static boolean isOnlineRelationNode(java.lang.Object node)
node
- the node to test for a RelationisOnlineNodeOfType(java.lang.String, java.lang.Object)
public static boolean isOnlineRelationNode(java.lang.Object node, boolean unwrapSynonym)
node
- the node to test for a RelationunwrapSynonym
- resolve referenced object for SynonymsisOnlineNodeOfType(java.lang.String, java.lang.Object)
public static java.lang.String getStoreName(java.lang.Object node)
node
- the node to to checkDatabaseConnectionStores.getCurrentStore()
public static java.lang.String getConnectionName(java.lang.Object node)
node
- the node to to checkDatabaseConnectionStores.getCurrentConnection(oracle.ide.Context)
public static java.lang.String decode(java.lang.String name, boolean store)
name
- the string to decodestore
- if true, on decoding the string the store name is returned.public static <T extends Element> T getSelectedElement(Context context, java.lang.Class<T> clz)
context
- the context to look at the selection ofclz
- the class of Element to look forgetElementOfType(oracle.ide.model.Element, java.lang.Class<T>)
public static <T extends Element> T getElementOfType(Element elem, java.lang.Class<T> clz)
elem
- the element to testclz
- the class of Element to look forpublic static Schema getSchema(DBObjectTypeNode node, boolean defaultIfNone)
node
- the node to get the Schema fordefaultIfNone
- whether to default to the default schema if the node's schema cannot be determined
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.7.2) E13403-10 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |