| Modifier and Type | Class and Description |
|---|---|
| pack-priv static enum | ForeignReferenceMapping.ExtendPessimisticLockScope
Indicates whether and how pessimistic lock scope should be extended |
| Modifier and Type | Field and Description |
|---|---|
| protected BatchFetchType | batchFetchType
Indicates whether the referenced object should always be batch read on read all queries, and defines the type of batch fetch to use. |
| protected boolean | |
| protected boolean | |
| protected boolean | cascadePersist
Cascading flags used by the EntityManager |
| protected boolean | |
| protected boolean | |
| pack-priv ForeignReferenceMapping. | |
| protected boolean | forceInitializationOfSelectionCriteria
This is a way (after cloning) to force the initialization of the selection criteria |
| protected transient boolean | hasCustomSelectionQuery
Indicates whether the selection query is TopLink generated or defined by the user. |
| protected IndirectionPolicy | indirectionPolicy
Implements indirection behavior |
| public static final int | INNER_JOIN
Specify any INNER join on a join fetch. |
| protected boolean | isCascadeOnDeleteSetOnDatabase
Support delete cascading on the database relationship constraint. |
| protected boolean | isPrivateOwned
Indicates whether the referenced object is privately owned or not. |
| protected int | joinFetch
Define if the relationship should always be join fetched. |
| protected String | mappedBy
Stores JPA metadata about whether another mapping is the owning mapping. |
| public static final int | NONE
Specify no join fetch, this is the default. |
| public static final int | OUTER_JOIN
Specify any OUTER join on a join fetch. |
| protected PartitioningPolicy | partitioningPolicy
Allow the mapping's queries to be targeted at specific connection pools. |
| protected String | partitioningPolicyName
Allow the mapping's queries to be targeted at specific connection pools. |
| public static final String | QUERY_BATCH_PARAMETER
Query parameter name used for IN batch ids. |
| protected Class | referenceClass
This is used only in descriptor proxy in remote session |
| protected String | |
| protected transient ClassDescriptor | referenceDescriptor
The descriptor of the reference class. |
| protected DatabaseMapping | relationshipPartner
Used to reference the other half of a bi-directional relationship. |
| protected String | relationshipPartnerAttributeName
Set by users, used to retrieve the backpointer for this mapping |
| protected boolean | requiresTransientWeavedFields
Flag used to determine if we need to weave the transient annotation on weaved fields. |
| protected ReadQuery | selectionQuery
This query is used to read referenced objects for this mapping. |
| protected transient AbstractSession | tempInitSession
The session is temporarily used for initialization. |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public void | addForeignKeyField(DatabaseField sourceForeignKeyField, DatabaseField targetPrimaryKeyField)
INTERNAL: Allow subclass to define a foreign key in the source's table. |
| public void | addTargetForeignKeyField(DatabaseField targetForeignKeyField, DatabaseField sourcePrimaryKeyField)
INTERNAL: Allow subclass to define a foreign key in the target's table. |
| protected Object | batchedValueFromRow(AbstractRecord row, ObjectLevelReadQuery query, CacheKey parentCacheKey)
INTERNAL: Retrieve the value through using batch reading. |
| public void | buildBackupClone(Object
TODO clone, Object TODO backup, UnitOfWorkImpl TODO unitOfWork)Implements abstract org. |
| public abstract Object | buildBackupCloneForPartObject(Object
TODO attributeValue, Object TODO clone, Object TODO backup, UnitOfWorkImpl TODO unitOfWork)Overrides org. |
| protected Expression | buildBatchCriteria(ExpressionBuilder builder, ObjectLevelReadQuery query)
INTERNAL: Return the selection criteria used to IN batch fetching. |
| public void | buildClone(Object
TODO original, CacheKey TODO cacheKey, Object TODO clone, Integer TODO refreshCascade, AbstractSession TODO cloningSession)Implements abstract org. |
| public abstract Object | buildCloneForPartObject(Object
TODO attributeValue, Object TODO original, CacheKey TODO cacheKey, Object TODO clone, AbstractSession TODO cloningSession, Integer TODO refreshCascade, boolean TODO isExisting, boolean TODO isFromSharedCache)Overrides org. |
| public void | buildCloneFromRow(AbstractRecord
TODO databaseRow, JoinedAttributeManager TODO joinManager, Object TODO clone, CacheKey TODO sharedCacheKey, ObjectBuildingQuery TODO sourceQuery, UnitOfWorkImpl TODO unitOfWork, AbstractSession TODO executionSession)Implements abstract org. |
| public abstract Object[] | buildReferencesPKList(Object entity, Object attribute, AbstractSession session)
INTERNAL: This method will access the target relationship and create a list of information to rebuild the relationship. |
| protected Object | checkCacheForBatchKey(AbstractRecord sourceRow, Object foreignKey, Map<K, V> batchObjects, ReadQuery batchQuery, ObjectLevelReadQuery originalQuery, AbstractSession session)
INTERNAL: Check if the target object is in the cache if possible based on the source row. |
| public Object | clone()
Overrides org. |
| public abstract void | collectQueryParameters(Set<DatabaseField>
TODO cacheFields)Overrides org. |
| public boolean | compareObjects(Object
TODO firstObject, Object TODO secondObject, AbstractSession TODO session)Implements abstract org. |
| protected abstract boolean | compareObjectsWithoutPrivateOwned(Object first, Object second, AbstractSession session)
Compare two objects if their parts are not private owned |
| protected abstract boolean | compareObjectsWithPrivateOwned(Object first, Object second, AbstractSession session)
Compare two objects if their parts are private owned |
| public void | convertClassNamesToClasses(ClassLoader
TODO classLoader)Overrides org. |
| public <T> DatabaseValueHolder | createCloneValueHolder(ValueHolderInterface<T>
TODO attributeValue, Object TODO original, Object TODO clone, AbstractRecord TODO row, AbstractSession TODO cloningSession, boolean indicates that we are building the clone directly
from a row as opposed to building the original from the row, putting it in buildDirectlyFromRow)Overrides org. |
| protected boolean | dontDoMerge(Object target, Object source, MergeManager mergeManager)
INTERNAL: Return true if the merge should be bypassed. |
| public void | dontUseBatchReading()
PUBLIC: Indicates whether the referenced object should always be batch read on read all queries. |
| public void | dontUseIndirection()
PUBLIC: Indirection means that a ValueHolder will be put in-between the attribute and the real object. |
| protected void | executeBatchQuery(DatabaseQuery query, CacheKey parentCacheKey, Map<K, V> referenceObjectsByKey, AbstractSession session, AbstractRecord row)
INTERNAL: Prepare and execute the batch query and store the results for each source object in a map keyed by the mappings source keys of the source objects. |
| public void | extendPessimisticLockScopeInSourceQuery(ObjectLevelReadQuery sourceQuery)
INTERNAL: Called if shouldExtendPessimisticLockScopeInSourceQuery is true. |
| protected void | extendPessimisticLockScopeInTargetQuery(ObjectLevelReadQuery targetQuery, ObjectBuildingQuery sourceQuery)
INTERNAL: Called if shouldExtendPessimisticLockScopeInTargetQuery() is true. |
| protected Object | extractBatchKeyFromRow(AbstractRecord targetRow, AbstractSession session)
INTERNAL: Extract the batch key value from the source row. |
| public Object | extractResultFromBatchQuery(ReadQuery batchQuery, CacheKey parentCacheKey, AbstractRecord sourceRow, AbstractSession session, ObjectLevelReadQuery originalQuery)
INTERNAL: Extract the value from the batch optimized query, this should be supported by most query types. |
| public void | fixObjectReferences(Object
TODO object, Map<Object, ObjectDescriptor> TODO objectDescriptors, Map<Object, Object> TODO processedObjects, ObjectLevelReadQuery TODO query, DistributedSession TODO session)Implements abstract org. |
| public Object | getAttributeValueFromObject(Object
TODO object)Overrides org. |
| public Object | getAttributeValueWithClonedValueHolders(Object object)
INTERNAL: Returns the attribute value from the reference object. |
| public BatchFetchType | getBatchFetchType()
PUBLIC: Return the type of batch fetching to use for all queries for this class if configured. |
| protected ReadQuery | getExtendPessimisticLockScopeDedicatedQuery(AbstractSession session, short lockMode)
INTERNAL: Should be overridden by subclass that allows setting extendPessimisticLockScope to DEDICATED_QUERY. |
| public Collection | getFieldsForTranslationInAggregate()
INTERNAL: Return source key fields for translation by an AggregateObjectMapping By default, return an empty NonSynchronizedVector |
| public IndirectionPolicy | |
| public Expression | getJoinCriteria(ObjectExpression context, Expression base)
INTERNAL: Returns the join criteria stored in the mapping selection query. |
| public int | |
| public String | |
| public Object | getObjectCorrespondingTo(Object
TODO object, DistributedSession TODO session, Map<Object, ObjectDescriptor> TODO objectDescriptors, Map<Object, Object> TODO processedObjects, ObjectLevelReadQuery TODO query)Overrides org. |
| public List | getOrderByNormalizedExpressions(Expression base)
Overrides org. |
| public PartitioningPolicy | |
| public String | |
| public Object | getRealAttributeValueFromAttribute(Object attributeValue, Object object, AbstractSession session)
Overrides org. |
| public Class | |
| public String | |
| public ClassDescriptor | getReferenceDescriptor()
Overrides org. |
| public DatabaseMapping | getRelationshipPartner()
Overrides org. |
| public String | getRelationshipPartnerAttributeName()
PUBLIC: Use this method retrieve the relationship partner attribute name of this bidirectional Mapping. |
| public Expression | getSelectionCriteria()
INTERNAL: Returns the selection criteria stored in the mapping selection query. |
| public ReadQuery | |
| protected AbstractSession | |
| public Object | getValueFromRemoteValueHolder(RemoteValueHolder<T> remoteValueHolder)
Overrides org. |
| public boolean | hasCustomSelectionQuery()
INTERNAL: Indicates whether the selection query is TopLink generated or defined by the user. |
| public boolean | hasDependency()
Overrides org. |
| public boolean | hasNestedIdentityReference()
Overrides org. |
| public void | initialize(AbstractSession session)
Overrides org. |
| protected void | initializeReferenceDescriptor(AbstractSession session)
Initialize and set the descriptor for the referenced class in this mapping. |
| protected void | initializeSelectionQuery(AbstractSession session)
A subclass should implement this method if it wants non default behavior. |
| public void | instantiateAttribute(Object object, AbstractSession session)
Overrides org. |
| public boolean | isAttributeValueFromObjectInstantiated(Object object)
Overrides org. |
| public boolean | isAttributeValueFullyBuilt(Object object)
INTERNAL: The method validateAttributeOfInstantiatedObject(Object attributeValue) fixes the value of the attributeValue in cases where it is null and indirection requires that it contain some specific data structure. |
| public boolean | isAttributeValueInstantiated(Object object)
INTERNAL: The referenced object is checked if it is instantiated or not |
| public boolean | |
| public boolean | |
| public boolean | isCascadeOnDeleteSetOnDatabase()
ADVANCED: Return if delete cascading has been set on the database for the mapping's foreign key constraint. |
| public boolean | |
| public boolean | |
| public boolean | |
| protected boolean | isExtendingPessimisticLockScope(ObjectBuildingQuery sourceQuery)
INTERNAL: Indicates whether the source query's pessimistic lock scope scope should be extended in the target query. |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | isJoiningSupported()
Overrides org. |
| public boolean | isLazy()
Overrides org. |
| public boolean | isLockableMapping()
Overrides org. |
| public boolean | |
| public boolean | isPrivateOwned()
Overrides org. |
| public void | iterate(DescriptorIterator iterator)
Implements abstract org. |
| public abstract void | iterateOnRealAttributeValue(DescriptorIterator iterator, Object realAttributeValue)
Overrides org. |
| public void | load(final Object object, AttributeItem item, final AbstractSession session, final boolean fromFetchGroup)
Overrides org. |
| public void | mergeRemoteValueHolder(Object clientSideDomainObject, Object serverSideDomainObject, MergeManager mergeManager)
INTERNAL: Replace the client value holder with the server value holder, after copying some of the settings from the client value holder. |
| protected void | postPrepareNestedBatchQuery(ReadQuery batchQuery, ObjectLevelReadQuery query)
INTERNAL: Allow the mapping the do any further batch preparation. |
| public void | preInitialize(AbstractSession session)
Overrides org. |
| protected ReadQuery | prepareHistoricalQuery(ReadQuery targetQuery, ObjectBuildingQuery sourceQuery, AbstractSession executionSession)
INTERNAL: Allow for the mapping to perform any historical query additions. |
| public ReadQuery | prepareNestedBatchQuery(ObjectLevelReadQuery query)
INTERNAL: Clone and prepare the selection query as a nested batch read query. |
| protected ObjectLevelReadQuery | prepareNestedJoinQueryClone(AbstractRecord row, List<E> dataResults, JoinedAttributeManager joinManager, ObjectBuildingQuery sourceQuery, AbstractSession executionSession)
INTERNAL: Prepare the clone of the nested query for joining. |
| public ObjectLevelReadQuery | prepareNestedJoins(JoinedAttributeManager joinManager, ObjectBuildingQuery baseQuery, AbstractSession session)
INTERNAL: Clone and prepare the JoinedAttributeManager nested JoinedAttributeManager. |
| public void | |
| public Object | readFromRowIntoObject(AbstractRecord databaseRow, JoinedAttributeManager joinManager, Object targetObject, CacheKey parentCacheKey, ObjectBuildingQuery sourceQuery, AbstractSession executionSession, boolean isTargetProtected)
Overrides org. |
| public void | remoteInitialization(DistributedSession session)
Overrides org. |
| public Map | replaceValueHoldersIn(Object object, RemoteSessionController controller)
Overrides org. |
| public boolean | requiresTransientWeavedFields()
Returns true if this mappings associated weaved field requires a transient setting to avoid metadata processing. |
| public void | setBatchFetchType(BatchFetchType batchFetchType)
PUBLIC: Set the type of batch fetching to use for all queries for this class. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | setCustomSelectionQuery(ReadQuery query)
PUBLIC: Relationship mappings creates a read query to read reference objects. |
| public void | setForceInitializationOfSelectionCriteria(boolean bool)
INTERNAL: A way of forcing the selection criteria to be rebuilt. |
| protected void | |
| public void | |
| public void | setIsCacheable(boolean cacheable)
Overrides org. |
| public void | setIsCascadeOnDeleteSetOnDatabase(boolean isCascadeOnDeleteSetOnDatabase)
ADVANCED: Set if delete cascading has been set on the database for the mapping's foreign key constraint. |
| public void | |
| public void | setJoinFetch(int joinFetch)
PUBLIC: Indicates whether the referenced object(s) should always be joined on read queries. |
| public void | setMappedBy(String mappedBy)
INTERNAL: Called by JPA metadata processing to store the owning mapping for this mapping |
| public void | setPartitioningPolicy(PartitioningPolicy partitioningPolicy)
PUBLIC: Set the mapping's partitioning policy. |
| public void | setPartitioningPolicyName(String partitioningPolicyName)
PUBLIC: Set the name of the mapping's partitioning policy. |
| public void | setRealAttributeValueInObject(Object object, Object value)
Overrides org. |
| public void | |
| public void | |
| protected void | |
| public void | setRelationshipPartner(DatabaseMapping mapping)
INTERNAL: Sets the relationshipPartner mapping for this bi-directional mapping. |
| public void | setRelationshipPartnerAttributeName(String attributeName)
PUBLIC: Use this method to specify the relationship partner attribute name of a bidirectional Mapping. |
| public void | setRequiresTransientWeavedFields(boolean requiresTransientWeavedFields)
Set this flag if this mappings associated weaved field requires a transient setting to avoid metadata processing. |
| public void | setSelectionCall(Call call)
PUBLIC: This is a property on the mapping which will allow custom call to be substituted for reading a reference object. |
| public void | setSelectionCriteria(Expression anExpression)
PUBLIC: Sets the selection criteria to be used as a where clause to read reference objects. |
| protected void | |
| public void | setSelectionSQLString(String sqlString)
PUBLIC: This is a property on the mapping which will allow custom SQL to be substituted for reading a reference object. |
| public void | setShouldExtendPessimisticLockScope(boolean shouldExtend)
ADVANCED: Indicates whether pessimistic lock of ObjectLevelReadQuery with isPessimisticLockScopeExtended set to true should be applied through this mapping beyond the tables mapped to the source object. |
| protected void | |
| public void | setUsesBatchReading(boolean usesBatchReading)
PUBLIC: Indicates whether the referenced object should always be batch read on read all queries. |
| public void | setUsesIndirection(boolean usesIndirection)
PUBLIC: Indirection means that a ValueHolder will be put in-between the attribute and the real object. |
| public boolean | shouldExtendPessimisticLockScope()
INTERNAL: Indicates whether pessimistic lock of ObjectLevelReadQuery with isPessimisticLockScopeExtended set to true should be applied through this mapping beyond the tables mapped to the source object. |
| public boolean | |
| public boolean | |
| public boolean | |
| protected boolean | |
| protected boolean | |
| public boolean | shouldMergeCascadeParts(MergeManager mergeManager)
INTERNAL: Returns true if the merge should cascade to the mappings reference's parts. |
| protected boolean | shouldMergeCascadeReference(MergeManager mergeManager)
Returns true if the merge should cascade to the mappings reference. |
| protected boolean | shouldObjectModifyCascadeToParts(ObjectLevelModifyQuery query)
Returns true if any process leading to object modification should also affect its parts Usually used by write, insert, update and delete. |
| public boolean | shouldRefreshCascadeParts(MergeManager mergeManager)
INTERNAL: Returns true if the merge should cascade to the mappings reference's parts. |
| public boolean | shouldUseBatchReading()
PUBLIC: Indicates whether the referenced object should always be batch read on read all queries. |
| protected boolean | shouldUseValueFromRowWithJoin(JoinedAttributeManager joinManager, ObjectBuildingQuery sourceQuery)
INTERNAL: Indicates whether valueFromRow should call valueFromRowInternalWithJoin (true) or valueFromRowInternal (false) |
| public AbstractRecord | trimRowForJoin(AbstractRecord row, JoinedAttributeManager joinManager, AbstractSession executionSession)
INTERNAL: Return a sub-partition of the row starting at the index for the mapping. |
| public AbstractRecord | trimRowForJoin(AbstractRecord row, Object value, AbstractSession executionSession)
INTERNAL: Return a sub-partition of the row starting at the index. |
| public abstract void | updateChangeRecordForSelfMerge(ChangeRecord changeRecord, Object source, Object target, UnitOfWorkChangeSet parentUOWChangeSet, UnitOfWorkImpl unitOfWork)
INTERNAL: Update a ChangeRecord to replace the ChangeSet for the old entity with the changeSet for the new Entity. |
| public void | useBasicIndirection()
PUBLIC: Indirection means that a ValueHolder will be put in-between the attribute and the real object. |
| public void | useBatchReading()
PUBLIC: Indicates whether the referenced object should always be batch read on read all queries. |
| public void | useContainerIndirection(Class<?> containerClass)
PUBLIC: Indirection means that a IndirectContainer (wrapping a ValueHolder) will be put in-between the attribute and the real object. |
| public void | |
| public void | |
| public boolean | usesIndirection()
PUBLIC: Indirection means that some sort of indirection object will be put in-between the attribute and the real object. |
| public void | useWeavedIndirection(String
is the name of the original (or weaved in field access case) set method for the mapping. getMethodName, String is the name of the original (or weaved in field access case) set method for the mapping. setMethodName, boolean indicates whether method or field access was originally used. hasUsedMethodAccess)INTERNAL: Configures the mapping to used weaved indirection. |
| public void | validateBeforeInitialization(AbstractSession session)
Overrides org. |
| public abstract Object | valueFromPKList(Object[] pks, AbstractRecord foreignKeys, AbstractSession session)
This method is used to load a relationship from a list of PKs. |
| public Object | valueFromRow(AbstractRecord row, JoinedAttributeManager joinManager, ObjectBuildingQuery sourceQuery, CacheKey cacheKey, AbstractSession executionSession, boolean isTargetProtected, Boolean[] wasCacheUsed)
Overrides org. |
| protected Object | valueFromRowInternal(AbstractRecord row, JoinedAttributeManager joinManager, ObjectBuildingQuery sourceQuery, AbstractSession executionSession)
INTERNAL: Return the value of the reference attribute or a value holder. |
| protected Object | valueFromRowInternal(AbstractRecord row, JoinedAttributeManager joinManager, ObjectBuildingQuery sourceQuery, AbstractSession executionSession, boolean
indicates whether sopObject stored in the row should be used to extract the value (and fields/values stored in the row ignored). shouldUseSopObject)INTERNAL: Return the value of the reference attribute or a value holder. |
| protected Object | valueFromRowInternalWithJoin(AbstractRecord row, JoinedAttributeManager joinManager, ObjectBuildingQuery sourceQuery, CacheKey parentCacheKey, AbstractSession executionSession, boolean isTargetProtected)
INTERNAL: If the query used joining or partial attributes, build the target object directly. |