Oracle Fusion Middleware extensions for Seed Data Framework
11g Release 1 (11.1.2)

E22564-02

oracle.apps.fnd.applseed.rt.common.objects
Class SDViewNode

java.lang.Object
  extended by javax.swing.tree.DefaultMutableTreeNode
      extended by oracle.apps.fnd.applseed.rt.common.objects.SDViewNode
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, javax.swing.tree.MutableTreeNode, javax.swing.tree.TreeNode
Direct Known Subclasses:
SDExtractViewNode, SDInheritedViewNode, SDLoaderViewNode

public class SDViewNode
extends javax.swing.tree.DefaultMutableTreeNode

This class serves as a common infrastructure for both upload and extract. It encapsulates an ADF ViewObject and provides access to all the metadata contained within it. This class also takes care of interpreting the metadata in the context of applseed.

Since:
Drop 5
Version:
$Header: atgpf/applseed/src/java/oracle/apps/fnd/applseed/rt/common/objects/SDViewNode.java /main/80 2010/12/08 20:40:05 ksedlund Exp $
Author:
sjanarth
See Also:
Serialized Form

Field Summary
protected  java.util.List<SDViewNode> childNodes
           
protected static int dumpDepth
           
protected  java.util.List<java.lang.String[]> extRefList
           
protected  java.lang.Boolean isNodeTranslatable
           
protected  java.util.Set<oracle.jbo.AttributeDef> orderedPayloadAttrs
           
protected  java.util.List<java.lang.String> refVAList
           
 
Fields inherited from class javax.swing.tree.DefaultMutableTreeNode
allowsChildren, children, EMPTY_ENUMERATION, parent, userObject
 
Constructor Summary
SDViewNode(oracle.jbo.ViewObject viewObject, oracle.jbo.ApplicationModule appModule)
           
 
Method Summary
static boolean areDriverNodesSame(SDViewNode node1, SDViewNode node2)
          Checks for given two ViewNodes whether the driver is same or not
 void buildParentHierarchy()
          Special Method used for creating the parent hierarchy.
 void dumpNode()
           
 void dumpTree()
           
 boolean equals(java.lang.Object obj)
           
protected  oracle.jbo.ViewObject findOrCreateViewObject(oracle.jbo.server.ViewDefImpl def)
           
static SDViewNode findViewInstance(java.lang.String instanceName, oracle.jbo.ApplicationModule am)
          Finds the view object with the given instance name in the am
static SDViewNode findViewNode(oracle.jbo.ApplicationModule refAM, oracle.jbo.ViewObject refVO)
           
static SDViewNode findViewNodeByDBObject(oracle.jbo.ApplicationModule appModule, SDViewNode excludeNode, java.lang.String dBObject)
          find the view node which has the same DB Object as dBObject and is either a driver view node or is part of the hierarchy of a driver view node.
static SDViewNode findViewNodeByDef(oracle.jbo.ApplicationModule appModule, SDViewNode excludeNode, java.lang.String viewDef)
          find the view node which has the same view definition as viewDef and is either a driver view node or is part of the hierarchy of a driver view node
 java.util.Collection<SDCompositionUsage> getAllCompositionUsages()
           
 java.util.Collection<SDLOVUsage> getAllLOVUsages()
           
 java.util.List<Mapper> getAllMappers()
           
 java.util.Collection<SDReferenceUsage> getAllReferenceUsages()
           
 java.util.List<oracle.jbo.AttributeDef> getAltKeyAttributeList()
          Method returns list of invariant key attributes.
 java.util.List<java.lang.String> getAltKeyAttributeNames()
          Get the attribute names of the alternate key as a List of Strings.
 java.util.List<oracle.jbo.AttributeDef> getAltKeyAttributesWithoutEffDate()
          Get the list of AttributeDefs that make up the logical keys of the effective dated entity.
 oracle.jbo.ViewCriteria getAltKeyCriteria()
          Method returns a ViewCriteria.
 oracle.jbo.ApplicationModule getAM()
           
 SDViewNode getChildByDefName(java.lang.String defName)
           
 SDViewNode getChildByName(java.lang.String name)
           
 java.util.List<SDViewNode> getChildren()
          Returns a list of SDViewNode instances that are children of this node.
 SDCompositionUsage getCompositionUsage(java.lang.String childName)
           
 SDViewNode getContainedNodeForDBObject(java.lang.String dbObject)
           
 SDViewNode getContainedNodeForDef(java.lang.String viewDef)
          Method returns contained child node that has the same view definition object as the viewDef.
