public class ForeignFieldDesc extends FieldDesc
| Modifier and Type | Field and Description |
|---|---|
static int |
ACT_AGGREGATE
Currently runtime code does not interprete this action.
|
static int |
ACT_CASCADE
When the parent object is deleted from db,
delete the relationship object described by this object also.
|
static int |
ACT_NONE
When the parent object is deleted,
no action is required for the relationship object described by this object.
|
static int |
ACT_NULLIFY
Currently runtime code does not interprete this action.
|
static int |
ACT_RESTRICT
Currently runtime code does not interprete this action.
|
ArrayList |
assocForeignColumns
Array of ColumnElement.
|
ArrayList |
assocForeignFields
Array of LocalFieldDesc.
|
ArrayList |
assocLocalColumns
Array of ColumnElement.
|
ArrayList |
assocLocalFields
Array of LocalFieldDesc.
|
int |
cardinalityLWB |
int |
cardinalityUPB |
int |
deleteAction |
ArrayList |
foreignColumns
Array of ColumnElement.
|
ClassDesc |
foreignConfig
Class descriptor for the class of this relationship field.
|
ArrayList |
foreignFields
Array of LocalFieldDesc.
|
ArrayList |
localColumns
Array of ColumnElement.
|
ArrayList |
localFields
Array of LocalFieldDesc.
|
absoluteID, classDesc, concurrencyGroup, fetchGroup, GROUP_DEFAULT, GROUP_NONE, logger, messages, PROP_FOREIGN_KEY_FIELD, PROP_IN_CONCURRENCY_CHECK, PROP_LOG_ON_UPDATE, PROP_PRIMARY_KEY_FIELD, PROP_PRIMARY_TRACKED_FIELD, PROP_READ_ONLY, PROP_RECORD_ON_UPDATE, PROP_REF_INTEGRITY_UPDATES, PROP_SECONDARY_TRACKED_FIELD, PROP_TRACK_RELATIONSHIP_FIELD, PROP_VERSION_FIELD, sqlProperties| Modifier and Type | Method and Description |
|---|---|
Object |
createObjectId(SQLStateManager sm,
LocalFieldDesc fieldDesc,
Object value)
Constructs the oid of a related instance.
|
ArrayList |
getAssocForeignFields() |
ArrayList |
getAssocLocalFields() |
ArrayList |
getForeignFields() |
ForeignFieldDesc |
getInverseRelationshipField() |
ArrayList |
getLocalFields() |
boolean |
hasForeignKey()
Checks the conditions that guarantee, that we have the foreign
key on this side.
|
boolean |
isMappedToPk()
Returns true, if the relationship is mapped to primary key fields
on the other relationship side.
|
boolean |
isRelationshipField()
Returns true.
|
boolean |
useJoinTable()
Returns true, if the relationship is mapped to a join table.
|
addTrackedField, convertValue, createSCO, getCharFromString, getComponentType, getDeclaringClass, getEnumType, getName, getTrackedFields, getType, getValue, isForeignKeyField, isKeyField, setupDesc, setValue, toStringpublic static final int ACT_CASCADE
public static final int ACT_NONE
public static final int ACT_NULLIFY
public static final int ACT_RESTRICT
public static final int ACT_AGGREGATE
public ClassDesc foreignConfig
public int cardinalityLWB
public int cardinalityUPB
public int deleteAction
public ArrayList foreignFields
public ArrayList foreignColumns
public ArrayList localFields
public ArrayList localColumns
public ArrayList assocForeignFields
public ArrayList assocForeignColumns
public ArrayList assocLocalFields
public ArrayList assocLocalColumns
public boolean isRelationshipField()
isRelationshipField in class FieldDescpublic boolean useJoinTable()
public boolean hasForeignKey()
public boolean isMappedToPk()
initializeIsMappedToPk()public ArrayList getLocalFields()
public ArrayList getForeignFields()
public ArrayList getAssocLocalFields()
public ArrayList getAssocForeignFields()
public ForeignFieldDesc getInverseRelationshipField()
public Object createObjectId(SQLStateManager sm, LocalFieldDesc fieldDesc, Object value)
SQLStateManager.updateTrackedFields(com.sun.jdo.spi.persistence.support.sqlstore.model.FieldDesc, java.lang.Object, com.sun.jdo.spi.persistence.support.sqlstore.model.ForeignFieldDesc), the new value for the
local field fieldDesc is not yet set and passed as
parameter value. If called for navigation by
SQLStateManager.populateForeignField(com.sun.jdo.spi.persistence.support.sqlstore.model.ForeignFieldDesc), values of updated
local fields must be retrieved from the before image. In both
cases, the actual call to this method is in SQLStateManager.getObjectById(com.sun.jdo.spi.persistence.support.sqlstore.model.ForeignFieldDesc, com.sun.jdo.spi.persistence.support.sqlstore.model.LocalFieldDesc, java.lang.Object, boolean).
For tracked field usage, see
SQLStateManager.setForeignKey(com.sun.jdo.spi.persistence.support.sqlstore.model.ForeignFieldDesc, com.sun.jdo.spi.persistence.support.sqlstore.SQLStateManager, com.sun.jdo.spi.persistence.support.sqlstore.model.ForeignFieldDesc) and
SQLStateManager.updateTrackedFields(com.sun.jdo.spi.persistence.support.sqlstore.model.FieldDesc, java.lang.Object, com.sun.jdo.spi.persistence.support.sqlstore.model.ForeignFieldDesc).
For navigation usage, see
SQLStateManager.realizeForeignField(com.sun.jdo.spi.persistence.support.sqlstore.model.ForeignFieldDesc).
sm - State manager on the local side.fieldDesc - Local field being set.value - New value of the field being set.Copyright © 2019. All rights reserved.