Module org.eclipse.persistence.jpa
Class DynamicIdentityPolicy
java.lang.Object
org.eclipse.persistence.descriptors.CMPPolicy
org.eclipse.persistence.internal.jpa.CMP3Policy
org.eclipse.persistence.jpa.dynamic.DynamicIdentityPolicy
- All Implemented Interfaces:
Serializable
,Cloneable
Custom CMPPolicy to handle Object[]. The parent class supports only List and
ID class for composite keys.
- Since:
- EclipseLink 1.2
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.persistence.descriptors.CMPPolicy
CMPPolicy.KeyElementAccessor, CMPPolicy.KeyIsElementAccessor
-
Field Summary
Fields inherited from class org.eclipse.persistence.internal.jpa.CMP3Policy
fieldToAccessorMap, keyClassFields, pkClass, pkClassName
Fields inherited from class org.eclipse.persistence.descriptors.CMPPolicy
AFTER_EJBCREATE, AFTER_EJBPOSTCREATE, ALL_MODIFICATIONS, descriptor, forceUpdate, mappedClass, modificationDeferralLevel, nonDeferredCreateTime, NONE, pessimisticLockingPolicy, UNDEFINED, UPDATE_MODIFICATIONS, updateAllFields
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncreatePrimaryKeyFromId
(Object key, AbstractSession session) INTERNAL: Use the key to create a EclipseLink primary key.protected CMPPolicy.KeyElementAccessor[]
initializePrimaryKeyFields
(Class<?> keyClass, AbstractSession session) INTERNAL: Cache the bean's primary key fields so speed up creating of primary key objects and initialization of beans.Methods inherited from class org.eclipse.persistence.internal.jpa.CMP3Policy
addReadOnlyMappings, addWritableMapping, clone, convertClassNamesToClasses, createBeanUsingKey, getField, getKeyClassFields, getPKClass, getPKClassInstance, getPKClassName, getPkValueFromKeyForField, initialize, isCMP3Policy, remoteInitialize, setPKClass, setPrimaryKeyClassName
Methods inherited from class org.eclipse.persistence.descriptors.CMPPolicy
createPrimaryKeyInstance, createPrimaryKeyInstanceFromId, createPrimaryKeyInstanceFromPrimaryKeyValues, getClassInstance, getDeferModificationsUntilCommit, getDescriptor, getForceUpdate, getMappedClass, getNonDeferredCreateTime, getPessimisticLockingPolicy, getUpdateAllFields, hasPessimisticLockingPolicy, internalGetForceUpdate, internalGetUpdateAllFields, internalSetForceUpdate, internalSetUpdateAllFields, isSingleKey, setDeferModificationsUntilCommit, setDescriptor, setFieldValue, setForceUpdate, setMappedClass, setNonDeferredCreateTime, setPessimisticLockingPolicy, setUpdateAllFields
-
Constructor Details
-
DynamicIdentityPolicy
public DynamicIdentityPolicy()Default constructor;
-
-
Method Details
-
createPrimaryKeyFromId
Description copied from class:CMP3Policy
INTERNAL: Use the key to create a EclipseLink primary key. If the key is simple (direct mapped) then just add it to a vector, otherwise must go through the inefficient process of copying the key into the bean and extracting the key from the bean.- Overrides:
createPrimaryKeyFromId
in classCMP3Policy
-
initializePrimaryKeyFields
protected CMPPolicy.KeyElementAccessor[] initializePrimaryKeyFields(Class<?> keyClass, AbstractSession session) Description copied from class:CMP3Policy
INTERNAL: Cache the bean's primary key fields so speed up creating of primary key objects and initialization of beans. Note, we have to re-look up the fields for the bean class since these fields may have been loaded with the wrong loader (thank you Kirk). If the key is compound, we also have to look up the fields for the key.- Overrides:
initializePrimaryKeyFields
in classCMP3Policy
-