static java.lang.String getDBObject(oracle.jbo.ViewObject vo)
           
static SDViewNode getDriver(oracle.jbo.ApplicationModule appModule, java.lang.String viewName)
          Convinience API.
static SDViewNode getDriver(oracle.jbo.ApplicationModule appModule, java.lang.String viewName, java.lang.Class cls)
          Gets the seed driver view object for a given view name.
 java.lang.String getDriverId()
           
 SDViewNode getDriverNode()
           
 java.util.Map<java.lang.String,oracle.jbo.AttributeDef> getDrivingAttributeDefsMap(java.lang.String attrName)
          Fetches the list of attributes definitions that drive the given attribute via an LOV.
 java.util.Set<java.lang.String> getDrivingAttributes(java.lang.String attrName)
          Fetches the list of attributes that drive the given attribute via an LOV.
 SDLOVUsage getDrivingLOVUsage(java.lang.String attrName)
           
 oracle.jbo.AttributeDef getEnterpriseAttribute()
           
 SDViewNode getExtensionNode(java.lang.String name)
          Looks up a polymorphic subtype of the current node.
 java.util.List<oracle.jbo.AttributeDef> getExtractAttributes()
           
 java.util.List<oracle.jbo.AttributeDef> getKeyAttributes()
          Gets the key attributes for this view node.
 Mapper getMapper(java.lang.String attr)
           
 java.lang.String getName()
           
 java.util.Set<oracle.jbo.AttributeDef> getOrderedPayloadAttrs()
           
 java.util.List<oracle.jbo.AttributeDef> getPrimaryKeyAttributesWithoutEffDate()
          Get the list of AttributeDefs that make up the logical keys of the effective dated entity.
static java.lang.String getReferenceAttributeName(SDViewNode targetNode, java.lang.String attr)
           
 SDViewNode getReferenceByName(java.lang.String name)
           
 java.util.List<SDViewNode> getReferences()
           
 SDReferenceUsage getReferenceUsage(java.lang.String refName)
           
 SDReferenceUsage getReferenceUsageByAttribute(java.lang.String attrName)
           
static java.util.List<oracle.jbo.ViewObject> getRootViews(oracle.jbo.ApplicationModule appModule)
          Gets a list of 'top-level' view objects in the given app module.
 java.lang.String getSeedChangeIndicator()
          Get the seed change indicator attribute as defined for this node.
static java.util.List<oracle.jbo.ViewObject> getSeedDriverViews(oracle.jbo.ApplicationModule appModule)
          Gets a list of Seed Driver View Objects in the given app Module.
 java.util.LinkedHashMap<oracle.jbo.AttributeDef,oracle.jbo.AttributeDef> getSelfReferences()
          Gets the attributes which make up the self reference if this SDViewNode instance really has a self referemce.
 java.util.List<java.lang.String[]> getStaticExtRefList()
           
 oracle.jbo.AttributeDef getSurrogateAttribute()
          Returns the attribute that is identified in the configurton as surrogate.
 java.util.Map<java.lang.String,oracle.jbo.AttributeDef> getTrueKeyAttributeDefsMap()
          returns a map of attribute name and java type
 java.util.Collection<java.lang.String> getTrueKeyAttributeNames()
          Gets the complete list of attribute names that make up the 'true' key of this node.
 java.util.List<java.lang.String> getTrueKeyAttributeNamesNoChaining()
          Get the list of key attribute names, not including the parental chain.
static oracle.jbo.AttributeDef getViewAttrDefForEntityAttrDef(oracle.jbo.AttributeDef eoAttrDef, oracle.jbo.ViewObject vo)
           
