|
Oracle Fusion Middleware Java API Reference for Oracle TopLink 11g Release 1 (11.1.1) B32476-03 |
||||||||
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
public abstract class CollectionMapping
Purpose: Abstract class for relationship mappings which store collection of objects
Field Summary |
---|
Fields inherited from class oracle.toplink.mappings.ForeignReferenceMapping |
---|
INNER_JOIN, NONE, OUTER_JOIN |
Constructor Summary | |
---|---|
CollectionMapping()
Default constructor. |
Method Summary | |
---|---|
void |
addAggregateOrderBy(java.lang.String aggregateName,
java.lang.String queryKeyName,
boolean isDescending)
Provide order support for queryKeyName in ascending order. |
void |
addAscendingOrdering(java.lang.String queryKeyName)
Provide order support for queryKeyName in ascending order |
void |
addDescendingOrdering(java.lang.String queryKeyName)
Provide order support for queryKeyName in descending order. |
void |
addOrderBy(java.lang.String queryKeyName,
boolean isDescending)
Provide order support for queryKeyName in descending or ascending order. |
java.lang.Object |
getRealCollectionAttributeValueFromObject(java.lang.Object object,
oracle.toplink.internal.sessions.AbstractSession session)
Convenience method. |
void |
setContainerPolicy(oracle.toplink.internal.queryframework.ContainerPolicy containerPolicy)
ADVANCED: Configure the mapping to use a container policy. |
void |
setCustomDeleteAllQuery(ModifyQuery query)
The default delete all query for mapping can be overridden by specifying the new query. |
void |
setDeleteAllCall(Call call)
Set the receiver's delete all call. |
void |
setDeleteAllSQLString(java.lang.String sqlString)
Set the receiver's delete all SQL string. |
void |
setSessionName(java.lang.String name)
Set the name of the session to execute the mapping's queries under. |
void |
simpleAddToCollectionChangeRecord(java.lang.Object referenceKey,
java.lang.Object changeSetToAdd,
oracle.toplink.internal.sessions.ObjectChangeSet changeSet,
oracle.toplink.internal.sessions.AbstractSession 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 changeSetToRemove,
oracle.toplink.internal.sessions.ObjectChangeSet changeSet,
oracle.toplink.internal.sessions.AbstractSession 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)
Configure the mapping to use an instance of the specified container class to hold the target objects. |
void |
useMapClass(java.lang.Class concreteClass)
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 keyName)
Configure the mapping to use an instance of the specified container class to hold the target objects. |
void |
useSortedSetClass(java.lang.Class concreteClass,
java.util.Comparator comparator)
Configure the mapping to use an instance of the specified container class to hold the target objects. |
void |
useTransparentCollection()
If transparent indirection is used, a special collection will be placed in the source object's attribute. |
void |
useTransparentList()
If transparent indirection is used, a special collection will be placed in the source object's attribute. |
void |
useTransparentMap(java.lang.String methodName)
If transparent indirection is used, a special map will be placed in the source object's attribute. |
void |
useTransparentSet()
If transparent indirection is used, a special collection will be placed in the source object's attribute. |
Methods inherited from class oracle.toplink.mappings.DatabaseMapping |
---|
getAttributeAccessor, getAttributeClassification, getAttributeName, getGetMethodName, getProperty, getSetMethodName, isLazy, isOptional, isUsingMethodAccess, readOnly, readWrite, setAttributeAccessor, setAttributeName, setGetMethodName, setIsLazy, setIsOptional, setIsReadOnly, setProperty, setSetMethodName, setWeight |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public CollectionMapping()
Method Detail |
---|
public void addAscendingOrdering(java.lang.String queryKeyName)
public void addDescendingOrdering(java.lang.String queryKeyName)
public void addOrderBy(java.lang.String queryKeyName, boolean isDescending)
public void addAggregateOrderBy(java.lang.String aggregateName, java.lang.String queryKeyName, boolean isDescending)
public java.lang.Object getRealCollectionAttributeValueFromObject(java.lang.Object object, oracle.toplink.internal.sessions.AbstractSession session) throws DescriptorException
getRealCollectionAttributeValueFromObject
in class DatabaseMapping
DescriptorException
public void setContainerPolicy(oracle.toplink.internal.queryframework.ContainerPolicy containerPolicy)
setContainerPolicy
in interface ContainerMapping
public void setCustomDeleteAllQuery(ModifyQuery query)
public void setDeleteAllSQLString(java.lang.String sqlString)
public void setDeleteAllCall(Call call)
public void setSessionName(java.lang.String name)
public void simpleAddToCollectionChangeRecord(java.lang.Object referenceKey, java.lang.Object changeSetToAdd, oracle.toplink.internal.sessions.ObjectChangeSet changeSet, oracle.toplink.internal.sessions.AbstractSession session)
simpleAddToCollectionChangeRecord
in class DatabaseMapping
public void simpleRemoveFromCollectionChangeRecord(java.lang.Object referenceKey, java.lang.Object changeSetToRemove, oracle.toplink.internal.sessions.ObjectChangeSet changeSet, oracle.toplink.internal.sessions.AbstractSession session)
simpleRemoveFromCollectionChangeRecord
in class DatabaseMapping
public void useCollectionClass(java.lang.Class concreteClass)
The container class must implement (directly or indirectly) the
java.util.Collection
interface.
useCollectionClass
in interface ContainerMapping
public void useSortedSetClass(java.lang.Class concreteClass, java.util.Comparator comparator)
The container class must implement (directly or indirectly) the
java.util.SortedSet
interface.
public void useMapClass(java.lang.Class concreteClass, java.lang.String keyName)
Map
is the value returned by a call to the specified
zero-argument method.
The method must be implemented by the class (or a superclass) of any
value to be inserted into the Map
.
The container class must implement (directly or indirectly) the
java.util.Map
interface.
To facilitate resolving the method, the mapping's referenceClass must set before calling this method.
useMapClass
in interface ContainerMapping
public void useMapClass(java.lang.Class concreteClass)
Map
is an instance of the composite primary key class.
To facilitate resolving the primary key class, the mapping's referenceClass must set before calling this method.
The container class must implement (directly or indirectly) the
java.util.Map
interface.
public void useTransparentCollection()
public void useTransparentSet()
public void useTransparentList()
public void useTransparentMap(java.lang.String methodName)
The key used in the Map is the value returned by a call to the zero parameter method named methodName. The method should be a zero argument method implemented (or inherited) by the value to be inserted into the Map.
|
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |