oracle.toplink.sdk
Class SDKObjectCollectionMapping
java.lang.Object
|
+--oracle.toplink.mappings.DatabaseMapping
|
+--oracle.toplink.mappings.ForeignReferenceMapping
|
+--oracle.toplink.mappings.CollectionMapping
|
+--oracle.toplink.sdk.SDKObjectCollectionMapping
- All Implemented Interfaces:
- java.lang.Cloneable, ContainerMapping, SDKCollectionMapping, java.io.Serializable
- public class SDKObjectCollectionMapping
- extends CollectionMapping
- implements SDKCollectionMapping
SDKObjectCollectionMapping
is used to represent
a relationship between a single
source object and collection of target objects; where,
on the data store, the source object has a collection of
references (foreign keys) to the target objects. The parent
database row stores the nested foreign keys in database rows
in an SDKFieldValue
.
- Since:
- TOPLink/Java 3.0
- See Also:
SDKDescriptor
,
SDKFieldValue
,
SDKCollectionMappingHelper
,
SDKCollectionChangeRecord
,
SDKOrderedCollectionChangeRecord
, Serialized Form
Type | Method |
void |
addAscendingOrdering(java.lang.String queryKeyName)
PUBLIC:
Currently, the TOPLink SDK does not support query result ordering. |
void |
addDescendingOrdering(java.lang.String queryKeyName)
PUBLIC:
Currently, the TOPLink SDK does not support query result ordering. |
void |
addSourceForeignKeyFieldName(java.lang.String sourceForeignKeyFieldName,
java.lang.String targetKeyFieldName)
PUBLIC:
Define the source foreign key relationship in the one-to-many mapping. |
java.lang.String |
getFieldName()
PUBLIC:
Return the name of the field mapped by the mapping. |
java.lang.String |
getReferenceDataTypeName()
PUBLIC:
Return the "data type" of the reference objects. |
void |
setFieldName(java.lang.String fieldName)
PUBLIC:
Set the name of the field mapped by the mapping. |
void |
setReferenceDataTypeName(java.lang.String referenceDataTypeName)
PUBLIC:
Set the "data type" of the reference objects. |
void |
setSelectionCall(SDKCall call)
PUBLIC:
Set the custom call that will perform the read
query to read all the related objects. |
void |
setSourceForeignKeyFieldName(java.lang.String sourceForeignKeyFieldName)
PUBLIC:
Define the source foreign key relationship in the one-to-many mapping. |
void |
setSourceForeignKeyFieldNames(java.lang.String[] sourceForeignKeyFieldNames,
java.lang.String[] targetKeyFieldNames)
PUBLIC:
Define the source foreign key relationship in the one-to-many mapping. |
void |
setUsesBatchReading(boolean usesBatchReading)
PUBLIC:
Currently, the TOPLink SDK does not support batch reading. |
Methods inherited from class oracle.toplink.mappings.ForeignReferenceMapping |
dontUseBatchReading, dontUseIndirection, getReferenceClass,
getRelationshipPartnerAttributeName, privateOwnedRelationship,
setCustomSelectionQuery, setIndirectionPolicy,
setReferenceClass, setRelationshipPartnerAttributeName,
setSelectionCriteria, setSelectionSQLString,
setUsesIndirection, shouldUseBatchReading, useBasicIndirection,
useBatchReading, useContainerIndirection, useIndirection,
usesIndirection |
Methods inherited from class oracle.toplink.mappings.DatabaseMapping |
getAttributeClassification, getAttributeName, getGetMethodName,
getSetMethodName, readOnly, readWrite,
setAttributeName, setGetMethodName, setIsReadOnly,
setSetMethodName, setWeight |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
SDKObjectCollectionMapping
public SDKObjectCollectionMapping()
- Default constructor.
addAscendingOrdering
public void addAscendingOrdering(java.lang.String queryKeyName)
- PUBLIC:
Currently, the TOPLink SDK does not support query result ordering.
- Overrides:
addAscendingOrdering
in class CollectionMapping
addDescendingOrdering
public void addDescendingOrdering(java.lang.String queryKeyName)
- PUBLIC:
Currently, the TOPLink SDK does not support query result ordering.
- Overrides:
addDescendingOrdering
in class CollectionMapping
addSourceForeignKeyFieldName
public void addSourceForeignKeyFieldName(java.lang.String sourceForeignKeyFieldName,
java.lang.String targetKeyFieldName)
- PUBLIC:
Define the source foreign key relationship in the one-to-many mapping.
This method is used for composite source foreign key relationships.
That is, the source object's table has multiple foreign key fields
that are references to
the target object's (typically primary) key fields.
Both the source foreign key field name and the corresponding
target primary key field name must be specified.
getFieldName
public java.lang.String getFieldName()
- PUBLIC:
Return the name of the field mapped by the mapping.
getReferenceDataTypeName
public java.lang.String getReferenceDataTypeName()
- PUBLIC:
Return the "data type" of the reference objects.
Depending on the data store, this could be optional.
setFieldName
public void setFieldName(java.lang.String fieldName)
- PUBLIC:
Set the name of the field mapped by the mapping.
setReferenceDataTypeName
public void setReferenceDataTypeName(java.lang.String referenceDataTypeName)
- PUBLIC:
Set the "data type" of the reference objects.
Depending on the data store, this could be optional.
setSelectionCall
public void setSelectionCall(SDKCall call)
- PUBLIC:
Set the custom call that will perform the read
query to read all the related objects.
setSourceForeignKeyFieldName
public void setSourceForeignKeyFieldName(java.lang.String sourceForeignKeyFieldName)
- PUBLIC:
Define the source foreign key relationship in the one-to-many mapping.
This method can be used when the foreign and primary keys
have only a single field each.
(Use #addSourceForeignKeyFieldName(String, String)
#setSourceForeignKeyFieldNames(String[], String[]) for "composite" keys.)
Only the source foreign key field name is specified and the target
(primary) key field is
assumed to be the primary key of the target object.
setSourceForeignKeyFieldNames
public void setSourceForeignKeyFieldNames(java.lang.String[] sourceForeignKeyFieldNames,
java.lang.String[] targetKeyFieldNames)
- PUBLIC:
Define the source foreign key relationship in the one-to-many mapping.
This method is used for composite source foreign key relationships.
That is, the source object's table has multiple foreign key fields to
the target object's (typically primary) key fields.
Both the source foreign key field names and the corresponding target primary
key field names must be specified.
setUsesBatchReading
public void setUsesBatchReading(boolean usesBatchReading)
- PUBLIC:
Currently, the TOPLink SDK does not support batch reading.
- Overrides:
setUsesBatchReading
in class ForeignReferenceMapping