static oracle.jbo.AttributeDef getViewAttrDefForEntityAttrDef(oracle.jbo.AttributeDef eoAttrDef, oracle.jbo.ViewObject vo, oracle.jbo.server.EntityDefImpl eDef)
          Get the View attribute def associated with the given Entity attribute def.
 oracle.jbo.ViewObject getViewObject()
           
protected  void handleSelfReferences()
          Checks if the current view object has a reference to itself.
 boolean hasExtensionVOs()
          Checks if the current node has polymorphic extension nodes.
 boolean hasExtractedAttribute(java.lang.String attrName)
           
 int hashCode()
           
 boolean hasReference(java.lang.String refName)
           
 boolean hasSelfReferences()
          Checks if this SDViewNode instance has selef references.
 boolean hasSurrogate()
           
protected  void initialize()
           
 boolean isAttrInCompUsage(oracle.jbo.AttributeDef attr)
          Determine if attribute participates in the parent composition usage.
protected  boolean isAttrToBeExcluded(java.lang.String attrName)
           
 boolean isChangeIndicator(oracle.jbo.AttributeDef attr)
          Checks if given attribute is marked as Change Indicator (OVN) on its EntityDef.
 boolean isContained()
           
 boolean isEffDateAttr(oracle.jbo.server.AttributeDefImpl attr)
          Test if the attribute def is marked as an effective date attr.
 boolean isEffectiveDated()
          Checks if this SDViewNode instance is an effective dated one.
 boolean isForeignKey(oracle.jbo.AttributeDef attr)
          Checks if a given attribute is linked through View Links to some other node.
protected  boolean isHashingAttr(oracle.jbo.AttributeDef attr)
          Does the attribute partake in the mid-tier hash gen.
 boolean isHistoryColAttribute(oracle.jbo.AttributeDef attr)
           
 boolean isIncrDatabase()
           
 boolean isIncrMidTier()
          Test if incremental loading, and mid-tier hash cacluation enabled.
 boolean isKeyAttribute(oracle.jbo.AttributeDef attr)
           
 boolean isLOVDriven(java.lang.String attrName)
          Checks if a given attribute is populated through LOV(s).
 boolean isLOVToBeExcluded(java.lang.String lovName)
           
 boolean isMLSAttribute(oracle.jbo.AttributeDef attr)
          Return true if attribute is "Language"
 boolean isMultiTenantCapable()
          Check if this node is multi-tenant aware.
 boolean isParentKey(oracle.jbo.AttributeDef attr)
          Checks if a given attribute is linked to the parent of this node.
 boolean isReference(oracle.jbo.server.ViewAttributeDefImpl attr)
           
 boolean isTranslatable()
          Test if this node is translatable.
 boolean isTranslationIncrLoad()
          Test if incremental load for translations is enabled for this node.
 boolean isVAInRefVAList(java.lang.String vaDefName)
           
 java.lang.String toString()
           
 
Methods inherited from class javax.swing.tree.DefaultMutableTreeNode
add, breadthFirstEnumeration, children, clone, depthFirstEnumeration, getAllowsChildren, getChildAfter, getChildAt, getChildBefore, getChildCount, getDepth, getFirstChild, getFirstLeaf, getIndex, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getParent, getPath, getPathToRoot, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isLeaf, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, isRoot, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setParent, setUserObject
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

childNodes

protected java.util.List<SDViewNode> childNodes

extRefList

protected java.util.List<java.lang.String[]> extRefList

refVAList

protected java.util.List<java.lang.String> refVAList

orderedPayloadAttrs

protected java.util.Set<oracle.jbo.AttributeDef> orderedPayloadAttrs

isNodeTranslatable

protected java.lang.Boolean isNodeTranslatable

dumpDepth

protected static int dumpDepth
Constructor Detail

SDViewNode

public SDViewNode(oracle.jbo.ViewObject viewObject,
                  oracle.jbo.ApplicationModule appModule)
Method Detail

getRootViews

public static java.util.List<oracle.jbo.ViewObject> getRootViews(oracle.jbo.ApplicationModule appModule)
Gets a list of 'top-level' view objects in the given app module. A top-level view object is one that is not involved in the destination end of any of the view links contained in the given app module.

Parameters:
appModule - application module to look into for top-level view objects
Returns:
list of top-level view objects

getSeedDriverViews

