|
Oracle TopLink Java API Reference 10g Release 3 (10.1.3.1) B28219-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.toplink.mappings.DatabaseMapping
oracle.toplink.mappings.ForeignReferenceMapping
oracle.toplink.mappings.CollectionMapping
oracle.toplink.mappings.DirectCollectionMapping
Purpose: This mapping is used to store a collection of simple types (String, Number, Date, etc.) into a single table. The table must store the value and a foreign key to the source object. A converter can be used if the desired object type and the data type do not match.
Converter
, ObjectTypeConverter
, TypeConversionConverter
, SerializedObjectConverter
, Serialized FormConstructor Summary | |
DirectCollectionMapping() PUBLIC: Default constructor. |
Method Summary | |
void |
addReferenceKeyFieldName(java.lang.String referenceForeignKeyFieldName, java.lang.String sourcePrimaryKeyFieldName) PUBLIC: Add the name of the reference key field. |
java.lang.String |
getDirectFieldName() PUBLIC: Returns the name of the field name in the reference table. |
HistoryPolicy |
getHistoryPolicy() PUBLIC: |
java.lang.String |
getReferenceClassName() INTERNAL: Used by MW. |
java.lang.String |
getReferenceTableName() PUBLIC: Returns the name of the reference table |
java.lang.String |
getReferenceTableQualifiedName() PUBLIC: Returns the qualified name of the reference table |
java.util.Vector |
getSourceKeyFieldNames() PUBLIC: Return the source key field names associated with the mapping. |
Converter |
getValueConverter() PUBLIC: Return the converter on the mapping. |
boolean |
isRelationalMapping() INTERNAL: All relational mappings should implement this method to return true. |
void |
setContainerPolicy(ContainerPolicy containerPolicy) ADVANCED: Configure the mapping to use a container policy. |
void |
setCustomDeleteQuery(ModifyQuery query) PUBLIC: The default delete query for this mapping can be overridden by specifying the new query. |
void |
setCustomInsertQuery(DataModifyQuery query) PUBLIC: The default insert query for mapping can be overridden by specifying the new query. |
void |
setDeleteSQLString(java.lang.String sqlString) PUBLIC: Set the receiver's delete SQL string. |
void |
setDirectFieldName(java.lang.String fieldName) PUBLIC: Set the direct field name in the reference table. |
void |
setHistoryPolicy(HistoryPolicy policy) PUBLIC: |
void |
setInsertSQLString(java.lang.String sqlString) PUBLIC: Set the receiver's insert SQL string. |
void |
setReferenceClassName(java.lang.String referenceClassName) INTERNAL: Used by MW. |
void |
setReferenceKeyFieldName(java.lang.String fieldName) PUBLIC: Set the name of the reference key field. |
void |
setReferenceTableName(java.lang.String tableName) PUBLIC: Set the reference table name. |
void |
setSessionName(java.lang.String name) PUBLIC: Set the name of the session to execute the mapping's queries under. |
void |
setValueConverter(Converter valueConverter) PUBLIC: Set the converter on the mapping. |
void |
simpleAddToCollectionChangeRecord(java.lang.Object referenceKey, java.lang.Object objectToAdd, ObjectChangeSet changeSet, Session session) ADVANCED: This method is used to have an object add to a collection once the changeSet is applied The referenceKey parameter should only be used for direct Maps. |
void |
simpleRemoveFromCollectionChangeRecord(java.lang.Object referenceKey, java.lang.Object objectToRemove, ObjectChangeSet changeSet, Session session) ADVANCED: This method is used to have an object removed from a collection once the changeSet is applied The referenceKey parameter should only be used for direct Maps. |
void |
useCollectionClass(java.lang.Class concreteClass) PUBLIC: Configure the mapping to use an instance of the specified container class to hold the target objects. |
void |
useMapClass(java.lang.Class concreteClass, java.lang.String methodName) PUBLIC: It is illegal to use a Map as the container of a DirectCollectionMapping. |
Methods inherited from class oracle.toplink.mappings.CollectionMapping |
addAscendingOrdering, addDescendingOrdering, getRealCollectionAttributeValueFromObject, setCustomDeleteAllQuery, setDeleteAllCall, setDeleteAllSQLString, useSortedSetClass, useTransparentCollection, useTransparentList, useTransparentMap, useTransparentSet |
Methods inherited from class oracle.toplink.mappings.DatabaseMapping |
getAttributeAccessor, getAttributeClassification, getAttributeName, getGetMethodName, getProperty, getReferenceClassDescriptor, getSetMethodName, isUsingMethodAccess, readOnly, readWrite, setAttributeAccessor, setAttributeName, setGetMethodName, setIsReadOnly, setProperty, setSetMethodName, setWeight |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public DirectCollectionMapping()
Method Detail |
public boolean isRelationalMapping()
DatabaseMapping
isRelationalMapping
in class DatabaseMapping
public Converter getValueConverter()
public void setValueConverter(Converter valueConverter)
public void addReferenceKeyFieldName(java.lang.String referenceForeignKeyFieldName, java.lang.String sourcePrimaryKeyFieldName)
public java.lang.String getDirectFieldName()
public HistoryPolicy getHistoryPolicy()
public java.lang.String getReferenceClassName()
ForeignReferenceMapping
getReferenceClassName
in class ForeignReferenceMapping
public java.lang.String getReferenceTableName()
public java.lang.String getReferenceTableQualifiedName()
public java.util.Vector getSourceKeyFieldNames()
public void setDeleteSQLString(java.lang.String sqlString)
public void setContainerPolicy(ContainerPolicy containerPolicy)
setContainerPolicy
in interface ContainerMapping
setContainerPolicy
in class CollectionMapping
public void setCustomDeleteQuery(ModifyQuery query)
public void setCustomInsertQuery(DataModifyQuery query)
public void setDirectFieldName(java.lang.String fieldName)
public void setInsertSQLString(java.lang.String sqlString)
public void setReferenceClassName(java.lang.String referenceClassName)
ForeignReferenceMapping
setReferenceClassName
in class ForeignReferenceMapping
public void setReferenceKeyFieldName(java.lang.String fieldName)
public void setReferenceTableName(java.lang.String tableName)
public void setHistoryPolicy(HistoryPolicy policy)
public void setSessionName(java.lang.String name)
setSessionName
in class CollectionMapping
public void simpleAddToCollectionChangeRecord(java.lang.Object referenceKey, java.lang.Object objectToAdd, ObjectChangeSet changeSet, Session session)
simpleAddToCollectionChangeRecord
in class CollectionMapping
public void simpleRemoveFromCollectionChangeRecord(java.lang.Object referenceKey, java.lang.Object objectToRemove, ObjectChangeSet changeSet, Session session)
simpleRemoveFromCollectionChangeRecord
in class CollectionMapping
public void useCollectionClass(java.lang.Class concreteClass)
jdk1.2.x: The container class must implement (directly or indirectly) the Collection interface.
jdk1.1.x: The container class must be a subclass of Vector.
useCollectionClass
in interface ContainerMapping
useCollectionClass
in class CollectionMapping
public void useMapClass(java.lang.Class concreteClass, java.lang.String methodName)
useMapClass
in interface ContainerMapping
useMapClass
in class CollectionMapping
DirectMapMapping
|
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |