All Packages Class Hierarchy This Package Previous Next Index
java.lang.Object | +----org.xmlmiddleware.xmldbms.maps.MapBase | +----org.xmlmiddleware.xmldbms.maps.LinkInfo
LinkInfo contains the keys needed to link one class table to another class table or a class table to a property table. LinkInfo classes are used in RelatedClassMaps, PropertyMaps, and RelatedTableMaps.
In PropertyMaps and RelatedClassMaps, "parent" and "child" refer to the relationship between the corresponding structures in the XML document. In a class / property relationship, such as an element type and an attribute, the parent is the class (mapped by a ClassMap) and child is the property (mapped by a PropertyMap). In a class / related class relationship, such as between an element type and a child element type mapped as a class, the parent is the class (mapped by a ClassMap) and the child is the related class (mapped by a RelatedClassMap).
In RelatedTableMaps, "parent" and "child" refer to the relationship between the corresponding structures in the database. That is, the parent is the table encountered first in the database hierarchy (mapped by a ClassTableMap) and the child is the table encountered second (mapped by a RelatedClassTableMap).
The parent / child relationship is independent of where the primary / unique key is located. That is, it could be in the table of the parent or the child. Which table contains the primary / unique key is determined by the types of the parent and child keys.
public static LinkInfo create(Key parentKey, Key childKey)
If the parent key is a primary or unique key, the child key must be a foreign key and vice versa.
public final Key getParentKey()
public final Key getChildKey()
public final boolean parentKeyIsUnique()
All Packages Class Hierarchy This Package Previous Next Index