public static java.util.List<oracle.jbo.ViewObject> getSeedDriverViews(oracle.jbo.ApplicationModule appModule)
Gets a list of Seed Driver View Objects in the given app Module. This is a subset of the the list returned by getRootViews. A root view thats explicitly marked in the Seed Config metadata as a driver will find a place in the returned list.

Parameters:
appModule - Application Module
Returns:
list of ViewObject one for each of the seed data driver views

findViewNodeByDef

public static SDViewNode findViewNodeByDef(oracle.jbo.ApplicationModule appModule,
                                           SDViewNode excludeNode,
                                           java.lang.String viewDef)
find the view node which has the same view definition as viewDef and is either a driver view node or is part of the hierarchy of a driver view node

Parameters:
appModule - Application Module
viewDef - view definition name, Full definition is expected
Returns:
the View Node which matches the given defintion

findViewNodeByDBObject

public static SDViewNode findViewNodeByDBObject(oracle.jbo.ApplicationModule appModule,
                                                SDViewNode excludeNode,
                                                java.lang.String dBObject)
find the view node which has the same DB Object as dBObject and is either a driver view node or is part of the hierarchy of a driver view node.

Parameters:
appModule - Application Module
dBObject - db object name
Returns:
the View Node which matches the given Db Object

areDriverNodesSame

public static boolean areDriverNodesSame(SDViewNode node1,
                                         SDViewNode node2)
Checks for given two ViewNodes whether the driver is same or not

Parameters:
node1 -
node2 -
Returns:

findViewNode

public static SDViewNode findViewNode(oracle.jbo.ApplicationModule refAM,
                                      oracle.jbo.ViewObject refVO)

findViewInstance

public static SDViewNode findViewInstance(java.lang.String instanceName,
                                          oracle.jbo.ApplicationModule am)
Finds the view object with the given instance name in the am

Parameters:
instanceName - view object instance name which needs to be found in am
am - AppilcationModule in which instance should be found
Returns:

getDriver

public static SDViewNode getDriver(oracle.jbo.ApplicationModule appModule,
                                   java.lang.String viewName,
                                   java.lang.Class cls)
Gets the seed driver view object for a given view name.

Parameters:
appModule - Application Module
viewName - View Object name whose driver view object is being requested
cls - a subclass of SDViewNode. If a driver view is located, the returned object will be an instance of this class.
Returns:
driver view node for the given view object, null if no driver views could be found

getDriver

public static SDViewNode getDriver(oracle.jbo.ApplicationModule appModule,
                                   java.lang.String viewName)
Convinience API. This is the same as calling getDriver (appModule, viewName, SDViewNode.class)

Parameters:
appModule - Application Module
viewName - View Object name whose driver view object is being requested
Returns:
driver view node for the given view object, null if no driver views could be found

getDBObject

public static java.lang.String getDBObject(oracle.jbo.ViewObject vo)

initialize

protected void initialize()

buildParentHierarchy

public void buildParentHierarchy()
                          throws java.lang.NoSuchMethodException,
                                 java.lang.InstantiationException,
                                 java.lang.IllegalAccessException,
                                 java.lang.reflect.InvocationTargetException,
                                 SDMetaDataException
Special Method used for creating the parent hierarchy. NOTE: this is currently used only for VL Reference View Node creation The nodes in the hierarchy built by this method are not initalized with a call to the initailize method.

Throws:
java.lang.NoSuchMethodException
java.lang.InstantiationException
java.lang.IllegalAccessException
java.lang.reflect.InvocationTargetException
SDMetaDataException

isLOVToBeExcluded

public boolean isLOVToBeExcluded(java.lang.String lovName)

isAttrToBeExcluded

protected boolean isAttrToBeExcluded(java.lang.String attrName)

getSeedChangeIndicator

public java.lang.String getSeedChangeIndicator()
Get the seed change indicator attribute as defined for this node. This is for database based hash calculations only.

Returns:
String seed change indicator attribute name for this node, or null if not set

isIncrMidTier

public boolean isIncrMidTier()
Test if incremental loading, and mid-tier hash cacluation enabled.

Returns:
True when incrmental loading and mid-tier hash enabled

isIncrDatabase

public boolean isIncrDatabase()

isTranslationIncrLoad

public boolean isTranslationIncrLoad()
Test if incremental load for translations is enabled for this node. Currently, translation incremental loading is performed as separate process from base files.

Returns:
true when nls incremental load

getViewAttrDefForEntityAttrDef

public static oracle.jbo.AttributeDef getViewAttrDefForEntityAttrDef(oracle.jbo.AttributeDef eoAttrDef,
                                                                     oracle.jbo.ViewObject vo)
                                                              throws SDMetaDataException
Throws:
SDMetaDataException

getViewAttrDefForEntityAttrDef

public static oracle.jbo.AttributeDef getViewAttrDefForEntityAttrDef(oracle.jbo.AttributeDef eoAttrDef,
                                                                     oracle.jbo.ViewObject vo,
                                                                     oracle.jbo.server.EntityDefImpl eDef)
                                                              throws SDMetaDataException
Get the View attribute def associated with the given Entity attribute def.

Parameters:
eoAttrDef - AttributeDef at Entity level
Returns:
AttributeDef at View level
Throws:
SDMetaDataException

isParentKey

public boolean isParentKey(oracle.jbo.AttributeDef attr)
Checks if a given attribute is linked to the parent of this node.

Parameters:
attr - attribute to be checked
Returns:
true if the given attribute is linked to the parent ofthis node, false otherwise.

isAttrInCompUsage

public boolean isAttrInCompUsage(oracle.jbo.AttributeDef attr)
Determine if attribute participates in the parent composition usage. Needed when the source and dest keys are not same name. See Bug 8596451.

Parameters:
attr - AttributeDef
Returns:
true when attr is dest attr of parent composition usage

isMLSAttribute

public boolean isMLSAttribute(oracle.jbo.AttributeDef attr)
Return true if attribute is "Language"

Parameters:
attr -
Returns:

isChangeIndicator

public boolean isChangeIndicator(oracle.jbo.AttributeDef attr)
Checks if given attribute is marked as Change Indicator (OVN) on its EntityDef.

Parameters:
attr - AttributeDef to check
Returns:
True when attribute is marked as the change indicator column.

isForeignKey

public boolean isForeignKey(oracle.jbo.AttributeDef attr)
Checks if a given attribute is linked through View Links to some other node.

Parameters:
attr - attribute to be checked
Returns:
true if the given attribute is linked to some other node through VLs, false otherwise.

isReference

public boolean isReference(oracle.jbo.server.ViewAttributeDefImpl attr)

isLOVDriven

public boolean isLOVDriven(java.lang.String attrName)
Checks if a given attribute is populated through LOV(s).

Parameters:
attrName - - attribute to check
Returns:
true if the given attribute is populated through LOV(s)

getDrivingAttributes

public java.util.Set<java.lang.String> getDrivingAttributes(java.lang.String attrName)
Fetches the list of attributes that drive the given attribute via an LOV.

Parameters:
attrName - - attribute whose LOV driving attributes are to be fetched
Returns:
Set of attribute names that drive the given attribute through LOV(s)

getDrivingAttributeDefsMap

public java.util.Map<java.lang.String,oracle.jbo.AttributeDef> getDrivingAttributeDefsMap(java.lang.String attrName)
Fetches the list of attributes definitions that drive the given attribute via an LOV.

Parameters:
attrName - - attribute whose LOV driving attributes are to be fetched
Returns:
Set of attribute definitions that drive the given attribute through LOV(s)

getDrivingLOVUsage

public SDLOVUsage getDrivingLOVUsage(java.lang.String attrName)

isHashingAttr

protected boolean isHashingAttr(oracle.jbo.AttributeDef attr)
Does the attribute partake in the mid-tier hash gen. Only persistent, non-key, non-history col attrs.

Parameters:
attr - AttributeDef
Returns:
true if the attr should be included in mid-tier hash

isHistoryColAttribute

public boolean isHistoryColAttribute(oracle.jbo.AttributeDef attr)

isKeyAttribute

public boolean isKeyAttribute(oracle.jbo.AttributeDef attr)

findOrCreateViewObject

protected oracle.jbo.ViewObject findOrCreateViewObject(oracle.jbo.server.ViewDefImpl def)

hasExtensionVOs

public boolean hasExtensionVOs()
Checks if the current node has polymorphic extension nodes.

Returns:
true if the current node has polymorphic extension nodes.

getExtensionNode

public SDViewNode getExtensionNode(java.lang.String name)
Looks up a polymorphic subtype of the current node.

Parameters:
name - - view name of the the polymorphic sub type
Returns:
SDViewNode representhing the correct subtype of the current node or null if such a subtype doesn't exist

handleSelfReferences

protected void handleSelfReferences()
Checks if the current view object has a reference to itself.


hasSelfReferences

public boolean hasSelfReferences()
Checks if this SDViewNode instance has selef references.

Returns:
true if this SDViewNode instance has self references.

getSelfReferences

public java.util.LinkedHashMap<oracle.jbo.AttributeDef,oracle.jbo.AttributeDef> getSelfReferences()
Gets the attributes which make up the self reference if this SDViewNode instance really has a self referemce.

Returns:
LinkedHashMap containing the source-to-destination mapping for the self reference or an empty map if no self reference exists.

isEffectiveDated

public boolean isEffectiveDated()
Checks if this SDViewNode instance is an effective dated one.

Returns:
true if this SDViewNode instance is an effective dated one.

getName

public java.lang.String getName()

isContained

public boolean isContained()

getDriverId

public java.lang.String getDriverId()

getDriverNode

public SDViewNode getDriverNode()

getViewObject

public oracle.jbo.ViewObject getViewObject()

getAM

public oracle.jbo.ApplicationModule getAM()

hasSurrogate

public boolean hasSurrogate()

getSurrogateAttribute

public oracle.jbo.AttributeDef getSurrogateAttribute()
Returns the attribute that is identified in the configurton as surrogate.

Returns:
surrogate attribute if defined, null otherwise

getChildren

public java.util.List<SDViewNode> getChildren()
Returns a list of SDViewNode instances that are children of this node.

Returns:
List of SDViewNode instances

getChildByName

public SDViewNode getChildByName(java.lang.String name)

getChildByDefName

public SDViewNode getChildByDefName(java.lang.String defName)

getCompositionUsage

public SDCompositionUsage getCompositionUsage(java.lang.String childName)

getAllCompositionUsages

public java.util.Collection<SDCompositionUsage> getAllCompositionUsages()

getReferences

public java.util.List<SDViewNode> getReferences()

getAllLOVUsages

public java.util.Collection<SDLOVUsage> getAllLOVUsages()

getReferenceByName

public SDViewNode getReferenceByName(java.lang.String name)

getReferenceUsageByAttribute

public SDReferenceUsage getReferenceUsageByAttribute(java.lang.String attrName)

getReferenceUsage

public SDReferenceUsage getReferenceUsage(java.lang.String refName)

getAllReferenceUsages

public java.util.Collection<SDReferenceUsage> getAllReferenceUsages()

hasExtractedAttribute

public boolean hasExtractedAttribute(java.lang.String attrName)

hasReference

public boolean hasReference(java.lang.String refName)

getExtractAttributes

public java.util.List<oracle.jbo.AttributeDef> getExtractAttributes()

getOrderedPayloadAttrs

public java.util.Set<oracle.jbo.AttributeDef> getOrderedPayloadAttrs()

getMapper

public Mapper getMapper(java.lang.String attr)

getAllMappers

public java.util.List<Mapper> getAllMappers()

getAltKeyAttributeList

public java.util.List<oracle.jbo.AttributeDef> getAltKeyAttributeList()
Method returns list of invariant key attributes. The list is populated if the view object contains surrogate attribute. The attributes are based on the alternate key attributes of the entity behind the view. The alternate key should contain all attributes of the primary key other than the surrogate key. It will contain additional attributes to uniquely identify the data row.

Returns:
List of invarinat key attributes.

getAltKeyCriteria

public oracle.jbo.ViewCriteria getAltKeyCriteria()
Method returns a ViewCriteria. The view criteria is populated with the names of the alternate Key Attributes and bind variables with the same name. The operation is set to '='.

Returns:
ViewCriteria for altenate key.

getKeyAttributes

public java.util.List<oracle.jbo.AttributeDef> getKeyAttributes()
Gets the key attributes for this view node. If the node has a surrogate, gets the alternate key attributes. Does not dereference parent/child or foreign key attributes.

Returns:
List of attributes that make up the primary key of this node or the alternate key for this node in case if the node has any surrogate attributes.

getPrimaryKeyAttributesWithoutEffDate

public java.util.List<oracle.jbo.AttributeDef> getPrimaryKeyAttributesWithoutEffDate()
Get the list of AttributeDefs that make up the logical keys of the effective dated entity. List will include all key PK attributes that make up a logical row, without the eff date attrs.

Returns:
List of primary key AttributeDefs that make up logical row

getAltKeyAttributesWithoutEffDate

public java.util.List<oracle.jbo.AttributeDef> getAltKeyAttributesWithoutEffDate()
Get the list of AttributeDefs that make up the logical keys of the effective dated entity. List will include all the Alt Key (or PK if no alt) attributes that make up a logical row, without eff date attrs.

Returns:
List of alt key AttributeDefs that make up logical row

isEffDateAttr

public boolean isEffDateAttr(oracle.jbo.server.AttributeDefImpl attr)
Test if the attribute def is marked as an effective date attr.

Parameters:
attr - AttributeDefImpl
Returns:
True when attr is an effective date attribute

getTrueKeyAttributeNamesNoChaining

public java.util.List<java.lang.String> getTrueKeyAttributeNamesNoChaining()
Get the list of key attribute names, not including the parental chain. Any atrributes based on LOVs will include the LOV's driving attributes.

Returns:
List of String attribute names

getTrueKeyAttributeNames

public java.util.Collection<java.lang.String> getTrueKeyAttributeNames()
Gets the complete list of attribute names that make up the 'true' key of this node. If the node has any surrogate attributes, the alternate key is used, else the primary key. If the node is involved in any parent/child or foreign key relationships, those are dereferenced, so that the key thats returned has all the attributes required to uniquely identify a record of this node. Bug 9124437 Any LOV driven key attributes are replaced with the LOV driving attribute names. Bug 9635825 Return only the set of unique atribute names, so if more than one same derived LOV attribute, return just one.

Returns:
Collection of unique key attribute names

getTrueKeyAttributeDefsMap

public java.util.Map<java.lang.String,oracle.jbo.AttributeDef> getTrueKeyAttributeDefsMap()
returns a map of attribute name and java type

Returns:

getContainedNodeForDef

public SDViewNode getContainedNodeForDef(java.lang.String viewDef)
Method returns contained child node that has the same view definition object as the viewDef.

Parameters:
viewDef - View definition
Returns:
returns ViewNode.

getContainedNodeForDBObject

public SDViewNode getContainedNodeForDBObject(java.lang.String dbObject)

getReferenceAttributeName

public static java.lang.String getReferenceAttributeName(SDViewNode targetNode,
                                                         java.lang.String attr)

toString

public java.lang.String toString()
Overrides:
toString in class javax.swing.tree.DefaultMutableTreeNode

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

dumpNode

public void dumpNode()

dumpTree

public void dumpTree()

getAltKeyAttributeNames

public java.util.List<java.lang.String> getAltKeyAttributeNames()
Get the attribute names of the alternate key as a List of Strings.

Returns:
List of String alt key attribute names

isMultiTenantCapable

public boolean isMultiTenantCapable()
Check if this node is multi-tenant aware. Convienence

Returns:

isVAInRefVAList

public boolean isVAInRefVAList(java.lang.String vaDefName)

getStaticExtRefList

public java.util.List<java.lang.String[]> getStaticExtRefList()

isTranslatable

public boolean isTranslatable()
Test if this node is translatable.

Returns:
boolean true when node is translatable

getEnterpriseAttribute

public oracle.jbo.AttributeDef getEnterpriseAttribute()

Oracle Fusion Middleware extensions for Seed Data Framework
11g Release 1 (11.1.2)

E22564-02

Copyright © 2011 Oracle. All Rights Reserved.