Class ClassDescriptor
- java.lang.Object
-
- org.eclipse.persistence.core.descriptors.CoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
- org.eclipse.persistence.descriptors.ClassDescriptor
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable
- Direct Known Subclasses:
EISDescriptor,RelationalDescriptor,XMLDescriptor
public class ClassDescriptor extends CoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder> implements java.lang.Cloneable, java.io.Serializable
Purpose: Abstract descriptor class for defining persistence information on a class. This class provides the data independent behavior and is subclassed, for relational, object-relational, EIS, XML, etc.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<AttributeAccessor>accessorTreeA list of AttributeAccessors in order of access from root to leaf to arrive at current AggregateDescriptor.protected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>additionalAggregateCollectionKeyFieldsused by aggregate descriptors to hold additional fields needed when they are stored in an AggregatateCollection These fields are generally foreign key fields that are required in addition to the fields in the descriptor's mappings to uniquely identify the Aggregateprotected java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Map<org.eclipse.persistence.internal.helper.DatabaseField,org.eclipse.persistence.internal.helper.DatabaseField>>additionalTablePrimaryKeyFieldsprotected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>additionalWritableMapKeyFieldsstores fields that are written by Map key mappings so they can be checked for multiple writable mappingsprotected static intAGGREGATEprotected static intAGGREGATE_COLLECTIONprotected java.lang.Stringaliasprotected java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>allFieldsprotected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>allSelectionFieldsprotected java.lang.ClassamendmentClassprotected java.lang.StringamendmentClassNameprotected java.lang.StringamendmentMethodNameprotected CacheInvalidationPolicycacheInvalidationPolicyprotected CachePolicycachePolicyprotected booleancascadedLockingInitializedINTERNAL: flag to indicate the initialization state of cascade locking for this descriptorprotected java.util.List<org.eclipse.persistence.internal.descriptors.CascadeLockingPolicy>cascadeLockingPoliciesprotected ObjectChangePolicychangePolicyprotected CMPPolicycmpPolicyprotected java.util.VectorconstraintDependenciesprotected CopyPolicycopyPolicyprotected java.lang.StringcopyPolicyClassNameprotected QueryRedirectordefaultDeleteObjectQueryRedirectorprotected java.lang.StringdefaultDeleteObjectQueryRedirectorClassNameprotected QueryRedirectordefaultInsertObjectQueryRedirectorprotected java.lang.StringdefaultInsertObjectQueryRedirectorClassNameprotected QueryRedirectordefaultQueryRedirectorprotected java.lang.StringdefaultQueryRedirectorClassNameprotected QueryRedirectordefaultReadAllQueryRedirectorprotected java.lang.StringdefaultReadAllQueryRedirectorClassNameprotected QueryRedirectordefaultReadObjectQueryRedirectorprotected java.lang.StringdefaultReadObjectQueryRedirectorClassNameprotected QueryRedirectordefaultReportQueryRedirectorprotected java.lang.StringdefaultReportQueryRedirectorClassNameprotected org.eclipse.persistence.internal.helper.DatabaseTabledefaultTableprotected QueryRedirectordefaultUpdateObjectQueryRedirectorprotected java.lang.StringdefaultUpdateObjectQueryRedirectorClassNameprotected java.util.Map<java.lang.String,DatabaseMapping>derivesIdMappingsprotected java.lang.StringdescriptorCustomizerClassNameJPA DescriptorCustomizer list stored here to preserve it when caching the projectprotected intdescriptorTypestatic intDO_NOT_SEND_CHANGESprotected static intERRORprotected FetchGroupManagerfetchGroupManagerprotected java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>fieldsprotected java.util.Set<org.eclipse.persistence.internal.helper.DatabaseField>foreignKeyValuesForCachingStores a set of FK fields that will be cached to later retrieve noncacheable mappingsprotected booleanhasMultipleTableConstraintDependecyDefines if any mapping reference a field in a secondary table.protected booleanhasNoncacheableMappingscaches if this descriptor has any non cacheable mappingsprotected booleanhasRelationshipswhether this descriptor has any relationships through its mappings, through inheritance, or through aggregatesprotected booleanhasSimplePrimaryKeyPERF: Compute and store if the primary key is simple (direct-mapped) to allow fast extraction.protected HistoryPolicyhistoryPolicyprotected IdValidationidValidationAllow zero primary key validation to be configured.protected intinitializationStageprotected static intINITIALIZEDprotected static intINTERFACEprotected intinterfaceInitializationStageprotected InterfacePolicyinterfacePolicystatic intINVALIDATE_CHANGED_OBJECTSprotected booleanisCascadeOnDeleteSetOnDatabaseOnSecondaryTablesSupport delete cascading on the database for multiple and inheritance tables.protected booleanisNativeConnectionRequiredAllow connection unwrapping to be configured.static intISOLATE_CACHE_AFTER_TRANSACTIONstatic intISOLATE_CACHE_ALWAYSstatic intISOLATE_FROM_CLIENT_SESSIONstatic intISOLATE_NEW_DATA_AFTER_TRANSACTIONprotected java.lang.ClassjavaClassprotected java.lang.StringjavaClassNameprotected java.util.List<DatabaseMapping>lockableMappingsprotected java.util.Vector<DatabaseMapping>mappingsprotected java.util.List<DatabaseMapping>mappingsPostCalculateChangesMappings that require postCalculateChanges method to be calledprotected java.util.List<DatabaseMapping>mappingsPostCalculateChangesOnDeletedMappings that require postCalculateChangesOnDeleted method to be calledprotected java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Set<org.eclipse.persistence.internal.helper.DatabaseTable>>multipleTableForeignKeysprotected java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable>multipleTableInsertOrderprotected MultitenantPolicymultitenantPolicyprotected static intNORMALDefine valid descriptor types.protected org.eclipse.persistence.internal.descriptors.OptimisticLockingPolicyoptimisticLockingPolicyprotected PartitioningPolicypartitioningPolicyprotected java.lang.StringpartitioningPolicyNameprotected static intPOST_INITIALIZEDprotected java.util.List<DatabaseMapping>preDeleteMappingsstores a list of mappings that require preDelete as a group prior to the delete individuallyprotected static intPREINITIALIZEDprotected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>primaryKeyFieldsprotected java.util.List<IdValidation>primaryKeyIdValidationsAllow zero primary key validation to be configured per field.protected java.util.MappropertiesAdditional properties may be added.protected java.util.Map<java.lang.String,QueryKey>queryKeysprotected DescriptorQueryManagerqueryManagerprotected java.util.Set<ClassDescriptor>referencingClassesprotected java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>returnFieldsToGenerateInsertprotected java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>returnFieldsToGenerateUpdateprotected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>returnFieldsToMergeInsertprotected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>returnFieldsToMergeUpdateprotected java.util.List<ReturningPolicy>returningPoliciesprotected ReturningPolicyreturningPolicyprotected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>selectionFieldsstatic intSEND_NEW_OBJECTS_WITH_CHANGESstatic intSEND_OBJECT_CHANGESprotected SequencesequenceStore the Sequence used for the descriptor.protected org.eclipse.persistence.internal.helper.DatabaseFieldsequenceNumberFieldprotected java.lang.StringsequenceNumberNameprotected SerializedObjectPolicyserializedObjectPolicyprotected java.lang.StringsessionNameprotected booleanshouldAcquireCascadedLocksPERF: Used to optimize cache locking to only acquire deferred locks when required (no-indirection).protected booleanshouldAlwaysConformResultsInUnitOfWorkprotected booleanshouldBeReadOnlyprotected booleanshouldLockForCloneThis flag controls if a UOW should acquire locks for clone or simple clone the instance passed to registerExistingObject.protected booleanshouldOrderMappingsprotected booleanshouldRegisterResultsInUnitOfWorkstatic booleanshouldUseFullChangeSetsForNewObjectsINTERNAL: Backdoor for using changes sets for new objects.protected java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseTable>tablesprotected java.util.Map<java.lang.String,java.util.List<java.lang.String>>unconvertedPropertiesAllow the user to defined un-converted properties which will be initialized at runtime.static intUNDEFINED_ISOLATATIONstatic intUNDEFINED_OBJECT_CHANGE_BEHAVIORprotected static intUNINITIALIZEDThe following are the [initializationStage] states the descriptor passes through during the initialization.static intUSE_SESSION_CACHE_AFTER_TRANSACTIONprotected java.util.List<org.eclipse.persistence.internal.descriptors.VirtualAttributeMethodInfo>virtualAttributeMethodsA list of methods that are used by virtual mappings.protected booleanweavingUsesPropertyAccessThis flag stores whether this descriptor is using Property access based on JPA semantics.protected WrapperPolicywrapperPolicy-
Fields inherited from class org.eclipse.persistence.core.descriptors.CoreDescriptor
attributeGroups, eventManager, field, inheritancePolicy, instantiationPolicy, objectBuilder
-
-
Constructor Summary
Constructors Constructor Description ClassDescriptor()PUBLIC: Return a new descriptor.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidaddAbstractQueryKey(java.lang.String queryKeyName)PUBLIC: This method should only be used for interface descriptors.voidaddCascadeLockingPolicy(org.eclipse.persistence.internal.descriptors.CascadeLockingPolicy policy)INTERNAL: Add the cascade locking policy to all children that have a relationship to this descriptor either by inheritance or by encapsulation/aggregation.voidaddConstraintDependencies(java.lang.Class dependencies)ADVANCED: EclipseLink automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings.voidaddConstraintDependency(java.lang.Class dependencies)ADVANCED: EclipseLink automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings.DatabaseMappingaddDirectMapping(java.lang.String attributeName, java.lang.String fieldName)PUBLIC: Add a direct to field mapping to the receiver.DatabaseMappingaddDirectMapping(java.lang.String attributeName, java.lang.String getMethodName, java.lang.String setMethodName, java.lang.String fieldName)PUBLIC: Add a direct to field mapping to the receiver.voidaddDirectQueryKey(java.lang.String queryKeyName, java.lang.String fieldName)PUBLIC: Add a query key to the descriptor.voidaddForeignKeyFieldForMultipleTable(org.eclipse.persistence.internal.helper.DatabaseField sourceForeignKeyField, org.eclipse.persistence.internal.helper.DatabaseField targetPrimaryKeyField)PUBLIC: This protocol can be used to associate multiple tables with foreign key information.voidaddForeignKeyFieldNameForMultipleTable(java.lang.String sourceForeignKeyFieldName, java.lang.String targetPrimaryKeyFieldName)PUBLIC: This protocol can be used to associate multiple tables with foreign key information.DatabaseMappingaddMapping(DatabaseMapping mapping)PUBLIC: Add a database mapping to the receiver.voidaddMappingsPostCalculateChanges(DatabaseMapping mapping)Add a mapping to the list of mappings that require postCalculateChanges method to be called.voidaddMappingsPostCalculateChangesOnDeleted(DatabaseMapping mapping)Add a mapping to the list of mappings that require mappingsPostCalculateChangesOnDeleted method to be called.voidaddPreDeleteMapping(DatabaseMapping mapping)INTERNAL: Add the mapping to be notified before deletion.voidaddPrimaryKeyField(org.eclipse.persistence.internal.helper.DatabaseField field)ADVANCED: Specify the primary key field of the descriptors table.voidaddPrimaryKeyFieldName(java.lang.String fieldName)PUBLIC: Specify the primary key field of the descriptors table.voidaddQueryKey(QueryKey queryKey)PUBLIC: Add a query key to the descriptor.voidaddTable(org.eclipse.persistence.internal.helper.DatabaseTable table)PUBLIC: Specify the table for the class of objects the receiver describes.voidaddTableName(java.lang.String tableName)PUBLIC: Specify the table name for the class of objects the receiver describes.voidaddUnconvertedProperty(java.lang.String propertyName, java.lang.String propertyValue, java.lang.String propertyType)PUBLIC: Add an unconverted property (to be initialiazed at runtime)voidadjustMultipleTableInsertOrder()INTERNAL: Adjust the order of the tables in the multipleTableInsertOrder Vector according to the FK relationship if one (or more) were previously specified.voidalwaysConformResultsInUnitOfWork()PUBLIC: Used to set the descriptor to always conform in any unit of work query.voidalwaysRefreshCache()PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCache(boolean)with an argument oftrue: it configures aClassDescriptorto always refresh the cache if data is received from the database by any query.voidalwaysRefreshCacheOnRemote()PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCacheOnRemote(boolean)with an argument oftrue: it configures aClassDescriptorto always remotely refresh the cache if data is received from the database by any query in aRemoteSession.voidapplyAmendmentMethod()ADVANCED: Call the descriptor amendment method.voidapplyAmendmentMethod(DescriptorEvent event)INTERNAL: Call the descriptor amendment method.booleanarePrimaryKeyFields(java.util.Vector fields)INTERNAL: Used to determine if a foreign key references the primary key.protected voidassignDefaultValues(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Some attributes have default values defined in Project.ExpressionbuildBatchCriteriaByPK(ExpressionBuilder builder, ObjectLevelReadQuery query)INTERNAL: Return the selection criteria used to IN batch fetching.org.eclipse.persistence.internal.databaseaccess.DatasourceCallbuildCallFromStatement(org.eclipse.persistence.internal.expressions.SQLStatement statement, DatabaseQuery query, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Return a call built from a statement.java.util.VectorbuildDirectValuesFromFieldValue(java.lang.Object fieldValue)INTERNAL: Extract the direct values from the specified field value.org.eclipse.persistence.internal.helper.DatabaseFieldbuildField(java.lang.String fieldName)INTERNAL: A DatabaseField is built from the given field name.org.eclipse.persistence.internal.helper.DatabaseFieldbuildField(org.eclipse.persistence.internal.helper.DatabaseField field)INTERNAL: The table of the field is ensured to be unique from the descriptor's tables.org.eclipse.persistence.internal.helper.DatabaseFieldbuildField(org.eclipse.persistence.internal.helper.DatabaseField field, org.eclipse.persistence.internal.helper.DatabaseTable relationTable)java.lang.ObjectbuildFieldValueFromDirectValues(java.util.Vector directValues, java.lang.String elementDataTypeName, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Build the appropriate field value for the specified set of direct values.java.lang.ObjectbuildFieldValueFromForeignKeys(java.util.Vector foreignKeys, java.lang.String referenceDataTypeName, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Build and return the appropriate field value for the specified set of foreign keys (i.e. each row has the fields that make up a foreign key).java.lang.ObjectbuildFieldValueFromNestedRow(org.eclipse.persistence.internal.sessions.AbstractRecord nestedRow, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Build and return the field value from the specified nested database row.java.lang.ObjectbuildFieldValueFromNestedRows(java.util.Vector nestedRows, java.lang.String structureName, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Build and return the appropriate field value for the specified set of nested rows.org.eclipse.persistence.internal.sessions.AbstractRecordbuildNestedRowFromFieldValue(java.lang.Object fieldValue)INTERNAL: Build and return the nested database row from the specified field value.java.util.VectorbuildNestedRowsFromFieldValue(java.lang.Object fieldValue, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Build and return the nested rows from the specified field value.protected voidcheckDatabase(org.eclipse.persistence.internal.sessions.AbstractSession session)To check that tables and fields are present in databasevoidcheckInheritanceTreeAggregateSettings(org.eclipse.persistence.internal.sessions.AbstractSession session, AggregateMapping mapping)INTERNAL: Verify that an aggregate descriptor's inheritance tree is full of aggregate descriptors.voidclearReferencingClasses()INTERNAL: Cleans referencingClasses set.java.lang.Objectclone()INTERNAL: Clones the descriptorvoidconvertClassNamesToClasses(java.lang.ClassLoader classLoader)INTERNAL: Convert all the class-name-based settings in this Descriptor to actual class-based settings.voidcreateCopyPolicy(java.lang.String policyType)PUBLIC: Create a copy policy of the type passed in as a string.voidcreateInstantiationPolicy(java.lang.String policyType)PUBLIC: Create a instantiation policy of the type passed in as a string.protected voidcreateMultipleTableInsertOrder()INTERNAL: Create multiple table insert order.protected voidcreateMultipleTableInsertOrderFromComparison(int[][] tableComparison, int nStart)INTERNAL: This helper method creates multipleTableInsertOrderFromComparison using comparison matrix created by createTableComparison(getTables()) method call.protected int[][]createTableComparison(java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable> tables, int nStart)INTERNAL: This helper method creates a matrix that contains insertion order comparison for the tables.protected booleancreateTableOrder(int k, int nTables, int[] tableOrder, int[][] tableComparison)INTERNAL: This helper method recursively puts indexes from 0 to nTables-1 into tableOrder according to tableComparison 2 dim array.voiddescriptorIsAggregate()PUBLIC: Sets the descriptor to be an aggregate.voiddescriptorIsAggregateCollection()PUBLIC: Sets the descriptor to be part of an aggregate collection.voiddescriptorIsForInterface()PUBLIC: Sets the descriptor to be for an interface.voiddescriptorIsNormal()PUBLIC: Sets the descriptor to be normal.voiddisableCacheHits()PUBLIC: Allow for cache hits on primary key read object queries to be disabled.voiddisableCacheHitsOnRemote()PUBLIC: Allow for remote session cache hits on primary key read object queries to be disabled.voiddontAlwaysConformResultsInUnitOfWork()PUBLIC: The descriptor is defined to not conform the results in unit of work in read query.voiddontAlwaysRefreshCache()PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCache(boolean)with an argument offalse: it ensures that aClassDescriptoris not configured to always refresh the cache if data is received from the database by any query.voiddontAlwaysRefreshCacheOnRemote()PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCacheOnRemote(boolean)with an argument offalse: it ensures that aClassDescriptoris not configured to always remotely refresh the cache if data is received from the database by any query in aRemoteSession.voiddontDisableCacheHits()PUBLIC: Allow for cache hits on primary key read object queries.voiddontDisableCacheHitsOnRemote()PUBLIC: Allow for remote session cache hits on primary key read object queries.voiddontOnlyRefreshCacheIfNewerVersion()PUBLIC: This method is the equivalent of callingsetShouldOnlyRefreshCacheIfNewerVersion(boolean)with an argument offalse: it ensures that aClassDescriptoris not configured to only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field).protected org.eclipse.persistence.internal.helper.DatabaseTableextractDefaultTable()INTERNAL: The first table in the tables is always treated as default.java.util.List<AttributeAccessor>getAccessorTree()java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getAdditionalAggregateCollectionKeyFields()INTERNAL: additionalAggregateCollectionKeyFields are used by aggregate descriptors to hold additional fields needed when they are stored in an AggregatateCollection These fields are generally foreign key fields that are required in addition to the fields in the descriptor's mappings to uniquely identify the Aggregatejava.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Map<org.eclipse.persistence.internal.helper.DatabaseField,org.eclipse.persistence.internal.helper.DatabaseField>>getAdditionalTablePrimaryKeyFields()INTERNAL: This is used to map the primary key field names in a multiple table descriptor.java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getAdditionalWritableMapKeyFields()INTERNAL: Return a list of fields that are written by map keys Used to determine if there is a multiple writable mappings issuejava.lang.StringgetAlias()PUBLIC: Get the aliasjava.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>getAllFields()INTERNAL: Return all the fields which include all child class fields.java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getAllSelectionFields()INTERNAL: Return all selection fields which include all child class fields.java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getAllSelectionFields(ObjectLevelReadQuery query)INTERNAL: Return all selection fields which include all child class fields.java.lang.ClassgetAmendmentClass()PUBLIC: Return the amendment class.java.lang.StringgetAmendmentClassName()INTERNAL: Return amendment class name, used by the MW.java.lang.StringgetAmendmentMethodName()PUBLIC: Return the amendment method.AttributeGroupgetAttributeGroup(java.lang.String name)PUBLIC: Returns the attribute group corresponding to the name provided.java.util.Map<java.lang.String,AttributeGroup>getAttributeGroups()ADVANCED: Returns the attribute groups for this Descriptor.java.lang.ClassgetCacheInterceptorClass()A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor.java.lang.StringgetCacheInterceptorClassName()A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor.CacheInvalidationPolicygetCacheInvalidationPolicy()PUBLIC: Return the CacheInvalidationPolicy for this descriptor For uninitialized cache invalidation policies, this will return a NoExpiryCacheInvalidationPolicyCacheIsolationTypegetCacheIsolation()PUBLIC: Controls how the Entity instances will be cached.CacheKeyTypegetCacheKeyType()ADVANCED: Return what cache key type to use to store the object in the cache.CachePolicygetCachePolicy()Return the cache policy.intgetCacheSynchronizationType()PUBLIC: Get a value indicating the type of cache synchronization that will be used on objects of this type.java.util.List<org.eclipse.persistence.internal.descriptors.CascadeLockingPolicy>getCascadeLockingPolicies()INTERNAL:CMPPolicygetCMPPolicy()ADVANCED: Return the cmp descriptor that holds cmp specific information.java.util.VectorgetConstraintDependencies()ADVANCED: automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings.CopyPolicygetCopyPolicy()INTERNAL: Returns the copy policy.java.lang.StringgetCopyPolicyClassName()INTERNAL: Returns the name of a Class that implements CopyPolicy Will be instantiated as a copy policy at initialization times using the no-args constructorQueryRedirectorgetDefaultDeleteObjectQueryRedirector()A Default DeleteObjectQuery Redirector will be applied to any executing DeleteObjectQuery or DeleteAllQuery that does not have a redirector set directly on the query.FetchGroupgetDefaultFetchGroup()INTERNAL: Return the default fetch group on the descriptor.QueryRedirectorgetDefaultInsertObjectQueryRedirector()A Default InsertObjectQuery Redirector will be applied to any executing InsertObjectQuery that does not have a redirector set directly on the query.QueryRedirectorgetDefaultQueryRedirector()A Default Query Redirector will be applied to any executing object query that does not have a more precise default (like the default ReadObjectQuery Redirector) or a redirector set directly on the query.QueryRedirectorgetDefaultReadAllQueryRedirector()A Default ReadAllQuery Redirector will be applied to any executing ReadAllQuery that does not have a redirector set directly on the query.QueryRedirectorgetDefaultReadObjectQueryRedirector()A Default ReadObjectQuery Redirector will be applied to any executing ReadObjectQuery that does not have a redirector set directly on the query.QueryRedirectorgetDefaultReportQueryRedirector()A Default ReportQuery Redirector will be applied to any executing ReportQuery that does not have a redirector set directly on the query.org.eclipse.persistence.internal.helper.DatabaseTablegetDefaultTable()INTERNAL: The first table in the tables is always treated as default.QueryRedirectorgetDefaultUpdateObjectQueryRedirector()A Default UpdateObjectQuery Redirector will be applied to any executing UpdateObjectQuery or UpdateAllQuery that does not have a redirector set directly on the query.java.util.Collection<DatabaseMapping>getDerivesIdMappinps()ADVANCED: Return the derives id mappings.java.lang.StringgetDescriptorCustomizerClassName()INTERNAL: DescriptorCustomizer is the JPA equivalent of an amendment method.DescriptorEventManagergetDescriptorEventManager()PUBLIC: Get the event manager for the descriptor.InheritancePolicygetDescriptorInheritancePolicy()PUBLIC: The inheritance policy is used to define how a descriptor takes part in inheritance.DescriptorQueryManagergetDescriptorQueryManager()PUBLIC: Return the queryManager.intgetDescriptorType()ADVANCED: return the descriptor type (NORMAL by default, others include INTERFACE, AGGREGATE, AGGREGATE COLLECTION)java.lang.StringgetDescriptorTypeValue()INTERNAL: This method is explicitly used by the XML reader.DescriptorEventManagergetEventManager()PUBLIC: Get the event manager for the descriptor.FetchGroupManagergetFetchGroupManager()PUBLIC: Get the fetch group manager for the descriptor.java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>getFields()INTERNAL: Return all the fieldsjava.util.Set<org.eclipse.persistence.internal.helper.DatabaseField>getForeignKeyValuesForCaching()INTERNAL:booleangetFullyMergeEntity()HistoryPolicygetHistoryPolicy()PUBLIC: Return this descriptor's HistoryPolicy.java.lang.ClassgetIdentityMapClass()INTERNAL: Return the class of identity map to be used by this descriptor.intgetIdentityMapSize()PUBLIC: Return the size of the identity map.IdValidationgetIdValidation()ADVANCED: Return what types are allowed as a primary key (id).InheritancePolicygetInheritancePolicy()PUBLIC: The inheritance policy is used to define how a descriptor takes part in inheritance.InheritancePolicygetInheritancePolicyOrNull()INTERNAL: Return the inheritance policy.org.eclipse.persistence.internal.descriptors.InstantiationPolicygetInstantiationPolicy()INTERNAL: Returns the instantiation policy.InterfacePolicygetInterfacePolicy()PUBLIC: Returns the InterfacePolicy.InterfacePolicygetInterfacePolicyOrNull()INTERNAL: Returns the InterfacePolicy.java.lang.ClassgetJavaClass()PUBLIC: Return the java class.java.lang.StringgetJavaClassName()Return the class name, used by the MW.java.util.List<DatabaseMapping>getLockableMappings()INTERNAL: Returns a reference to the mappings that must be traverse when lockingDatabaseMappinggetMappingForAttributeName(java.lang.String attributeName)PUBLIC: Returns the mapping associated with a given attribute name.java.util.Vector<DatabaseMapping>getMappings()PUBLIC: Returns mappingsjava.util.List<DatabaseMapping>getMappingsPostCalculateChanges()Mappings that require postCalculateChanges method to be calledjava.util.List<DatabaseMapping>getMappingsPostCalculateChangesOnDeleted()Mappings that require mappingsPostCalculateChangesOnDeleted method to be calledjava.util.VectorgetMultipleTableForeignKeyAssociations()INTERNAL: Returns the foreign key relationships used for multiple tables which were specified by the user.java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Set<org.eclipse.persistence.internal.helper.DatabaseTable>>getMultipleTableForeignKeys()INTERNAL: Returns the foreign key relationships used for multiple tables which were specified by the user.java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable>getMultipleTableInsertOrder()INTERNAL: Returns the List of DatabaseTables in the order which INSERTS should take place.java.util.VectorgetMultipleTablePrimaryKeyAssociations()INTERNAL: Returns the foreign key relationships used for multiple tables which were specified by the user.MultitenantPolicygetMultitenantPolicy()INTERNAL: Retun the multitenant policyorg.eclipse.persistence.internal.descriptors.ObjectBuildergetObjectBuilder()INTERNAL: Return the object builderObjectChangePolicygetObjectChangePolicy()PUBLIC: Return this objects ObjectChangePolicy.ObjectChangePolicygetObjectChangePolicyInternal()INTERNAL: Return this objects ObjectChangePolicy and do not lazy initializeorg.eclipse.persistence.internal.descriptors.OptimisticLockingPolicygetOptimisticLockingPolicy()PUBLIC: Returns the OptimisticLockingPolicy.PartitioningPolicygetPartitioningPolicy()PUBLIC: Return the descriptor's partitioning policy.java.lang.StringgetPartitioningPolicyName()PUBLIC: Return the name of the descriptor's partitioning policy.java.util.List<DatabaseMapping>getPreDeleteMappings()INTERNAL: Set of mappings that require early delete behavior.java.util.Vector<java.lang.String>getPrimaryKeyFieldNames()PUBLIC: Return the names of all the primary keys.java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getPrimaryKeyFields()INTERNAL: Return all the primary key fieldsjava.util.List<IdValidation>getPrimaryKeyIdValidations()ADVANCED: Return what types are allowed in each primary key field (id).java.util.MapgetProperties()PUBLIC: Returns the user defined properties.java.lang.ObjectgetProperty(java.lang.String name)PUBLIC: Returns the descriptor property associated the given String.QueryKeygetQueryKeyNamed(java.lang.String queryKeyName)INTERNAL: Return the query key with the specified namejava.util.Map<java.lang.String,QueryKey>getQueryKeys()PUBLIC: Return the query keys.DescriptorQueryManagergetQueryManager()PUBLIC: Return the queryManager.java.lang.ClassgetRemoteIdentityMapClass()INTERNAL: Return the class of identity map to be used by this descriptor.intgetRemoteIdentityMapSize()PUBLIC: Return the size of the remote identity map.java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>getReturnFieldsToGenerateInsert()INTERNAL: Return fields used to build insert statement.java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField>getReturnFieldsToGenerateUpdate()INTERNAL: Return fields used to build update statement.java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getReturnFieldsToMergeInsert()INTERNAL: Return fields used in to map into entity for insert.java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getReturnFieldsToMergeUpdate()INTERNAL: Return fields used in to map into entity for update.java.util.List<ReturningPolicy>getReturningPolicies()PUBLIC: Return returning policy from current descriptor and from mappingsReturningPolicygetReturningPolicy()PUBLIC: Return returning policy.ClassDescriptorgetRootDescriptor()PUBLIC: This method returns the root descriptor for for this descriptor's class heirarchy.java.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getSelectionFields()INTERNAL: Return all selection fieldsjava.util.List<org.eclipse.persistence.internal.helper.DatabaseField>getSelectionFields(ObjectLevelReadQuery query)INTERNAL: Return all selection fieldsSequencegetSequence()Return the descriptor's sequence.org.eclipse.persistence.internal.helper.DatabaseFieldgetSequenceNumberField()INTERNAL: Get sequence number fieldjava.lang.StringgetSequenceNumberFieldName()PUBLIC: Get sequence number field namejava.lang.StringgetSequenceNumberName()PUBLIC: Get sequence number nameSerializedObjectPolicygetSerializedObjectPolicy()INTERNAL:java.lang.StringgetSessionName()INTERNAL: Return the name of the session local to this descriptor.org.eclipse.persistence.internal.helper.DatabaseTablegetTable(java.lang.String tableName)INTERNAL: Checks if table name exists with the current descriptor or not.java.lang.StringgetTableName()PUBLIC: Return the name of the descriptor's first table.java.util.VectorgetTableNames()PUBLIC: Return the table names.TablePerClassPolicygetTablePerClassPolicy()PUBLIC: Returns the TablePerClassPolicy.java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseTable>getTables()INTERNAL: Return all the tables.org.eclipse.persistence.internal.helper.DatabaseFieldgetTypedField(org.eclipse.persistence.internal.helper.DatabaseField field)INTERNAL: searches first descriptor than its ReturningPolicy for an equal fieldjava.util.Map<java.lang.String,java.util.List<java.lang.String>>getUnconvertedProperties()INTERNAL: Used to store un-converted properties, which are subsequenctly converted at runtime (through the convertClassNamesToClasses method.intgetUnitOfWorkCacheIsolationLevel()ADVANCED: Return the unit of work cache isolation setting.java.util.List<org.eclipse.persistence.internal.descriptors.VirtualAttributeMethodInfo>getVirtualAttributeMethods()INTERNAL: Return the list of virtual methods sets for this Entity.WrapperPolicygetWrapperPolicy()ADVANCED: Return the WrapperPolicy for this descriptor.booleanhasCascadeLockingPolicies()INTERNAL:booleanhasCMPPolicy()INTERNAL: Return if the descriptor has a CMP policy.booleanhasDependencyOnParts()INTERNAL: Checks if the class has any private owned parts or other dependencies, (i.e.booleanhasDerivedId()INTERNAL: returns true if users have designated one or more mappings as IDs.booleanhasEventManager()INTERNAL: returns true if a DescriptorEventManager has been set.booleanhasFetchGroupManager()INTERNAL: Return if the descriptor has a fetch group manager associated with.booleanhasInheritance()INTERNAL: Return if this descriptor is involved in inheritance, (is child or parent).booleanhasInterfacePolicy()INTERNAL: Return if this descriptor is involved in interface, (is child or parent).booleanhasMappingsPostCalculateChanges()Are there any mappings that require postCalculateChanges method to be called.booleanhasMappingsPostCalculateChangesOnDeleted()Are there any mappings that require mappingsPostCalculateChangesOnDeleted method to be called.booleanhasMultipleTableConstraintDependecy()Return if any mapping reference a field in a secondary table.booleanhasMultipleTables()INTERNAL: Check if descriptor has multiple tablesbooleanhasMultitenantPolicy()Return true if the descriptor has a multitenant policybooleanhasNestedIdentityReference(boolean withChildren)INTERNAL: Calculates whether descriptor references an entity (directly or through a nested mapping).booleanhasNoncacheableMappings()booleanhasPessimisticLockingPolicy()INTERNAL:booleanhasPreDeleteMappings()booleanhasPrivatelyOwnedParts()INTERNAL: Checks if the class has any private owned parts are notbooleanhasQueryKeyOrMapping(java.lang.String attributeName)INTERNAL: Checks to see if it has a query key or mapping with the specified name or not.booleanhasRelationships()INTERNAL: return whether this descriptor has any relationships through its mappings, through inheritance, or through aggregatesbooleanhasRelationshipsExceptBackpointer(ClassDescriptor descriptor)INTERNAL: This method returns true if this descriptor has either a ForeignReferenceMapping to an object aside from the one described by descriptor or more than one ForeignReferenceMapping to descriptor.booleanhasReturningPolicies()INTERNAL: Return if this descriptor or descriptors from mappings has Returning policy.booleanhasReturningPolicy()INTERNAL: Return if this descriptor has Returning policy.booleanhasSerializedObjectPolicy()INTERNAL:booleanhasSimplePrimaryKey()INTERNAL: PERF: Return if the primary key is simple (direct-mapped) to allow fast extraction.booleanhasTablePerClassPolicy()INTERNAL: Return if this descriptor is involved in a table per class inheritance.booleanhasTablePerMultitenantPolicy()PUBLICbooleanhasTargetForeignKeyMapping(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Indicates whether descriptor has at least one target foreign key mappingbooleanhasUnconvertedProperties()INTERNAL: Used to store un-converted properties, which are subsequenctly converted at runtime (through the convertClassNamesToClasses method.booleanhasWrapperPolicy()INTERNAL: Return if a wrapper policy is used.voidinitialize(DescriptorQueryManager queryManager, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Initialize the query manager specific to the descriptor type.voidinitialize(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Initialize the mappings as a separate step.voidinitializeAggregateInheritancePolicy(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: This initialized method is used exclusively for inheritance.voidinitializeMultipleTablePrimaryKeyFields()INTERNAL: Rebuild the multiple table primary key map.protected voidinitializeProperties(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Initialize the descriptor properties such as write lock and sequencing.voidinterfaceInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Allow the descriptor to initialize any dependencies on this session.booleanisAbstract()INTERNAL: Convenience method to return true if the java class from this descriptor is abstract.booleanisAggregateCollectionDescriptor()PUBLIC: Return true if this descriptor is an aggregate collection descriptorbooleanisAggregateDescriptor()PUBLIC: Return true if this descriptor is an aggregate descriptorbooleanisCascadeOnDeleteSetOnDatabaseOnSecondaryTables()ADVANCED: Return if delete cascading has been set on the database for the descriptor's multiple tables.booleanisChildDescriptor()PUBLIC: Return if the descriptor defines inheritance and is a child.booleanisDescriptorForInterface()PUBLIC: Return if the java class is an interface.booleanisDescriptorTypeAggregate()PUBLIC return true if this descriptor is any type of aggregate descriptor.booleanisDescriptorTypeNormal()INTERNAL: return true if this descriptor is an entity.booleanisEISDescriptor()PUBLIC: Return if the descriptor maps to an EIS or NoSQL datasource.booleanisFullyInitialized()INTERNAL: Check if the descriptor is finished initialization.protected booleanisInitialized(int initializationStage)INTERNAL: Check if descriptor is already initialized for the level of initialization. 1 = pre 2 = mapping 3 = postbooleanisInterfaceChildDescriptor()INTERNAL: Return if the descriptor defines inheritance and is a child.protected booleanisInterfaceInitialized(int interfaceInitializationStage)INTERNAL: Check if interface descriptor is already initialized for the level of initialization. 1 = pre 2 = mapping 3 = postbooleanisInvalid()INTERNAL: Return if an error occurred during initialization which should abort any further initialization.booleanisIsolated()PUBLIC: Returns true if the descriptor represents an isolated classbooleanisMultipleTableDescriptor()INTERNAL: Return if this descriptor has more than one table.booleanisNativeConnectionRequired()ADVANCED: Return if the descriptor requires usage of a native (unwrapped) JDBC connection.booleanisObjectRelationalDataTypeDescriptor()PUBLIC: Return if the descriptor maps to an object-relational structured type.booleanisPrimaryKeySetAfterInsert(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Indicates whether pk or some of its components set after insert into the database.booleanisProtectedIsolation()PUBLIC: Returns true if the descriptor represents an isolated classbooleanisRelationalDescriptor()PUBLIC: Return if the descriptor maps to a relational table.booleanisReturnTypeRequiredForReturningPolicy()INTERNAL: Indicates if a return type is required for the field set on the returning policy.booleanisSharedIsolation()PUBLIC: Returns true if the descriptor represents an isolated classbooleanisXMLDescriptor()PUBLIC: Return if the descriptor maps to XML.DatabaseMappingnewAggregateCollectionMapping()Return a new aggregate collection/element collection mapping for this type of descriptor.AggregateMappingnewAggregateMapping()Return a new aggregate/embedded mapping for this type of descriptor.DatabaseMappingnewDirectCollectionMapping()Return a new direct collection/element collection mapping for this type of descriptor.AbstractDirectMappingnewDirectMapping()Return a new direct/basic mapping for this type of descriptor.CollectionMappingnewManyToManyMapping()Return a new one to many mapping for this type of descriptor.ObjectReferenceMappingnewManyToOneMapping()Return a new many to one mapping for this type of descriptor.CollectionMappingnewOneToManyMapping()Return a new one to many mapping for this type of descriptor.ObjectReferenceMappingnewOneToOneMapping()Return a new one to one mapping for this type of descriptor.CollectionMappingnewUnidirectionalOneToManyMapping()Return a new one to many mapping for this type of descriptor.voidnotifyReferencingDescriptorsOfIsolation(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Configure all descriptors referencing this class to be protected and update their cache settings.voidonlyRefreshCacheIfNewerVersion()PUBLIC: This method is the equivalent of callingsetShouldOnlyRefreshCacheIfNewerVersion(boolean)with an argument oftrue: it configures aClassDescriptorto only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field) and as long as one of the following is true: theClassDescriptorwas configured by callingalwaysRefreshCache()oralwaysRefreshCacheOnRemote(), the query was configured by callingObjectLevelReadQuery.refreshIdentityMapResult(), or the query was a call toSession.refreshObject(java.lang.Object)voidpostInitialize(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Post initializations after mappings are initialized.voidpreInitialize(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Allow the descriptor to initialize any dependencies on this session.protected voidpreInitializeInheritancePolicy(org.eclipse.persistence.internal.sessions.AbstractSession session)Hook together the inheritance policy tree.voidpreInterfaceInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Allow the descriptor to initialize any dependencies on this session.protected voidprepareCascadeLockingPolicy(DatabaseMapping mapping)INTERNAL:voidrehashFieldDependancies(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Rehash any hashtables based on fields.voidreInitializeJoinedAttributes()INTERNAL: A user should not be setting which attributes to join or not to join after descriptor initialization; provided only for backwards compatibility.voidremoteInitialization(DistributedSession session)INTERNAL: Used to initialize a remote descriptor.DatabaseMappingremoveMappingForAttributeName(java.lang.String attributeName)ADVANCED: Removes the locally defined mapping associated with a given attribute name.voidremoveProperty(java.lang.String property)PUBLIC: Remove the user defined property.booleanrequiresInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Aggregate and Interface descriptors do not require initialization as they are cloned and initialized by each mapping.protected voidselfValidationAfterInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Validate that the descriptor was defined correctly.protected voidselfValidationBeforeInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Validate that the descriptor's non-mapping attribute are defined correctly.voidsetAccessorTree(java.util.List<AttributeAccessor> accessorTree)voidsetAdditionalTablePrimaryKeyFields(java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Map<org.eclipse.persistence.internal.helper.DatabaseField,org.eclipse.persistence.internal.helper.DatabaseField>> additionalTablePrimaryKeyFields)INTERNAL: This is used to map the primary key field names in a multiple table descriptor.protected voidsetAdditionalTablePrimaryKeyFields(org.eclipse.persistence.internal.helper.DatabaseTable table, org.eclipse.persistence.internal.helper.DatabaseField field1, org.eclipse.persistence.internal.helper.DatabaseField field2)INTERNAL: This is used to map the primary key field names in a multiple table descriptor.voidsetAlias(java.lang.String alias)PUBLIC: Set the aliasprotected voidsetAllFields(java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> allFields)INTERNAL: Set all the fields.voidsetAmendmentClass(java.lang.Class amendmentClass)PUBLIC: Set the amendment class.voidsetAmendmentClassName(java.lang.String amendmentClassName)INTERNAL: Return the amendment class name, used by the MW.voidsetAmendmentMethodName(java.lang.String amendmentMethodName)PUBLIC: Set the amendment method.voidsetCacheable(java.lang.Boolean cacheable)INTERNAL: Set entity @Cacheable annotation value in cache configuration object.voidsetCacheInterceptorClass(java.lang.Class cacheInterceptorClass)PUBLIC: A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor.voidsetCacheInterceptorClassName(java.lang.String cacheInterceptorClassName)PUBLIC: A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor.voidsetCacheInvalidationPolicy(CacheInvalidationPolicy policy)PUBLIC: Set the Cache Invalidation Policy for this descriptor.voidsetCacheIsolation(CacheIsolationType isolationType)PUBLIC: Controls how the Entity instances and data will be cached.voidsetCacheKeyType(CacheKeyType cacheKeyType)ADVANCED: Set what cache key type to use to store the object in the cache.voidsetCachePolicy(CachePolicy cachePolicy)ADVANCED: Set cache policy for the descriptor.voidsetCacheSynchronizationType(int type)PUBLIC: Set the type of cache synchronization that will be used on objects of this type.voidsetCMPPolicy(CMPPolicy newCMPPolicy)ADVANCED: Set the cmp descriptor that holds cmp specific information.voidsetConstraintDependencies(java.util.Vector constraintDependencies)ADVANCED: automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings.voidsetCopyPolicy(CopyPolicy policy)INTERNAL: Set the copy policy.voidsetCopyPolicyClassName(java.lang.String className)INTERNAL: Sets the name of a Class that implements CopyPolicy Will be instantiatied as a copy policy at initialization times using the no-args constructorvoidsetDefaultDeleteObjectQueryRedirector(QueryRedirector defaultDeleteObjectQueryRedirector)A Default DeleteObjectQuery Redirector will be applied to any executing DeleteObjectQuery or DeleteAllQuery that does not have a redirector set directly on the query.voidsetDefaultDeleteObjectQueryRedirectorClassName(java.lang.String defaultDeleteObjectQueryRedirectorClassName)A Default DeleteObjectQuery Redirector will be applied to any executing DeleteObjectQuery or DeleteAllQuery that does not have a redirector set directly on the query.voidsetDefaultInsertObjectQueryRedirector(QueryRedirector defaultInsertQueryRedirector)A Default InsertObjectQuery Redirector will be applied to any executing InsertObjectQuery that does not have a redirector set directly on the query.voidsetDefaultInsertObjectQueryRedirectorClassName(java.lang.String defaultInsertObjectQueryRedirectorClassName)A Default InsertObjectQuery Redirector will be applied to any executing InsertObjectQuery that does not have a redirector set directly on the query.voidsetDefaultQueryRedirector(QueryRedirector defaultRedirector)A Default Query Redirector will be applied to any executing object query that does not have a more precise default (like the default ReadObjectQuery Redirector) or a redirector set directly on the query.voidsetDefaultQueryRedirectorClassName(java.lang.String defaultQueryRedirectorClassName)A Default Query Redirector will be applied to any executing object query that does not have a more precise default (like the default ReadObjectQuery Redirector) or a redirector set directly on the query.voidsetDefaultReadAllQueryRedirector(QueryRedirector defaultReadAllQueryRedirector)A Default ReadAllQuery Redirector will be applied to any executing ReadAllQuery that does not have a redirector set directly on the query.voidsetDefaultReadAllQueryRedirectorClassName(java.lang.String defaultReadAllQueryRedirectorClassName)A Default ReadAllQuery Redirector will be applied to any executing ReadAllQuery that does not have a redirector set directly on the query.voidsetDefaultReadObjectQueryRedirector(QueryRedirector defaultReadObjectQueryRedirector)A Default ReadObjectQuery Redirector will be applied to any executing ReadObjectQuery that does not have a redirector set directly on the query.voidsetDefaultReadObjectQueryRedirectorClassName(java.lang.String defaultReadObjectQueryRedirectorClassName)A Default ReadObjectQuery Redirector will be applied to any executing ReadObjectQuery that does not have a redirector set directly on the query.voidsetDefaultReportQueryRedirector(QueryRedirector defaultReportQueryRedirector)A Default ReportQuery Redirector will be applied to any executing ReportQuery that does not have a redirector set directly on the query.voidsetDefaultReportQueryRedirectorClassName(java.lang.String defaultReportQueryRedirectorClassName)A Default ReportQuery Redirector will be applied to any executing ReportQuery that does not have a redirector set directly on the query.voidsetDefaultTable(org.eclipse.persistence.internal.helper.DatabaseTable defaultTable)INTERNAL: The descriptors default table can be configured if the first table is not desired.voidsetDefaultTableName(java.lang.String defaultTableName)PUBLIC: The descriptors default table can be configured if the first table is not desired.voidsetDefaultUpdateObjectQueryRedirector(QueryRedirector defaultUpdateQueryRedirector)A Default UpdateObjectQuery Redirector will be applied to any executing UpdateObjectQuery or UpdateAllQuery that does not have a redirector set directly on the query.voidsetDefaultUpdateObjectQueryRedirectorClassName(java.lang.String defaultUpdateObjectQueryRedirectorClassName)A Default UpdateObjectQuery Redirector will be applied to any executing UpdateObjectQuery or UpdateAllQuery that does not have a redirector set directly on the query.voidsetDescriptorCustomizerClassName(java.lang.String descriptorCustomizerClassName)INTERNAL: Sets the JPA DescriptorCustomizer class name.voidsetDescriptorType(int descriptorType)ADVANCED: set the descriptor type (NORMAL by default, others include INTERFACE, AGGREGATE, AGGREGATE COLLECTION)voidsetDescriptorTypeValue(java.lang.String value)INTERNAL: This method is explicitly used by the XML reader.voidsetEventManager(DescriptorEventManager eventManager)INTERNAL: Set the event manager for the descriptor.voidsetExistenceChecking(java.lang.String token)INTERNAL: OBSOLETE - old reader.voidsetFetchGroupManager(FetchGroupManager fetchGroupManager)PUBLIC: Set the fetch group manager for the descriptor.voidsetFields(java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> fields)INTERNAL: Set the fields used by this descriptor.voidsetForeignKeyFieldNamesForMultipleTable(java.util.Vector associations)INTERNAL: This method is used by the XML Deployment ClassDescriptor to read and write these mappingsvoidsetFullyMergeEntity(boolean fullyMergeEntity)voidsetHasMultipleTableConstraintDependecy(boolean hasMultipleTableConstraintDependecy)Set if any mapping reference a field in a secondary table.voidsetHasRelationships(boolean hasRelationships)INTERNAL: set whether this descriptor has any relationships through its mappings, through inheritance, or through aggregatesvoidsetHasSimplePrimaryKey(boolean hasSimplePrimaryKey)INTERNAL: PERF: Set if the primary key is simple (direct-mapped) to allow fast extraction.voidsetHistoryPolicy(HistoryPolicy policy)PUBLIC: Set the HistoryPolicy for this descriptor.voidsetIdentityMapClass(java.lang.Class theIdentityMapClass)PUBLIC: Set the class of identity map to be used by this descriptor.voidsetIdentityMapSize(int identityMapSize)PUBLIC: Set the size of the identity map to be used by this descriptor.voidsetIdValidation(IdValidation idValidation)ADVANCED: Set what types are allowed as a primary key (id).voidsetInheritancePolicy(InheritancePolicy inheritancePolicy)INTERNAL: Sets the inheritance policy.protected voidsetInitializationStage(int initializationStage)INTERNAL:voidsetInstantiationPolicy(org.eclipse.persistence.internal.descriptors.InstantiationPolicy instantiationPolicy)INTERNAL: Sets the instantiation policy.protected voidsetInterfaceInitializationStage(int interfaceInitializationStage)INTERNAL:voidsetInterfacePolicy(InterfacePolicy interfacePolicy)INTERNAL: Sets the interface policy.voidsetInternalDefaultTable()INTERNAL: Set the default table if one if not already set.voidsetInternalDefaultTable(org.eclipse.persistence.internal.helper.DatabaseTable defaultTable)INTERNAL: Set the default table if one if not already set.voidsetIsCascadeOnDeleteSetOnDatabaseOnSecondaryTables(boolean isCascadeOnDeleteSetOnDatabaseOnSecondaryTables)ADVANCED: Set if delete cascading has been set on the database for the descriptor's multiple tables.voidsetIsIsolated(boolean isIsolated)Deprecated.as of EclipseLink 2.2voidsetIsNativeConnectionRequired(boolean isNativeConnectionRequired)ADVANCED: Set if the descriptor requires usage of a native (unwrapped) JDBC connection.voidsetJavaClass(java.lang.Class theJavaClass)PUBLIC: Set the Java class that this descriptor maps.voidsetJavaClassName(java.lang.String theJavaClassName)INTERNAL: Return the java class name, used by the MW.voidsetJavaInterface(java.lang.Class theJavaInterface)PUBLIC: Sets the descriptor to be for an interface.voidsetJavaInterfaceName(java.lang.String theJavaInterfaceName)INTERNAL: Return the java interface name, used by the MW.voidsetLockableMappings(java.util.List<DatabaseMapping> lockableMappings)INTERNAL: Set the list of lockable mappings for this project This method is provided for CMP use.voidsetMappings(java.util.Vector<DatabaseMapping> mappings)INTERNAL: Set the mappings.protected voidsetMultipleTableForeignKeys(java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Set<org.eclipse.persistence.internal.helper.DatabaseTable>> newValue)INTERNAL:voidsetMultipleTableInsertOrder(java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable> newValue)ADVANCED: Sets the List of DatabaseTables in the order which INSERTS should take place.voidsetMultitenantPolicy(MultitenantPolicy multitenantPolicy)INTERNAL: Set a multitenant policy on the descriptor.protected voidsetObjectBuilder(org.eclipse.persistence.internal.descriptors.ObjectBuilder builder)INTERNAL: Set the ObjectBuilder.voidsetObjectChangePolicy(ObjectChangePolicy policy)PUBLIC: Set the ObjectChangePolicy for this descriptor.voidsetOptimisticLockingPolicy(org.eclipse.persistence.internal.descriptors.OptimisticLockingPolicy optimisticLockingPolicy)PUBLIC: Set the OptimisticLockingPolicy.voidsetPartitioningPolicy(PartitioningPolicy partitioningPolicy)PUBLIC: Set the descriptor's partitioning policy.voidsetPartitioningPolicyName(java.lang.String partitioningPolicyName)PUBLIC: Set the name of the descriptor's partitioning policy.voidsetPrimaryKeyFieldName(java.lang.String fieldName)PUBLIC: Specify the primary key field of the descriptors table.voidsetPrimaryKeyFieldNames(java.util.Vector primaryKeyFieldsName)PUBLIC: User can specify a vector of all the primary key field names if primary key is composite.voidsetPrimaryKeyFields(java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> thePrimaryKeyFields)INTERNAL: Set the primary key fieldsvoidsetPrimaryKeyIdValidations(java.util.List<IdValidation> primaryKeyIdValidations)ADVANCED: Return what types are allowed in each primary key field (id).voidsetProperties(java.util.Map properties)INTERNAL: Set the user defined properties.voidsetProperty(java.lang.String name, java.lang.Object value)PUBLIC: Set the user defined property.voidsetQueryKeys(java.util.Map<java.lang.String,QueryKey> queryKeys)INTERNAL: Set the query keys.voidsetQueryManager(DescriptorQueryManager queryManager)INTERNAL: Set the query manager.voidsetReadOnly()PUBLIC: Set the descriptor to be read-only.voidsetRemoteIdentityMapClass(java.lang.Class theIdentityMapClass)PUBLIC: Set the class of identity map to be used by this descriptor.voidsetRemoteIdentityMapSize(int identityMapSize)PUBLIC: Set the size of the identity map to be used by this descriptor.voidsetReturningPolicy(ReturningPolicy returningPolicy)PUBLIC: Sets the returning policy.voidsetSequence(Sequence sequence)Set the descriptor's sequence.voidsetSequenceNumberField(org.eclipse.persistence.internal.helper.DatabaseField sequenceNumberField)INTERNAL: Set the sequence number field.voidsetSequenceNumberFieldName(java.lang.String fieldName)PUBLIC: Set the sequence number field name.voidsetSequenceNumberName(java.lang.String name)PUBLIC: Set the sequence number name.voidsetSerializedObjectPolicy(SerializedObjectPolicy serializedObjectPolicy)INTERNAL:protected voidsetSessionName(java.lang.String sessionName)INTERNAL: Set the name of the session local to this descriptor.voidsetShouldAcquireCascadedLocks(boolean shouldAcquireCascadedLocks)INTERNAL: PERF: Set if deferred locks should be used.voidsetShouldAlwaysConformResultsInUnitOfWork(boolean shouldAlwaysConformResultsInUnitOfWork)PUBLIC: set if the descriptor is defined to always conform the results in unit of work in read query.voidsetShouldAlwaysRefreshCache(boolean shouldAlwaysRefreshCache)PUBLIC: When theshouldAlwaysRefreshCacheargument passed into this method istrue, this method configures aClassDescriptorto always refresh the cache if data is received from the database by any query.voidsetShouldAlwaysRefreshCacheOnRemote(boolean shouldAlwaysRefreshCacheOnRemote)PUBLIC: When theshouldAlwaysRefreshCacheOnRemoteargument passed into this method istrue, this method configures aClassDescriptorto always remotely refresh the cache if data is received from the database by any query in aRemoteSession.voidsetShouldBeReadOnly(boolean shouldBeReadOnly)PUBLIC: Define if the descriptor reference class is read-onlyvoidsetShouldDisableCacheHits(boolean shouldDisableCacheHits)PUBLIC: Set if cache hits on primary key read object queries should be disabled.voidsetShouldDisableCacheHitsOnRemote(boolean shouldDisableCacheHitsOnRemote)PUBLIC: Set if the remote session cache hits on primary key read object queries is allowed or not.voidsetShouldLockForClone(boolean shouldLockForClone)ADVANCED: When set to false, this setting will allow the UOW to avoid locking the shared cache instance in order to perform a clone.voidsetShouldOnlyRefreshCacheIfNewerVersion(boolean shouldOnlyRefreshCacheIfNewerVersion)PUBLIC: When theshouldOnlyRefreshCacheIfNewerVersionargument passed into this method istrue, this method configures aClassDescriptorto only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field) and as long as one of the following is true: theClassDescriptorwas configured by callingalwaysRefreshCache()oralwaysRefreshCacheOnRemote(), the query was configured by callingObjectLevelReadQuery.refreshIdentityMapResult(), or the query was a call toSession.refreshObject(java.lang.Object)voidsetShouldOrderMappings(boolean shouldOrderMappings)PUBLIC: This is set to turn off the ordering of mappings.voidsetShouldRegisterResultsInUnitOfWork(boolean shouldRegisterResultsInUnitOfWork)INTERNAL: Set to false to have queries conform to a UnitOfWork without registering any additional objects not already in that UnitOfWork.voidsetTableName(java.lang.String tableName)PUBLIC: Specify the table name for the class of objects the receiver describes.voidsetTableNames(java.util.Vector tableNames)PUBLIC: Specify the all table names for the class of objects the receiver describes.voidsetTablePerClassPolicy(TablePerClassPolicy tablePerClassPolicy)INTERNAL: Sets the table per class policy.voidsetTableQualifier(java.lang.String tableQualifier)PUBLIC: Set the table Qualifier for this descriptor.voidsetTables(java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseTable> theTables)INTERNAL: Sets the tablesvoidsetUnitOfWorkCacheIsolationLevel(int unitOfWorkCacheIsolationLevel)ADVANCED: This setting configures how the session cache will be used in a unit of work.voidsetVirtualAttributeMethods(java.util.List<org.eclipse.persistence.internal.descriptors.VirtualAttributeMethodInfo> virtualAttributeMethods)INTERNAL: Set the list of methods used my mappings with virtual access this list is used to determine which methods to weavevoidsetWrapperPolicy(WrapperPolicy wrapperPolicy)ADVANCED: Sets the WrapperPolicy for this descriptor.booleanshouldAcquireCascadedLocks()INTERNAL: PERF: Return if deferred locks should be used.booleanshouldAlwaysConformResultsInUnitOfWork()PUBLIC: Return if the descriptor is defined to always conform the results in unit of work in read query.booleanshouldAlwaysRefreshCache()PUBLIC: This method returnstrueif theClassDescriptoris configured to always refresh the cache if data is received from the database by any query.booleanshouldAlwaysRefreshCacheOnRemote()PUBLIC: This method returnstrueif theClassDescriptoris configured to always remotely refresh the cache if data is received from the database by any query in aRemoteSession.booleanshouldBeReadOnly()PUBLIC: Return if the descriptor reference class is defined as read-onlybooleanshouldDisableCacheHits()PUBLIC: Return if for cache hits on primary key read object queries to be disabled.booleanshouldDisableCacheHitsOnRemote()PUBLIC: Return if the remote server session cache hits on primary key read object queries is aloowed or not.booleanshouldIsolateObjectsInUnitOfWork()INTERNAL: Return if the unit of work should by-pass the session cache.booleanshouldIsolateObjectsInUnitOfWorkEarlyTransaction()INTERNAL: Return if the unit of work should by-pass the session cache after an early transaction.booleanshouldIsolateProtectedObjectsInUnitOfWork()INTERNAL: Return if the unit of work should by-pass the IsolatedSession cache.booleanshouldLockForClone()ADVANCED: When set to false, this setting will allow the UOW to avoid locking the shared cache instance in order to perform a clone.booleanshouldOnlyRefreshCacheIfNewerVersion()PUBLIC: This method returnstrueif theClassDescriptoris configured to only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field).booleanshouldOrderMappings()INTERNAL: Return if mappings should be ordered or not.booleanshouldRegisterResultsInUnitOfWork()INTERNAL: Allows one to do conforming in a UnitOfWork without registering.booleanshouldUseAdditionalJoinExpression()PUBLIC: Return true if this descriptor should using an additional join expresison.booleanshouldUseCacheIdentityMap()PUBLIC: Return true if this descriptor is using CacheIdentityMapbooleanshouldUseFullChangeSetsForNewObjects()INTERNAL: Return if change sets are required for new objects.booleanshouldUseFullIdentityMap()PUBLIC: Return true if this descriptor is using FullIdentityMapbooleanshouldUseHardCacheWeakIdentityMap()PUBLIC: Return true if this descriptor is using HardCacheWeakIdentityMap.booleanshouldUseNoIdentityMap()PUBLIC: Return true if this descriptor is using NoIdentityMapbooleanshouldUseRemoteCacheIdentityMap()PUBLIC: Return true if this descriptor is using CacheIdentityMapbooleanshouldUseRemoteFullIdentityMap()PUBLIC: Return true if this descriptor is using FullIdentityMapbooleanshouldUseRemoteHardCacheWeakIdentityMap()PUBLIC: Return true if this descriptor is using HardCacheWeakIdentityMapbooleanshouldUseRemoteNoIdentityMap()PUBLIC: Return true if this descriptor is using NoIdentityMapbooleanshouldUseRemoteSoftCacheWeakIdentityMap()PUBLIC: Return true if this descriptor is using SoftCacheWeakIdentityMapbooleanshouldUseRemoteSoftIdentityMap()PUBLIC: Return true if this descriptor is using SoftIdentityMapbooleanshouldUseRemoteWeakIdentityMap()PUBLIC: Return true if this descriptor is using WeakIdentityMapbooleanshouldUseSessionCacheInUnitOfWorkEarlyTransaction()INTERNAL: Return if the unit of work should use the session cache after an early transaction.booleanshouldUseSoftCacheWeakIdentityMap()PUBLIC: Return true if this descriptor is using SoftCacheWeakIdentityMap.booleanshouldUseSoftIdentityMap()PUBLIC: Return true if this descriptor is using SoftIdentityMapbooleanshouldUseWeakIdentityMap()PUBLIC: Return true if this descriptor is using WeakIdentityMapbooleansupportsChangeTracking(Project project)INTERNAL: Returns whether this descriptor is capable of supporting weaved change tracking.protected voidtoggleAdditionalTablePrimaryKeyFields()INTERNAL: Eclipselink needs additionalTablePKFields entries to be associated with tables other than the main (getTables.get(0)) one.java.lang.StringtoString()PUBLIC: Returns a brief string representation of the receiver.voiduseAllFieldsLocking()PUBLIC: Set the locking policy an all fields locking policy.voiduseCacheIdentityMap()PUBLIC: Set the class of identity map to be the cache identity map.voiduseChangedFieldsLocking()PUBLIC: Set the locking policy a changed fields locking policy.voiduseCloneCopyPolicy()PUBLIC: Specifies that the creation of clones within a unit of work is done by sending the #clone() method to the original object.voiduseCloneCopyPolicy(java.lang.String cloneMethodName)PUBLIC: Specifies that the creation of clones within a unit of work is done by sending the cloneMethodName method to the original object.voiduseDefaultConstructorInstantiationPolicy()PUBLIC: Use the default constructor to create new instances of objects built from the database.voiduseFactoryInstantiationPolicy(java.lang.Class factoryClass, java.lang.String methodName)PUBLIC: Use an object factory to create new instances of objects built from the database.voiduseFactoryInstantiationPolicy(java.lang.Class factoryClass, java.lang.String methodName, java.lang.String factoryMethodName)PUBLIC: Use an object factory to create new instances of objects built from the database.voiduseFactoryInstantiationPolicy(java.lang.Object factory, java.lang.String methodName)PUBLIC: Use an object factory to create new instances of objects built from the database.voiduseFactoryInstantiationPolicy(java.lang.String factoryClassName, java.lang.String methodName)INTERNAL: Set the factory class name, used by the MW.voiduseFactoryInstantiationPolicy(java.lang.String factoryClassName, java.lang.String methodName, java.lang.String factoryMethodName)INTERNAL: Set the factory class name, used by the MW.voiduseFullIdentityMap()PUBLIC: Set the class of identity map to be the full identity map.voiduseHardCacheWeakIdentityMap()PUBLIC: Set the class of identity map to be the hard cache weak identity map.voiduseInstantiationCopyPolicy()PUBLIC: Specifies that the creation of clones within a unit of work is done by building a new instance using the technique indicated by the descriptor's instantiation policy (which by default is to use the the default constructor).voiduseMethodInstantiationPolicy(java.lang.String staticMethodName)PUBLIC: Use the specified static method to create new instances of objects built from the database.voiduseNoIdentityMap()PUBLIC: Set the class of identity map to be the no identity map.voidusePropertyAccessForWeaving()INTERNAL: Record that this descriptor uses property access.voiduseRemoteCacheIdentityMap()PUBLIC: Set the class of identity map to be the cache identity map.voiduseRemoteFullIdentityMap()PUBLIC: Set the class of identity map to be the full identity map.voiduseRemoteHardCacheWeakIdentityMap()PUBLIC: Set the class of identity map to be the hard cache weak identity map.voiduseRemoteNoIdentityMap()PUBLIC: Set the class of identity map to be the no identity map.voiduseRemoteSoftCacheWeakIdentityMap()PUBLIC: Set the class of identity map to be the soft cache weak identity map.voiduseRemoteSoftIdentityMap()PUBLIC: Set the class of identity map to be the soft identity map.voiduseRemoteWeakIdentityMap()PUBLIC: Set the class of identity map to be the weak identity map.voiduseSelectedFieldsLocking(java.util.Vector fieldNames)PUBLIC: Set the locking policy a selected fields locking policy.booleanusesFieldLocking()INTERNAL: Return true if the receiver uses either all or changed fields for optimistic locking.voiduseSoftCacheWeakIdentityMap()PUBLIC: Set the class of identity map to be the soft cache weak identity map.voiduseSoftIdentityMap()PUBLIC: Set the class of identity map to be the soft identity map.booleanusesOptimisticLocking()PUBLIC: Return true if the receiver uses write (optimistic) locking.booleanusesPropertyAccessForWeaving()INTERNAL: Return whether this descriptor uses property access.booleanusesSequenceNumbers()PUBLIC: Return true if the receiver uses sequence numbers.booleanusesVersionLocking()PUBLIC: Return true if the receiver uses version optimistic locking.voiduseTimestampLocking(java.lang.String writeLockFieldName)PUBLIC: Use the Timestamps locking policy and storing the value in the cache key #see useVersionLocking(String)voiduseTimestampLocking(java.lang.String writeLockFieldName, boolean shouldStoreInCache)PUBLIC: Set the locking policy to use timestamp version locking.voiduseVersionLocking(java.lang.String writeLockFieldName)PUBLIC: Default to use the version locking policy and storing the value in the cache key #see useVersionLocking(String)voiduseVersionLocking(java.lang.String writeLockFieldName, boolean shouldStoreInCache)PUBLIC: Set the locking policy to use numeric version locking.voiduseWeakIdentityMap()PUBLIC: Set the class of identity map to be the weak identity map.protected voidvalidateAfterInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Validate the entire post-initialization descriptor.protected voidvalidateBeforeInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Validate the entire pre-initialization descriptor.protected voidvalidateMappingType(DatabaseMapping mapping)protected voidverifyMultipleTableInsertOrder()INTERNAL: Verify multiple table insert order provided by the user.protected voidverifyMultipleTablesForeignKeysTables()INTERNAL: Verify that the tables specified in multipleTablesForeignKeysTables are valid.protected voidverifyTableQualifiers(org.eclipse.persistence.internal.databaseaccess.Platform platform)INTERNAL: Check that the qualifier on the table names are properly set.-
Methods inherited from class org.eclipse.persistence.core.descriptors.CoreDescriptor
addAttributeGroup
-
-
-
-
Field Detail
-
javaClass
protected java.lang.Class javaClass
-
javaClassName
protected java.lang.String javaClassName
-
tables
protected java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseTable> tables
-
defaultTable
protected transient org.eclipse.persistence.internal.helper.DatabaseTable defaultTable
-
primaryKeyFields
protected java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> primaryKeyFields
-
additionalTablePrimaryKeyFields
protected java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Map<org.eclipse.persistence.internal.helper.DatabaseField,org.eclipse.persistence.internal.helper.DatabaseField>> additionalTablePrimaryKeyFields
-
multipleTableInsertOrder
protected transient java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable> multipleTableInsertOrder
-
multipleTableForeignKeys
protected java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Set<org.eclipse.persistence.internal.helper.DatabaseTable>> multipleTableForeignKeys
-
isCascadeOnDeleteSetOnDatabaseOnSecondaryTables
protected boolean isCascadeOnDeleteSetOnDatabaseOnSecondaryTables
Support delete cascading on the database for multiple and inheritance tables.
-
fields
protected transient java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> fields
-
allFields
protected transient java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> allFields
-
selectionFields
protected transient java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> selectionFields
-
allSelectionFields
protected transient java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> allSelectionFields
-
returnFieldsToGenerateInsert
protected transient java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> returnFieldsToGenerateInsert
-
returnFieldsToGenerateUpdate
protected transient java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> returnFieldsToGenerateUpdate
-
returnFieldsToMergeInsert
protected transient java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> returnFieldsToMergeInsert
-
returnFieldsToMergeUpdate
protected transient java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> returnFieldsToMergeUpdate
-
mappings
protected java.util.Vector<DatabaseMapping> mappings
-
referencingClasses
protected java.util.Set<ClassDescriptor> referencingClasses
-
lockableMappings
protected java.util.List<DatabaseMapping> lockableMappings
-
queryKeys
protected java.util.Map<java.lang.String,QueryKey> queryKeys
-
sequenceNumberName
protected java.lang.String sequenceNumberName
-
sequenceNumberField
protected org.eclipse.persistence.internal.helper.DatabaseField sequenceNumberField
-
sessionName
protected transient java.lang.String sessionName
-
constraintDependencies
protected transient java.util.Vector constraintDependencies
-
amendmentMethodName
protected transient java.lang.String amendmentMethodName
-
amendmentClass
protected transient java.lang.Class amendmentClass
-
amendmentClassName
protected java.lang.String amendmentClassName
-
alias
protected java.lang.String alias
-
shouldBeReadOnly
protected boolean shouldBeReadOnly
-
shouldAlwaysConformResultsInUnitOfWork
protected boolean shouldAlwaysConformResultsInUnitOfWork
-
shouldRegisterResultsInUnitOfWork
protected boolean shouldRegisterResultsInUnitOfWork
-
queryManager
protected DescriptorQueryManager queryManager
-
copyPolicy
protected CopyPolicy copyPolicy
-
copyPolicyClassName
protected java.lang.String copyPolicyClassName
-
interfacePolicy
protected InterfacePolicy interfacePolicy
-
optimisticLockingPolicy
protected org.eclipse.persistence.internal.descriptors.OptimisticLockingPolicy optimisticLockingPolicy
-
cascadeLockingPolicies
protected transient java.util.List<org.eclipse.persistence.internal.descriptors.CascadeLockingPolicy> cascadeLockingPolicies
-
wrapperPolicy
protected WrapperPolicy wrapperPolicy
-
changePolicy
protected ObjectChangePolicy changePolicy
-
returningPolicy
protected ReturningPolicy returningPolicy
-
returningPolicies
protected java.util.List<ReturningPolicy> returningPolicies
-
historyPolicy
protected HistoryPolicy historyPolicy
-
partitioningPolicyName
protected java.lang.String partitioningPolicyName
-
partitioningPolicy
protected PartitioningPolicy partitioningPolicy
-
cmpPolicy
protected CMPPolicy cmpPolicy
-
cachePolicy
protected CachePolicy cachePolicy
-
multitenantPolicy
protected MultitenantPolicy multitenantPolicy
-
serializedObjectPolicy
protected SerializedObjectPolicy serializedObjectPolicy
-
fetchGroupManager
protected FetchGroupManager fetchGroupManager
-
properties
protected java.util.Map properties
Additional properties may be added.
-
unconvertedProperties
protected java.util.Map<java.lang.String,java.util.List<java.lang.String>> unconvertedProperties
Allow the user to defined un-converted properties which will be initialized at runtime.
-
initializationStage
protected transient int initializationStage
-
interfaceInitializationStage
protected transient int interfaceInitializationStage
-
UNINITIALIZED
protected static final int UNINITIALIZED
The following are the [initializationStage] states the descriptor passes through during the initialization.- See Also:
- Constant Field Values
-
PREINITIALIZED
protected static final int PREINITIALIZED
- See Also:
- Constant Field Values
-
INITIALIZED
protected static final int INITIALIZED
- See Also:
- Constant Field Values
-
POST_INITIALIZED
protected static final int POST_INITIALIZED
- See Also:
- Constant Field Values
-
ERROR
protected static final int ERROR
- See Also:
- Constant Field Values
-
descriptorType
protected int descriptorType
-
NORMAL
protected static final int NORMAL
Define valid descriptor types.- See Also:
- Constant Field Values
-
INTERFACE
protected static final int INTERFACE
- See Also:
- Constant Field Values
-
AGGREGATE
protected static final int AGGREGATE
- See Also:
- Constant Field Values
-
AGGREGATE_COLLECTION
protected static final int AGGREGATE_COLLECTION
- See Also:
- Constant Field Values
-
shouldOrderMappings
protected boolean shouldOrderMappings
-
cacheInvalidationPolicy
protected CacheInvalidationPolicy cacheInvalidationPolicy
-
shouldAcquireCascadedLocks
protected boolean shouldAcquireCascadedLocks
PERF: Used to optimize cache locking to only acquire deferred locks when required (no-indirection).
-
cascadedLockingInitialized
protected boolean cascadedLockingInitialized
INTERNAL: flag to indicate the initialization state of cascade locking for this descriptor
-
hasSimplePrimaryKey
protected boolean hasSimplePrimaryKey
PERF: Compute and store if the primary key is simple (direct-mapped) to allow fast extraction.
-
hasMultipleTableConstraintDependecy
protected boolean hasMultipleTableConstraintDependecy
Defines if any mapping reference a field in a secondary table. This is used to disable deferring multiple table writes.
-
UNDEFINED_OBJECT_CHANGE_BEHAVIOR
public static final int UNDEFINED_OBJECT_CHANGE_BEHAVIOR
- See Also:
- Constant Field Values
-
SEND_OBJECT_CHANGES
public static final int SEND_OBJECT_CHANGES
- See Also:
- Constant Field Values
-
INVALIDATE_CHANGED_OBJECTS
public static final int INVALIDATE_CHANGED_OBJECTS
- See Also:
- Constant Field Values
-
SEND_NEW_OBJECTS_WITH_CHANGES
public static final int SEND_NEW_OBJECTS_WITH_CHANGES
- See Also:
- Constant Field Values
-
DO_NOT_SEND_CHANGES
public static final int DO_NOT_SEND_CHANGES
- See Also:
- Constant Field Values
-
UNDEFINED_ISOLATATION
public static final int UNDEFINED_ISOLATATION
- See Also:
- Constant Field Values
-
USE_SESSION_CACHE_AFTER_TRANSACTION
public static final int USE_SESSION_CACHE_AFTER_TRANSACTION
- See Also:
- Constant Field Values
-
ISOLATE_NEW_DATA_AFTER_TRANSACTION
public static final int ISOLATE_NEW_DATA_AFTER_TRANSACTION
- See Also:
- Constant Field Values
-
ISOLATE_CACHE_AFTER_TRANSACTION
public static final int ISOLATE_CACHE_AFTER_TRANSACTION
- See Also:
- Constant Field Values
-
ISOLATE_FROM_CLIENT_SESSION
public static final int ISOLATE_FROM_CLIENT_SESSION
- See Also:
- Constant Field Values
-
ISOLATE_CACHE_ALWAYS
public static final int ISOLATE_CACHE_ALWAYS
- See Also:
- Constant Field Values
-
shouldUseFullChangeSetsForNewObjects
public static boolean shouldUseFullChangeSetsForNewObjects
INTERNAL: Backdoor for using changes sets for new objects.
-
isNativeConnectionRequired
protected boolean isNativeConnectionRequired
Allow connection unwrapping to be configured.
-
idValidation
protected IdValidation idValidation
Allow zero primary key validation to be configured.
-
primaryKeyIdValidations
protected java.util.List<IdValidation> primaryKeyIdValidations
Allow zero primary key validation to be configured per field.
-
derivesIdMappings
protected java.util.Map<java.lang.String,DatabaseMapping> derivesIdMappings
-
defaultQueryRedirector
protected QueryRedirector defaultQueryRedirector
-
defaultReadAllQueryRedirector
protected QueryRedirector defaultReadAllQueryRedirector
-
defaultReadObjectQueryRedirector
protected QueryRedirector defaultReadObjectQueryRedirector
-
defaultReportQueryRedirector
protected QueryRedirector defaultReportQueryRedirector
-
defaultUpdateObjectQueryRedirector
protected QueryRedirector defaultUpdateObjectQueryRedirector
-
defaultInsertObjectQueryRedirector
protected QueryRedirector defaultInsertObjectQueryRedirector
-
defaultDeleteObjectQueryRedirector
protected QueryRedirector defaultDeleteObjectQueryRedirector
-
defaultQueryRedirectorClassName
protected java.lang.String defaultQueryRedirectorClassName
-
defaultReadAllQueryRedirectorClassName
protected java.lang.String defaultReadAllQueryRedirectorClassName
-
defaultReadObjectQueryRedirectorClassName
protected java.lang.String defaultReadObjectQueryRedirectorClassName
-
defaultReportQueryRedirectorClassName
protected java.lang.String defaultReportQueryRedirectorClassName
-
defaultUpdateObjectQueryRedirectorClassName
protected java.lang.String defaultUpdateObjectQueryRedirectorClassName
-
defaultInsertObjectQueryRedirectorClassName
protected java.lang.String defaultInsertObjectQueryRedirectorClassName
-
defaultDeleteObjectQueryRedirectorClassName
protected java.lang.String defaultDeleteObjectQueryRedirectorClassName
-
sequence
protected Sequence sequence
Store the Sequence used for the descriptor.
-
mappingsPostCalculateChanges
protected java.util.List<DatabaseMapping> mappingsPostCalculateChanges
Mappings that require postCalculateChanges method to be called
-
mappingsPostCalculateChangesOnDeleted
protected java.util.List<DatabaseMapping> mappingsPostCalculateChangesOnDeleted
Mappings that require postCalculateChangesOnDeleted method to be called
-
additionalAggregateCollectionKeyFields
protected transient java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> additionalAggregateCollectionKeyFields
used by aggregate descriptors to hold additional fields needed when they are stored in an AggregatateCollection These fields are generally foreign key fields that are required in addition to the fields in the descriptor's mappings to uniquely identify the Aggregate
-
preDeleteMappings
protected java.util.List<DatabaseMapping> preDeleteMappings
stores a list of mappings that require preDelete as a group prior to the delete individually
-
additionalWritableMapKeyFields
protected transient java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> additionalWritableMapKeyFields
stores fields that are written by Map key mappings so they can be checked for multiple writable mappings
-
hasRelationships
protected boolean hasRelationships
whether this descriptor has any relationships through its mappings, through inheritance, or through aggregates
-
foreignKeyValuesForCaching
protected java.util.Set<org.eclipse.persistence.internal.helper.DatabaseField> foreignKeyValuesForCaching
Stores a set of FK fields that will be cached to later retrieve noncacheable mappings
-
hasNoncacheableMappings
protected boolean hasNoncacheableMappings
caches if this descriptor has any non cacheable mappings
-
weavingUsesPropertyAccess
protected boolean weavingUsesPropertyAccess
This flag stores whether this descriptor is using Property access based on JPA semantics. It is used to modify the behavior of our weaving functionality as it pertains to adding annotations to fields
-
virtualAttributeMethods
protected java.util.List<org.eclipse.persistence.internal.descriptors.VirtualAttributeMethodInfo> virtualAttributeMethods
A list of methods that are used by virtual mappings. This list is used to control weaving of methods used for virtual access
-
accessorTree
protected java.util.List<AttributeAccessor> accessorTree
A list of AttributeAccessors in order of access from root to leaf to arrive at current AggregateDescriptor. Only application for Aggregate Descriptors.
-
descriptorCustomizerClassName
protected java.lang.String descriptorCustomizerClassName
JPA DescriptorCustomizer list stored here to preserve it when caching the project
-
shouldLockForClone
protected boolean shouldLockForClone
This flag controls if a UOW should acquire locks for clone or simple clone the instance passed to registerExistingObject. If the IdentityMap type does not have concurrent access this can save a return to the identity map for cloning.
-
-
Method Detail
-
addAbstractQueryKey
public void addAbstractQueryKey(java.lang.String queryKeyName)
PUBLIC: This method should only be used for interface descriptors. It adds an abstract query key to the interface descriptor. Any implementors of that interface must define the query key defined by this abstract query key.
-
addCascadeLockingPolicy
public void addCascadeLockingPolicy(org.eclipse.persistence.internal.descriptors.CascadeLockingPolicy policy)
INTERNAL: Add the cascade locking policy to all children that have a relationship to this descriptor either by inheritance or by encapsulation/aggregation.- Parameters:
policy- - the CascadeLockingPolicy
-
addConstraintDependencies
public void addConstraintDependencies(java.lang.Class dependencies)
ADVANCED: EclipseLink automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings. In some case when 1:1 are not defined it may be required to tell the descriptor about a constraint, this defines that this descriptor has a foreign key constraint to another class and must be inserted after instances of the other class.
-
addConstraintDependency
public void addConstraintDependency(java.lang.Class dependencies)
ADVANCED: EclipseLink automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings. In some case when 1:1 are not defined it may be required to tell the descriptor about a constraint, this defines that this descriptor has a foreign key constraint to another class and must be inserted after instances of the other class.
-
newDirectMapping
public AbstractDirectMapping newDirectMapping()
Return a new direct/basic mapping for this type of descriptor.
-
newAggregateMapping
public AggregateMapping newAggregateMapping()
Return a new aggregate/embedded mapping for this type of descriptor.
-
newAggregateCollectionMapping
public DatabaseMapping newAggregateCollectionMapping()
Return a new aggregate collection/element collection mapping for this type of descriptor.
-
newDirectCollectionMapping
public DatabaseMapping newDirectCollectionMapping()
Return a new direct collection/element collection mapping for this type of descriptor.
-
newOneToOneMapping
public ObjectReferenceMapping newOneToOneMapping()
Return a new one to one mapping for this type of descriptor.
-
newManyToOneMapping
public ObjectReferenceMapping newManyToOneMapping()
Return a new many to one mapping for this type of descriptor.
-
newOneToManyMapping
public CollectionMapping newOneToManyMapping()
Return a new one to many mapping for this type of descriptor.
-
newUnidirectionalOneToManyMapping
public CollectionMapping newUnidirectionalOneToManyMapping()
Return a new one to many mapping for this type of descriptor.
-
newManyToManyMapping
public CollectionMapping newManyToManyMapping()
Return a new one to many mapping for this type of descriptor.
-
addDirectMapping
public DatabaseMapping addDirectMapping(java.lang.String attributeName, java.lang.String fieldName)
PUBLIC: Add a direct to field mapping to the receiver. The new mapping specifies that an instance variable of the class of objects which the receiver describes maps in the default manner for its type to the indicated database field.- Parameters:
attributeName- is the name of an instance variable of the class which the receiver describes.fieldName- is the name of the database column which corresponds with the designated instance variable.- Returns:
- The newly created DatabaseMapping is returned.
-
addDirectMapping
public DatabaseMapping addDirectMapping(java.lang.String attributeName, java.lang.String getMethodName, java.lang.String setMethodName, java.lang.String fieldName)
PUBLIC: Add a direct to field mapping to the receiver. The new mapping specifies that a variable accessed by the get and set methods of the class of objects which the receiver describes maps in the default manner for its type to the indicated database field.
-
addDirectQueryKey
public void addDirectQueryKey(java.lang.String queryKeyName, java.lang.String fieldName)PUBLIC: Add a query key to the descriptor. Query keys define Java aliases to database fields.
-
addForeignKeyFieldNameForMultipleTable
public void addForeignKeyFieldNameForMultipleTable(java.lang.String sourceForeignKeyFieldName, java.lang.String targetPrimaryKeyFieldName) throws DescriptorExceptionPUBLIC: This protocol can be used to associate multiple tables with foreign key information. Use this method to associate secondary tables to a primary table. Specify the source foreign key field to the target primary key field. The join criteria will be generated based on the fields provided. Unless the customary insert order is specified by the user (using setMultipleTableInsertOrder method) the (automatically generated) table insert order will ensure that insert into target table happens before insert into the source table (there may be a foreign key constraint in the database that requires target table to be inserted before the source table).- Throws:
DescriptorException
-
addForeignKeyFieldForMultipleTable
public void addForeignKeyFieldForMultipleTable(org.eclipse.persistence.internal.helper.DatabaseField sourceForeignKeyField, org.eclipse.persistence.internal.helper.DatabaseField targetPrimaryKeyField) throws DescriptorExceptionPUBLIC: This protocol can be used to associate multiple tables with foreign key information. Use this method to associate secondary tables to a primary table. Specify the source foreign key field to the target primary key field. The join criteria will be generated based on the fields provided.- Throws:
DescriptorException
-
addMapping
public DatabaseMapping addMapping(DatabaseMapping mapping)
PUBLIC: Add a database mapping to the receiver. Perform any required initialization of both the mapping and the receiving descriptor as a result of adding the new mapping.
-
validateMappingType
protected void validateMappingType(DatabaseMapping mapping)
-
addPrimaryKeyFieldName
public void addPrimaryKeyFieldName(java.lang.String fieldName)
PUBLIC: Specify the primary key field of the descriptors table. This should be called for each field that makes up the primary key of the table. If the descriptor has many tables, this must be the primary key in the first table, if the other tables have the same primary key nothing else is required, otherwise a primary key/foreign key field mapping must be provided for each of the other tables.
-
addPrimaryKeyField
public void addPrimaryKeyField(org.eclipse.persistence.internal.helper.DatabaseField field)
ADVANCED: Specify the primary key field of the descriptors table. This should be called for each field that makes up the primary key of the table. This can be used for advanced field types, such as XML nodes, or to set the field type.
-
addQueryKey
public void addQueryKey(QueryKey queryKey)
PUBLIC: Add a query key to the descriptor. Query keys define Java aliases to database fields.
-
addTable
public void addTable(org.eclipse.persistence.internal.helper.DatabaseTable table)
PUBLIC: Specify the table for the class of objects the receiver describes. This method is used if there is more than one table.
-
addTableName
public void addTableName(java.lang.String tableName)
PUBLIC: Specify the table name for the class of objects the receiver describes. If the table has a qualifier it should be specified using the dot notation, (i.e. "userid.employee"). This method is used if there is more than one table.
-
addUnconvertedProperty
public void addUnconvertedProperty(java.lang.String propertyName, java.lang.String propertyValue, java.lang.String propertyType)PUBLIC: Add an unconverted property (to be initialiazed at runtime)
-
adjustMultipleTableInsertOrder
public void adjustMultipleTableInsertOrder()
INTERNAL: Adjust the order of the tables in the multipleTableInsertOrder Vector according to the FK relationship if one (or more) were previously specified. I.e. target of FK relationship should be inserted before source. If the multipleTableInsertOrder has been specified (presumably by the user) then do not change it.
-
alwaysConformResultsInUnitOfWork
public void alwaysConformResultsInUnitOfWork()
PUBLIC: Used to set the descriptor to always conform in any unit of work query.
-
alwaysRefreshCache
public void alwaysRefreshCache()
PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCache(boolean)with an argument oftrue: it configures aClassDescriptorto always refresh the cache if data is received from the database by any query.However, if a query hits the cache, data is not refreshed regardless of how this setting is configured. For example, by default, when a query for a single object based on its primary key is executed, OracleAS TopLink will first look in the cache for the object. If the object is in the cache, the cached object is returned and data is not refreshed. To avoid cache hits, use the
disableCacheHits()method.Also note that the
UnitOfWorkwill not refresh its registered objects.Use this property with caution because it can lead to poor performance and may refresh on queries when it is not desired. Normally, if you require fresh data, it is better to configure a query with
ObjectLevelReadQuery.refreshIdentityMapResult(). To ensure that refreshes are only done when required, use this method in conjunction withonlyRefreshCacheIfNewerVersion().- See Also:
dontAlwaysRefreshCache()
-
alwaysRefreshCacheOnRemote
public void alwaysRefreshCacheOnRemote()
PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCacheOnRemote(boolean)with an argument oftrue: it configures aClassDescriptorto always remotely refresh the cache if data is received from the database by any query in aRemoteSession.However, if a query hits the cache, data is not refreshed regardless of how this setting is configured. For example, by default, when a query for a single object based on its primary key is executed, OracleAS TopLink will first look in the cache for the object. If the object is in the cache, the cached object is returned and data is not refreshed. To avoid cache hits, use the
disableCacheHitsOnRemote()method.Also note that the
UnitOfWorkwill not refresh its registered objects.Use this property with caution because it can lead to poor performance and may refresh on queries when it is not desired. Normally, if you require fresh data, it is better to configure a query with
ObjectLevelReadQuery.refreshIdentityMapResult(). To ensure that refreshes are only done when required, use this method in conjunction withonlyRefreshCacheIfNewerVersion().- See Also:
dontAlwaysRefreshCacheOnRemote()
-
applyAmendmentMethod
public void applyAmendmentMethod()
ADVANCED: Call the descriptor amendment method. This is called while loading or creating a descriptor that has an amendment method defined.
-
applyAmendmentMethod
public void applyAmendmentMethod(DescriptorEvent event)
INTERNAL: Call the descriptor amendment method. This is called while loading or creating a descriptor that has an amendment method defined.
-
arePrimaryKeyFields
public boolean arePrimaryKeyFields(java.util.Vector fields)
INTERNAL: Used to determine if a foreign key references the primary key.
-
assignDefaultValues
protected void assignDefaultValues(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Some attributes have default values defined in Project. If such the value for the attribute hasn't been set then the default value is assigned.
-
buildBatchCriteriaByPK
public Expression buildBatchCriteriaByPK(ExpressionBuilder builder, ObjectLevelReadQuery query)
INTERNAL: Return the selection criteria used to IN batch fetching.
-
buildCallFromStatement
public org.eclipse.persistence.internal.databaseaccess.DatasourceCall buildCallFromStatement(org.eclipse.persistence.internal.expressions.SQLStatement statement, DatabaseQuery query, org.eclipse.persistence.internal.sessions.AbstractSession session)INTERNAL: Return a call built from a statement. Subclasses may throw an exception if the statement is not appropriate.
-
buildDirectValuesFromFieldValue
public java.util.Vector buildDirectValuesFromFieldValue(java.lang.Object fieldValue) throws DatabaseExceptionINTERNAL: Extract the direct values from the specified field value. Return them in a vector.- Throws:
DatabaseException
-
buildField
public org.eclipse.persistence.internal.helper.DatabaseField buildField(java.lang.String fieldName)
INTERNAL: A DatabaseField is built from the given field name.
-
buildField
public org.eclipse.persistence.internal.helper.DatabaseField buildField(org.eclipse.persistence.internal.helper.DatabaseField field)
INTERNAL: The table of the field is ensured to be unique from the descriptor's tables. If the field has no table the default table is assigned. This is used only in initialization. Fields are ensured to be unique so if the field has already been built it is returned.
-
buildField
public org.eclipse.persistence.internal.helper.DatabaseField buildField(org.eclipse.persistence.internal.helper.DatabaseField field, org.eclipse.persistence.internal.helper.DatabaseTable relationTable)
-
buildFieldValueFromDirectValues
public java.lang.Object buildFieldValueFromDirectValues(java.util.Vector directValues, java.lang.String elementDataTypeName, org.eclipse.persistence.internal.sessions.AbstractSession session) throws DatabaseExceptionINTERNAL: Build the appropriate field value for the specified set of direct values.- Throws:
DatabaseException
-
buildFieldValueFromForeignKeys
public java.lang.Object buildFieldValueFromForeignKeys(java.util.Vector foreignKeys, java.lang.String referenceDataTypeName, org.eclipse.persistence.internal.sessions.AbstractSession session) throws DatabaseExceptionINTERNAL: Build and return the appropriate field value for the specified set of foreign keys (i.e. each row has the fields that make up a foreign key).- Throws:
DatabaseException
-
buildFieldValueFromNestedRow
public java.lang.Object buildFieldValueFromNestedRow(org.eclipse.persistence.internal.sessions.AbstractRecord nestedRow, org.eclipse.persistence.internal.sessions.AbstractSession session) throws DatabaseExceptionINTERNAL: Build and return the field value from the specified nested database row.- Throws:
DatabaseException
-
buildFieldValueFromNestedRows
public java.lang.Object buildFieldValueFromNestedRows(java.util.Vector nestedRows, java.lang.String structureName, org.eclipse.persistence.internal.sessions.AbstractSession session) throws DatabaseExceptionINTERNAL: Build and return the appropriate field value for the specified set of nested rows.- Throws:
DatabaseException
-
buildNestedRowFromFieldValue
public org.eclipse.persistence.internal.sessions.AbstractRecord buildNestedRowFromFieldValue(java.lang.Object fieldValue) throws DatabaseExceptionINTERNAL: Build and return the nested database row from the specified field value.- Throws:
DatabaseException
-
buildNestedRowsFromFieldValue
public java.util.Vector buildNestedRowsFromFieldValue(java.lang.Object fieldValue, org.eclipse.persistence.internal.sessions.AbstractSession session) throws DatabaseExceptionINTERNAL: Build and return the nested rows from the specified field value.- Throws:
DatabaseException
-
checkDatabase
protected void checkDatabase(org.eclipse.persistence.internal.sessions.AbstractSession session)
To check that tables and fields are present in database
-
checkInheritanceTreeAggregateSettings
public void checkInheritanceTreeAggregateSettings(org.eclipse.persistence.internal.sessions.AbstractSession session, AggregateMapping mapping) throws DescriptorExceptionINTERNAL: Verify that an aggregate descriptor's inheritance tree is full of aggregate descriptors.- Throws:
DescriptorException
-
createMultipleTableInsertOrder
protected void createMultipleTableInsertOrder()
INTERNAL: Create multiple table insert order. If its a child descriptor then insert order starts with the same insert order as in the parent. Non-inherited tables ordered to adhere to multipleTableForeignKeys: the target table (the key in multipleTableForeignKeys map) should stand in insert order before any of the source tables (members of the corresponding value in multipleTableForeignKeys).
-
verifyMultipleTableInsertOrder
protected void verifyMultipleTableInsertOrder()
INTERNAL: Verify multiple table insert order provided by the user. If its a child descriptor then insert order starts with the same insert order as in the parent. Non-inherited tables ordered to adhere to multipleTableForeignKeys: the target table (the key in multipleTableForeignKeys map) should stand in insert order before any of the source tables (members of the corresponding value in multipleTableForeignKeys).
-
verifyMultipleTablesForeignKeysTables
protected void verifyMultipleTablesForeignKeysTables()
INTERNAL: Verify that the tables specified in multipleTablesForeignKeysTables are valid.
-
createTableComparison
protected int[][] createTableComparison(java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable> tables, int nStart)INTERNAL: This helper method creates a matrix that contains insertion order comparison for the tables. Comparison is done for indexes from nStart to tables.size()-1.
-
createMultipleTableInsertOrderFromComparison
protected void createMultipleTableInsertOrderFromComparison(int[][] tableComparison, int nStart)INTERNAL: This helper method creates multipleTableInsertOrderFromComparison using comparison matrix created by createTableComparison(getTables()) method call.
-
createTableOrder
protected boolean createTableOrder(int k, int nTables, int[] tableOrder, int[][] tableComparison)INTERNAL: This helper method recursively puts indexes from 0 to nTables-1 into tableOrder according to tableComparison 2 dim array. k is index in tableOrder that currently the method is working on - the method should be called with k = 0.
-
clone
public java.lang.Object clone()
INTERNAL: Clones the descriptor- Overrides:
clonein classjava.lang.Object
-
convertClassNamesToClasses
public void convertClassNamesToClasses(java.lang.ClassLoader classLoader)
INTERNAL: Convert all the class-name-based settings in this Descriptor to actual class-based settings. This method is used when converting a project that has been built with class names to a project with classes.- Parameters:
classLoader-
-
createCopyPolicy
public void createCopyPolicy(java.lang.String policyType)
PUBLIC: Create a copy policy of the type passed in as a string.
-
createInstantiationPolicy
public void createInstantiationPolicy(java.lang.String policyType)
PUBLIC: Create a instantiation policy of the type passed in as a string.
-
descriptorIsAggregate
public void descriptorIsAggregate()
PUBLIC: Sets the descriptor to be an aggregate. An aggregate descriptor is contained within another descriptor's table. Aggregate descriptors are insert/updated/deleted with their owner and cannot exist without their owner as they share the same row. Aggregates are not cached (they are cached as part of their owner) and cannot be read/written/deleted/registered. All aggregate descriptors must call this.
-
descriptorIsAggregateCollection
public void descriptorIsAggregateCollection()
PUBLIC: Sets the descriptor to be part of an aggregate collection. An aggregate collection descriptor stored in a separate table but some of the fields (the primary key) comes from its owner. Aggregate collection descriptors are insert/updated/deleted with their owner and cannot exist without their owner as they share the primary key. Aggregate collections are not cached (they are cached as part of their owner) and cannot be read/written/deleted/registered. All aggregate collection descriptors must call this.
-
descriptorIsForInterface
public void descriptorIsForInterface()
PUBLIC: Sets the descriptor to be for an interface. An interface descriptor allows for other classes to reference an interface or one of several other classes. The implementor classes can be completely unrelated in term of the database stored in distinct tables. Queries can also be done for the interface which will query each of the implementor classes. An interface descriptor cannot define any mappings as an interface is just API and not state, a interface descriptor should define the common query key of its implementors to allow querying. An interface descriptor also does not define a primary key or table or other settings. If an interface only has a single implementor (i.e. a classes public interface or remote) then an interface descriptor should not be defined for it and relationships should be to the implementor class not the interface, in this case the implementor class can add the interface through its interface policy to map queries on the interface to it.
-
descriptorIsNormal
public void descriptorIsNormal()
PUBLIC: Sets the descriptor to be normal. This is the default and means the descriptor is not aggregate or for an interface.
-
disableCacheHits
public void disableCacheHits()
PUBLIC: Allow for cache hits on primary key read object queries to be disabled. This can be used withalwaysRefreshCache()oralwaysRefreshCacheOnRemote()to ensure queries always go to the database.
-
disableCacheHitsOnRemote
public void disableCacheHitsOnRemote()
PUBLIC: Allow for remote session cache hits on primary key read object queries to be disabled. This can be used with alwaysRefreshCacheOnRemote() to ensure queries always go to the server session cache.- See Also:
alwaysRefreshCacheOnRemote()
-
dontAlwaysConformResultsInUnitOfWork
public void dontAlwaysConformResultsInUnitOfWork()
PUBLIC: The descriptor is defined to not conform the results in unit of work in read query. Default.
-
dontAlwaysRefreshCache
public void dontAlwaysRefreshCache()
PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCache(boolean)with an argument offalse: it ensures that aClassDescriptoris not configured to always refresh the cache if data is received from the database by any query.- See Also:
alwaysRefreshCache()
-
dontAlwaysRefreshCacheOnRemote
public void dontAlwaysRefreshCacheOnRemote()
PUBLIC: This method is the equivalent of callingsetShouldAlwaysRefreshCacheOnRemote(boolean)with an argument offalse: it ensures that aClassDescriptoris not configured to always remotely refresh the cache if data is received from the database by any query in aRemoteSession.- See Also:
alwaysRefreshCacheOnRemote()
-
dontDisableCacheHits
public void dontDisableCacheHits()
PUBLIC: Allow for cache hits on primary key read object queries.- See Also:
disableCacheHits()
-
dontDisableCacheHitsOnRemote
public void dontDisableCacheHitsOnRemote()
PUBLIC: Allow for remote session cache hits on primary key read object queries.- See Also:
disableCacheHitsOnRemote()
-
dontOnlyRefreshCacheIfNewerVersion
public void dontOnlyRefreshCacheIfNewerVersion()
PUBLIC: This method is the equivalent of callingsetShouldOnlyRefreshCacheIfNewerVersion(boolean)with an argument offalse: it ensures that aClassDescriptoris not configured to only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field).- See Also:
onlyRefreshCacheIfNewerVersion()
-
extractDefaultTable
protected org.eclipse.persistence.internal.helper.DatabaseTable extractDefaultTable()
INTERNAL: The first table in the tables is always treated as default.
-
getAdditionalAggregateCollectionKeyFields
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getAdditionalAggregateCollectionKeyFields()
INTERNAL: additionalAggregateCollectionKeyFields are used by aggregate descriptors to hold additional fields needed when they are stored in an AggregatateCollection These fields are generally foreign key fields that are required in addition to the fields in the descriptor's mappings to uniquely identify the Aggregate- Returns:
-
getAdditionalTablePrimaryKeyFields
public java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Map<org.eclipse.persistence.internal.helper.DatabaseField,org.eclipse.persistence.internal.helper.DatabaseField>> getAdditionalTablePrimaryKeyFields()
INTERNAL: This is used to map the primary key field names in a multiple table descriptor.
-
getAdditionalWritableMapKeyFields
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getAdditionalWritableMapKeyFields()
INTERNAL: Return a list of fields that are written by map keys Used to determine if there is a multiple writable mappings issue- Returns:
-
getAlias
public java.lang.String getAlias()
PUBLIC: Get the alias
-
getAllFields
public java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> getAllFields()
INTERNAL: Return all the fields which include all child class fields. By default it is initialized to the fields for the current descriptor.
-
getAllSelectionFields
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getAllSelectionFields()
INTERNAL: Return all selection fields which include all child class fields. By default it is initialized to selection fields for the current descriptor.
-
getAllSelectionFields
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getAllSelectionFields(ObjectLevelReadQuery query)
INTERNAL: Return all selection fields which include all child class fields. By default it is initialized to selection fields for the current descriptor.
-
getReturnFieldsToGenerateInsert
public java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> getReturnFieldsToGenerateInsert()
INTERNAL: Return fields used to build insert statement.
-
getReturnFieldsToGenerateUpdate
public java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> getReturnFieldsToGenerateUpdate()
INTERNAL: Return fields used to build update statement.
-
getReturnFieldsToMergeInsert
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getReturnFieldsToMergeInsert()
INTERNAL: Return fields used in to map into entity for insert.
-
getReturnFieldsToMergeUpdate
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getReturnFieldsToMergeUpdate()
INTERNAL: Return fields used in to map into entity for update.
-
getAmendmentClass
public java.lang.Class getAmendmentClass()
PUBLIC: Return the amendment class. The amendment method will be called on the class before initialization to allow for it to initialize the descriptor. The method must be a public static method on the class.
-
getAmendmentClassName
public java.lang.String getAmendmentClassName()
INTERNAL: Return amendment class name, used by the MW.
-
getAmendmentMethodName
public java.lang.String getAmendmentMethodName()
PUBLIC: Return the amendment method. This will be called on the amendment class before initialization to allow for it to initialize the descriptor. The method must be a public static method on the class.
-
getAccessorTree
public java.util.List<AttributeAccessor> getAccessorTree()
- Returns:
- the accessorTree
-
getObjectChangePolicy
public ObjectChangePolicy getObjectChangePolicy()
PUBLIC: Return this objects ObjectChangePolicy.
-
getObjectChangePolicyInternal
public ObjectChangePolicy getObjectChangePolicyInternal()
INTERNAL: Return this objects ObjectChangePolicy and do not lazy initialize
-
getHistoryPolicy
public HistoryPolicy getHistoryPolicy()
PUBLIC: Return this descriptor's HistoryPolicy.
-
getPartitioningPolicy
public PartitioningPolicy getPartitioningPolicy()
PUBLIC: Return the descriptor's partitioning policy.
-
setPartitioningPolicy
public void setPartitioningPolicy(PartitioningPolicy partitioningPolicy)
PUBLIC: Set the descriptor's partitioning policy. A PartitioningPolicy is used to partition the data for a class across multiple difference databases or across a database cluster such as Oracle RAC. Partitioning can provide improved scalability by allowing multiple database machines to service requests.
-
getPartitioningPolicyName
public java.lang.String getPartitioningPolicyName()
PUBLIC: Return the name of the descriptor's partitioning policy. A PartitioningPolicy with the same name must be defined on the Project. A PartitioningPolicy is used to partition the data for a class across multiple difference databases or across a database cluster such as Oracle RAC. Partitioning can provide improved scalability by allowing multiple database machines to service requests.
-
setPartitioningPolicyName
public void setPartitioningPolicyName(java.lang.String partitioningPolicyName)
PUBLIC: Set the name of the descriptor's partitioning policy. A PartitioningPolicy with the same name must be defined on the Project. A PartitioningPolicy is used to partition the data for a class across multiple difference databases or across a database cluster such as Oracle RAC. Partitioning can provide improved scalability by allowing multiple database machines to service requests.
-
getCacheInterceptorClass
public java.lang.Class getCacheInterceptorClass()
A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor. Advanced users could use this interceptor to audit, profile or log cache access. This Interceptor could also be used to redirect or augment the TopLink cache with an alternate cache mechanism. EclipseLink's configurated IdentityMaps will be passed to the Interceptor constructor. As with IdentityMaps an entire class inheritance hierarchy will share the same interceptor.- See Also:
CacheInterceptor
-
getCacheInterceptorClassName
public java.lang.String getCacheInterceptorClassName()
A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor. Advanced users could use this interceptor to audit, profile or log cache access. This Interceptor could also be used to redirect or augment the TopLink cache with an alternate cache mechanism. EclipseLink's configurated IdentityMaps will be passed to the Interceptor constructor. As with IdentityMaps an entire class inheritance hierarchy will share the same interceptor.- See Also:
CacheInterceptor
-
getCacheInvalidationPolicy
public CacheInvalidationPolicy getCacheInvalidationPolicy()
PUBLIC: Return the CacheInvalidationPolicy for this descriptor For uninitialized cache invalidation policies, this will return a NoExpiryCacheInvalidationPolicy- Returns:
- CacheInvalidationPolicy
- See Also:
CacheInvalidationPolicy
-
getCacheSynchronizationType
public int getCacheSynchronizationType()
PUBLIC: Get a value indicating the type of cache synchronization that will be used on objects of this type. Possible values are: SEND_OBJECT_CHANGES INVALIDATE_CHANGED_OBJECTS SEND_NEW_OBJECTS+WITH_CHANGES DO_NOT_SEND_CHANGES
-
getCascadeLockingPolicies
public java.util.List<org.eclipse.persistence.internal.descriptors.CascadeLockingPolicy> getCascadeLockingPolicies()
INTERNAL:
-
getConstraintDependencies
public java.util.Vector getConstraintDependencies()
ADVANCED: automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings. In some case when 1:1 are not defined it may be required to tell the descriptor about a constraint, this defines that this descriptor has a foreign key constraint to another class and must be inserted after instances of the other class.
-
getCopyPolicy
public CopyPolicy getCopyPolicy()
INTERNAL: Returns the copy policy.
-
getCopyPolicyClassName
public java.lang.String getCopyPolicyClassName()
INTERNAL: Returns the name of a Class that implements CopyPolicy Will be instantiated as a copy policy at initialization times using the no-args constructor
-
getDefaultTable
public org.eclipse.persistence.internal.helper.DatabaseTable getDefaultTable()
INTERNAL: The first table in the tables is always treated as default.
-
getDescriptorType
public int getDescriptorType()
ADVANCED: return the descriptor type (NORMAL by default, others include INTERFACE, AGGREGATE, AGGREGATE COLLECTION)
-
getDescriptorTypeValue
public java.lang.String getDescriptorTypeValue()
INTERNAL: This method is explicitly used by the XML reader.
-
getDerivesIdMappinps
public java.util.Collection<DatabaseMapping> getDerivesIdMappinps()
ADVANCED: Return the derives id mappings.
-
getDescriptorCustomizerClassName
public java.lang.String getDescriptorCustomizerClassName()
INTERNAL: DescriptorCustomizer is the JPA equivalent of an amendment method.
-
getDescriptorEventManager
public DescriptorEventManager getDescriptorEventManager()
PUBLIC: Get the event manager for the descriptor. The event manager is responsible for managing the pre/post selectors.
-
getEventManager
public DescriptorEventManager getEventManager()
PUBLIC: Get the event manager for the descriptor. The event manager is responsible for managing the pre/post selectors.- Specified by:
getEventManagerin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getFields
public java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> getFields()
INTERNAL: Return all the fields
-
getSelectionFields
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getSelectionFields()
INTERNAL: Return all selection fields
-
getSelectionFields
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getSelectionFields(ObjectLevelReadQuery query)
INTERNAL: Return all selection fields
-
getForeignKeyValuesForCaching
public java.util.Set<org.eclipse.persistence.internal.helper.DatabaseField> getForeignKeyValuesForCaching()
INTERNAL:
-
getIdentityMapClass
public java.lang.Class getIdentityMapClass()
INTERNAL: Return the class of identity map to be used by this descriptor. The default is the "SoftCacheWeakIdentityMap".
-
getIdentityMapSize
public int getIdentityMapSize()
PUBLIC: Return the size of the identity map.
-
getDescriptorInheritancePolicy
public InheritancePolicy getDescriptorInheritancePolicy()
PUBLIC: The inheritance policy is used to define how a descriptor takes part in inheritance. All inheritance properties for both child and parent classes is configured in inheritance policy. Caution must be used in using this method as it lazy initializes an inheritance policy. Calling this on a descriptor that does not use inheritance will cause problems, #hasInheritance() must always first be called.
-
getInheritancePolicy
public InheritancePolicy getInheritancePolicy()
PUBLIC: The inheritance policy is used to define how a descriptor takes part in inheritance. All inheritance properties for both child and parent classes is configured in inheritance policy. Caution must be used in using this method as it lazy initializes an inheritance policy. Calling this on a descriptor that does not use inheritance will cause problems, #hasInheritance() must always first be called.- Specified by:
getInheritancePolicyin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getInheritancePolicyOrNull
public InheritancePolicy getInheritancePolicyOrNull()
INTERNAL: Return the inheritance policy.
-
getInstantiationPolicy
public org.eclipse.persistence.internal.descriptors.InstantiationPolicy getInstantiationPolicy()
INTERNAL: Returns the instantiation policy.- Specified by:
getInstantiationPolicyin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getInterfacePolicy
public InterfacePolicy getInterfacePolicy()
PUBLIC: Returns the InterfacePolicy. The interface policy allows for a descriptor's public and variable interfaces to be defined. Caution must be used in using this method as it lazy initializes an interface policy. Calling this on a descriptor that does not use interfaces will cause problems, #hasInterfacePolicy() must always first be called.
-
getInterfacePolicyOrNull
public InterfacePolicy getInterfacePolicyOrNull()
INTERNAL: Returns the InterfacePolicy.
-
getJavaClass
public java.lang.Class getJavaClass()
PUBLIC: Return the java class.- Specified by:
getJavaClassin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getJavaClassName
public java.lang.String getJavaClassName()
Return the class name, used by the MW.
-
getLockableMappings
public java.util.List<DatabaseMapping> getLockableMappings()
INTERNAL: Returns a reference to the mappings that must be traverse when locking
-
getMappingForAttributeName
public DatabaseMapping getMappingForAttributeName(java.lang.String attributeName)
PUBLIC: Returns the mapping associated with a given attribute name. This can be used to find a descriptors mapping in a amendment method before the descriptor has been initialized.
-
removeMappingForAttributeName
public DatabaseMapping removeMappingForAttributeName(java.lang.String attributeName)
ADVANCED: Removes the locally defined mapping associated with a given attribute name. This can be used in a amendment method before the descriptor has been initialized.
-
getMappings
public java.util.Vector<DatabaseMapping> getMappings()
PUBLIC: Returns mappings
-
getMultipleTableForeignKeyAssociations
public java.util.Vector getMultipleTableForeignKeyAssociations()
INTERNAL: Returns the foreign key relationships used for multiple tables which were specified by the user. Used by the Project XML writer to output these associations- See Also:
adjustMultipleTableInsertOrder()
-
getMultipleTableForeignKeys
public java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Set<org.eclipse.persistence.internal.helper.DatabaseTable>> getMultipleTableForeignKeys()
INTERNAL: Returns the foreign key relationships used for multiple tables which were specified by the user. The key of the Map is the field in the source table of the foreign key relationship. The value is the field name of the target table.- See Also:
adjustMultipleTableInsertOrder()
-
getMultipleTableInsertOrder
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable> getMultipleTableInsertOrder() throws DescriptorExceptionINTERNAL: Returns the List of DatabaseTables in the order which INSERTS should take place. This order is determined by the foreign key fields which are specified by the user.- Throws:
DescriptorException
-
getMultipleTablePrimaryKeyAssociations
public java.util.Vector getMultipleTablePrimaryKeyAssociations()
INTERNAL: Returns the foreign key relationships used for multiple tables which were specified by the user. Used by the Project XML writer to output these associations- See Also:
adjustMultipleTableInsertOrder()
-
getMultitenantPolicy
public MultitenantPolicy getMultitenantPolicy()
INTERNAL: Retun the multitenant policy
-
getObjectBuilder
public org.eclipse.persistence.internal.descriptors.ObjectBuilder getObjectBuilder()
INTERNAL: Return the object builder- Specified by:
getObjectBuilderin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getOptimisticLockingPolicy
public org.eclipse.persistence.internal.descriptors.OptimisticLockingPolicy getOptimisticLockingPolicy()
PUBLIC: Returns the OptimisticLockingPolicy. By default this is an instance of VersionLockingPolicy.
-
getPreDeleteMappings
public java.util.List<DatabaseMapping> getPreDeleteMappings()
INTERNAL: Set of mappings that require early delete behavior. This is used to handle deletion constraints.
-
addPreDeleteMapping
public void addPreDeleteMapping(DatabaseMapping mapping)
INTERNAL: Add the mapping to be notified before deletion. Must also be added to child descriptors.
-
getPrimaryKeyFieldNames
public java.util.Vector<java.lang.String> getPrimaryKeyFieldNames()
PUBLIC: Return the names of all the primary keys.- Specified by:
getPrimaryKeyFieldNamesin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getPrimaryKeyFields
public java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> getPrimaryKeyFields()
INTERNAL: Return all the primary key fields- Specified by:
getPrimaryKeyFieldsin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getProperties
public java.util.Map getProperties()
PUBLIC: Returns the user defined properties.
-
getProperty
public java.lang.Object getProperty(java.lang.String name)
PUBLIC: Returns the descriptor property associated the given String.
-
getQueryKeyNamed
public QueryKey getQueryKeyNamed(java.lang.String queryKeyName)
INTERNAL: Return the query key with the specified name
-
getQueryKeys
public java.util.Map<java.lang.String,QueryKey> getQueryKeys()
PUBLIC: Return the query keys.
-
getDescriptorQueryManager
public DescriptorQueryManager getDescriptorQueryManager()
PUBLIC: Return the queryManager. The query manager can be used to specify customization of the SQL that generates for this descriptor.
-
getQueryManager
public DescriptorQueryManager getQueryManager()
PUBLIC: Return the queryManager. The query manager can be used to specify customization of the SQL that generates for this descriptor.
-
getRemoteIdentityMapClass
public java.lang.Class getRemoteIdentityMapClass()
INTERNAL: Return the class of identity map to be used by this descriptor. The default is the "SoftCacheWeakIdentityMap".
-
getRootDescriptor
public ClassDescriptor getRootDescriptor()
PUBLIC: This method returns the root descriptor for for this descriptor's class heirarchy. If the user is not using inheritance then the root class will be this class.
-
getRemoteIdentityMapSize
public int getRemoteIdentityMapSize()
PUBLIC: Return the size of the remote identity map.
-
getReturningPolicy
public ReturningPolicy getReturningPolicy()
PUBLIC: Return returning policy.
-
getReturningPolicies
public java.util.List<ReturningPolicy> getReturningPolicies()
PUBLIC: Return returning policy from current descriptor and from mappings
-
getSequenceNumberField
public org.eclipse.persistence.internal.helper.DatabaseField getSequenceNumberField()
INTERNAL: Get sequence number field
-
getSequenceNumberFieldName
public java.lang.String getSequenceNumberFieldName()
PUBLIC: Get sequence number field name
-
getSequenceNumberName
public java.lang.String getSequenceNumberName()
PUBLIC: Get sequence number name
-
getSessionName
public java.lang.String getSessionName()
INTERNAL: Return the name of the session local to this descriptor. This is used by the session broker.
-
getTable
public org.eclipse.persistence.internal.helper.DatabaseTable getTable(java.lang.String tableName) throws DescriptorExceptionINTERNAL: Checks if table name exists with the current descriptor or not.- Throws:
DescriptorException
-
getTableName
public java.lang.String getTableName()
PUBLIC: Return the name of the descriptor's first table. This method must only be called on single table descriptors.
-
getTableNames
public java.util.Vector getTableNames()
PUBLIC: Return the table names.
-
getTablePerClassPolicy
public TablePerClassPolicy getTablePerClassPolicy()
PUBLIC: Returns the TablePerClassPolicy. The table per class policy allows JPA users to configure the TABLE_PER_CLASS inheritance strategy. Calling this on a descriptor that does not use table per class will cause problems, #hasTablePerClassPolicy() must always first be called.
-
getTables
public java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseTable> getTables()
INTERNAL: Return all the tables.
-
getTypedField
public org.eclipse.persistence.internal.helper.DatabaseField getTypedField(org.eclipse.persistence.internal.helper.DatabaseField field)
INTERNAL: searches first descriptor than its ReturningPolicy for an equal field- Specified by:
getTypedFieldin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getWrapperPolicy
public WrapperPolicy getWrapperPolicy()
ADVANCED: Return the WrapperPolicy for this descriptor. This advanced feature can be used to wrap objects with other classes such as CORBA TIE objects or EJBs.
-
hasDependencyOnParts
public boolean hasDependencyOnParts()
INTERNAL: Checks if the class has any private owned parts or other dependencies, (i.e. M:M join table).
-
hasDerivedId
public boolean hasDerivedId()
INTERNAL: returns true if users have designated one or more mappings as IDs. Used for CMP3Policy primary key class processing.
-
hasEventManager
public boolean hasEventManager()
INTERNAL: returns true if a DescriptorEventManager has been set.- Specified by:
hasEventManagerin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
hasInheritance
public boolean hasInheritance()
INTERNAL: Return if this descriptor is involved in inheritance, (is child or parent). Note: If this class is part of table per class inheritance strategy this method will return false.- Specified by:
hasInheritancein classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>- See Also:
hasTablePerClassPolicy()
-
hasInterfacePolicy
public boolean hasInterfacePolicy()
INTERNAL: Return if this descriptor is involved in interface, (is child or parent).
-
hasMultipleTables
public boolean hasMultipleTables()
INTERNAL: Check if descriptor has multiple tables
-
hasNestedIdentityReference
public boolean hasNestedIdentityReference(boolean withChildren)
INTERNAL: Calculates whether descriptor references an entity (directly or through a nested mapping).
-
hasNoncacheableMappings
public boolean hasNoncacheableMappings()
- Returns:
- the hasNoncacheableMappings
-
hasPreDeleteMappings
public boolean hasPreDeleteMappings()
- Returns:
- the preDeleteMappings
-
hasPrivatelyOwnedParts
public boolean hasPrivatelyOwnedParts()
INTERNAL: Checks if the class has any private owned parts are not
-
hasQueryKeyOrMapping
public boolean hasQueryKeyOrMapping(java.lang.String attributeName)
INTERNAL: Checks to see if it has a query key or mapping with the specified name or not.
-
hasRelationships
public boolean hasRelationships()
INTERNAL: return whether this descriptor has any relationships through its mappings, through inheritance, or through aggregates- Returns:
-
hasRelationshipsExceptBackpointer
public boolean hasRelationshipsExceptBackpointer(ClassDescriptor descriptor)
INTERNAL: This method returns true if this descriptor has either a ForeignReferenceMapping to an object aside from the one described by descriptor or more than one ForeignReferenceMapping to descriptor. (i.e. It determines if there is any mapping aside from a backpointer to a mapping defined in descriptor)- Parameters:
descriptor-- Returns:
-
hasReturningPolicy
public boolean hasReturningPolicy()
INTERNAL: Return if this descriptor has Returning policy.
-
hasReturningPolicies
public boolean hasReturningPolicies()
INTERNAL: Return if this descriptor or descriptors from mappings has Returning policy.
-
hasSerializedObjectPolicy
public boolean hasSerializedObjectPolicy()
INTERNAL:
-
getSerializedObjectPolicy
public SerializedObjectPolicy getSerializedObjectPolicy()
INTERNAL:
-
setSerializedObjectPolicy
public void setSerializedObjectPolicy(SerializedObjectPolicy serializedObjectPolicy)
INTERNAL:
-
hasWrapperPolicy
public boolean hasWrapperPolicy()
INTERNAL: Return if a wrapper policy is used.
-
initialize
public void initialize(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Initialize the mappings as a separate step. This is done as a separate step to ensure that inheritance has been first resolved.- Throws:
DescriptorException
-
initialize
public void initialize(DescriptorQueryManager queryManager, org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Initialize the query manager specific to the descriptor type.
-
initializeAggregateInheritancePolicy
public void initializeAggregateInheritancePolicy(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: This initialized method is used exclusively for inheritance. It passes in true if the child descriptor is isolated. This is needed by regular aggregate descriptors (because they require review); but not by SDK aggregate descriptors.
-
initializeMultipleTablePrimaryKeyFields
public void initializeMultipleTablePrimaryKeyFields()
INTERNAL: Rebuild the multiple table primary key map.
-
initializeProperties
protected void initializeProperties(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Initialize the descriptor properties such as write lock and sequencing.- Throws:
DescriptorException
-
interfaceInitialization
public void interfaceInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Allow the descriptor to initialize any dependencies on this session.- Throws:
DescriptorException
-
isAbstract
public boolean isAbstract()
INTERNAL: Convenience method to return true if the java class from this descriptor is abstract.
-
isAggregateCollectionDescriptor
public boolean isAggregateCollectionDescriptor()
PUBLIC: Return true if this descriptor is an aggregate collection descriptor
-
isAggregateDescriptor
public boolean isAggregateDescriptor()
PUBLIC: Return true if this descriptor is an aggregate descriptor
-
isChildDescriptor
public boolean isChildDescriptor()
PUBLIC: Return if the descriptor defines inheritance and is a child.
-
isEISDescriptor
public boolean isEISDescriptor()
PUBLIC: Return if the descriptor maps to an EIS or NoSQL datasource.
-
isObjectRelationalDataTypeDescriptor
public boolean isObjectRelationalDataTypeDescriptor()
PUBLIC: Return if the descriptor maps to an object-relational structured type.
-
isXMLDescriptor
public boolean isXMLDescriptor()
PUBLIC: Return if the descriptor maps to XML.
-
isRelationalDescriptor
public boolean isRelationalDescriptor()
PUBLIC: Return if the descriptor maps to a relational table.
-
isDescriptorForInterface
public boolean isDescriptorForInterface()
PUBLIC: Return if the java class is an interface.
-
isDescriptorTypeAggregate
public boolean isDescriptorTypeAggregate()
PUBLIC return true if this descriptor is any type of aggregate descriptor.
-
isDescriptorTypeNormal
public boolean isDescriptorTypeNormal()
INTERNAL: return true if this descriptor is an entity. (The descriptor may be a mappedSuperclass - only in the internal case during metamodel processing)
-
isFullyInitialized
public boolean isFullyInitialized()
INTERNAL: Check if the descriptor is finished initialization.
-
isInitialized
protected boolean isInitialized(int initializationStage)
INTERNAL: Check if descriptor is already initialized for the level of initialization. 1 = pre 2 = mapping 3 = post
-
isInterfaceChildDescriptor
public boolean isInterfaceChildDescriptor()
INTERNAL: Return if the descriptor defines inheritance and is a child.
-
isInterfaceInitialized
protected boolean isInterfaceInitialized(int interfaceInitializationStage)
INTERNAL: Check if interface descriptor is already initialized for the level of initialization. 1 = pre 2 = mapping 3 = post
-
isInvalid
public boolean isInvalid()
INTERNAL: Return if an error occurred during initialization which should abort any further initialization.
-
isIsolated
public boolean isIsolated()
PUBLIC: Returns true if the descriptor represents an isolated class
-
isProtectedIsolation
public boolean isProtectedIsolation()
PUBLIC: Returns true if the descriptor represents an isolated class
-
isSharedIsolation
public boolean isSharedIsolation()
PUBLIC: Returns true if the descriptor represents an isolated class
-
isMultipleTableDescriptor
public boolean isMultipleTableDescriptor()
INTERNAL: Return if this descriptor has more than one table.
-
isPrimaryKeySetAfterInsert
public boolean isPrimaryKeySetAfterInsert(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Indicates whether pk or some of its components set after insert into the database. Shouldn't be called before ClassDescriptor has been initialized.
-
shouldLockForClone
public boolean shouldLockForClone()
ADVANCED: When set to false, this setting will allow the UOW to avoid locking the shared cache instance in order to perform a clone. Caution should be taken as setting this to false may allow cloning of partial updates
-
shouldUseFullChangeSetsForNewObjects
public boolean shouldUseFullChangeSetsForNewObjects()
INTERNAL: Return if change sets are required for new objects.
-
onlyRefreshCacheIfNewerVersion
public void onlyRefreshCacheIfNewerVersion()
PUBLIC: This method is the equivalent of callingsetShouldOnlyRefreshCacheIfNewerVersion(boolean)with an argument oftrue: it configures aClassDescriptorto only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field) and as long as one of the following is true:- the
ClassDescriptorwas configured by callingalwaysRefreshCache()oralwaysRefreshCacheOnRemote(), - the query was configured by calling
ObjectLevelReadQuery.refreshIdentityMapResult(), or - the query was a call to
Session.refreshObject(java.lang.Object)
However, if a query hits the cache, data is not refreshed regardless of how this setting is configured. For example, by default, when a query for a single object based on its primary key is executed, EclipseLink will first look in the cache for the object. If the object is in the cache, the cached object is returned and data is not refreshed. To avoid cache hits, use the
disableCacheHits()method.Also note that the
UnitOfWorkwill not refresh its registered objects.- See Also:
dontOnlyRefreshCacheIfNewerVersion()
- the
-
postInitialize
public void postInitialize(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Post initializations after mappings are initialized.- Throws:
DescriptorException
-
notifyReferencingDescriptorsOfIsolation
public void notifyReferencingDescriptorsOfIsolation(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Configure all descriptors referencing this class to be protected and update their cache settings.
-
preInitialize
public void preInitialize(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Allow the descriptor to initialize any dependencies on this session.- Throws:
DescriptorException
-
prepareCascadeLockingPolicy
protected void prepareCascadeLockingPolicy(DatabaseMapping mapping)
INTERNAL:
-
preInitializeInheritancePolicy
protected void preInitializeInheritancePolicy(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionHook together the inheritance policy tree.- Throws:
DescriptorException
-
preInterfaceInitialization
public void preInterfaceInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Allow the descriptor to initialize any dependencies on this session.- Throws:
DescriptorException
-
rehashFieldDependancies
public void rehashFieldDependancies(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Rehash any hashtables based on fields. This is used to clone descriptors for aggregates, which hammer field names, it is probably better not to hammer the field name and this should be refactored.
-
reInitializeJoinedAttributes
public void reInitializeJoinedAttributes()
INTERNAL: A user should not be setting which attributes to join or not to join after descriptor initialization; provided only for backwards compatibility.
-
remoteInitialization
public void remoteInitialization(DistributedSession session)
INTERNAL: Used to initialize a remote descriptor.
-
removeProperty
public void removeProperty(java.lang.String property)
PUBLIC: Remove the user defined property.
-
requiresInitialization
public boolean requiresInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Aggregate and Interface descriptors do not require initialization as they are cloned and initialized by each mapping. Descriptors with table per tenant policies are cloned per client session (per tenant) so do not initialize the original descriptor.
-
selfValidationAfterInitialization
protected void selfValidationAfterInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Validate that the descriptor was defined correctly. This allows for checks to be done that require the descriptor initialization to be completed.- Throws:
DescriptorException
-
selfValidationBeforeInitialization
protected void selfValidationBeforeInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session) throws DescriptorExceptionINTERNAL: Validate that the descriptor's non-mapping attribute are defined correctly.- Throws:
DescriptorException
-
setAdditionalTablePrimaryKeyFields
protected void setAdditionalTablePrimaryKeyFields(org.eclipse.persistence.internal.helper.DatabaseTable table, org.eclipse.persistence.internal.helper.DatabaseField field1, org.eclipse.persistence.internal.helper.DatabaseField field2)INTERNAL: This is used to map the primary key field names in a multiple table descriptor.
-
toggleAdditionalTablePrimaryKeyFields
protected void toggleAdditionalTablePrimaryKeyFields()
INTERNAL: Eclipselink needs additionalTablePKFields entries to be associated with tables other than the main (getTables.get(0)) one. Also in case of two non-main tables additionalTablePKFields entry should be associated with the one father down insert order.
-
setAdditionalTablePrimaryKeyFields
public void setAdditionalTablePrimaryKeyFields(java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Map<org.eclipse.persistence.internal.helper.DatabaseField,org.eclipse.persistence.internal.helper.DatabaseField>> additionalTablePrimaryKeyFields)
INTERNAL: This is used to map the primary key field names in a multiple table descriptor.
-
setAlias
public void setAlias(java.lang.String alias)
PUBLIC: Set the alias
-
setAllFields
protected void setAllFields(java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> allFields)
INTERNAL: Set all the fields.
-
setAmendmentClass
public void setAmendmentClass(java.lang.Class amendmentClass)
PUBLIC: Set the amendment class. The amendment method will be called on the class before initialization to allow for it to initialize the descriptor. The method must be a public static method on the class.
-
setAmendmentClassName
public void setAmendmentClassName(java.lang.String amendmentClassName)
INTERNAL: Return the amendment class name, used by the MW.
-
setAmendmentMethodName
public void setAmendmentMethodName(java.lang.String amendmentMethodName)
PUBLIC: Set the amendment method. This will be called on the amendment class before initialization to allow for it to initialize the descriptor. The method must be a public static method on the class.
-
setAccessorTree
public void setAccessorTree(java.util.List<AttributeAccessor> accessorTree)
- Parameters:
accessorTree- the accessorTree to set
-
setCacheSynchronizationType
public void setCacheSynchronizationType(int type)
PUBLIC: Set the type of cache synchronization that will be used on objects of this type. Possible values are: SEND_OBJECT_CHANGES INVALIDATE_CHANGED_OBJECTS SEND_NEW_OBJECTS_WITH_CHANGES DO_NOT_SEND_CHANGES Note: Cache Synchronization type cannot be altered for descriptors that are set as isolated using the setIsIsolated method.- Parameters:
type- int The synchronization type for this descriptor
-
setObjectChangePolicy
public void setObjectChangePolicy(ObjectChangePolicy policy)
PUBLIC: Set the ObjectChangePolicy for this descriptor.
-
setHistoryPolicy
public void setHistoryPolicy(HistoryPolicy policy)
PUBLIC: Set the HistoryPolicy for this descriptor.
-
setCacheInterceptorClass
public void setCacheInterceptorClass(java.lang.Class cacheInterceptorClass)
PUBLIC: A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor. Advanced users could use this interceptor to audit, profile or log cache access. This Interceptor could also be used to redirect or augment the TopLink cache with an alternate cache mechanism. EclipseLink's configurated IdentityMaps will be passed to the Interceptor constructor. As with IdentityMaps an entire class inheritance hierarchy will share the same interceptor.- See Also:
CacheInterceptor
-
setCacheInterceptorClassName
public void setCacheInterceptorClassName(java.lang.String cacheInterceptorClassName)
PUBLIC: A CacheInterceptor is an adaptor that when overridden and assigned to a Descriptor all interaction between EclipseLink and the internal cache for that class will pass through the Interceptor. Advanced users could use this interceptor to audit, profile or log cache access. This Interceptor could also be used to redirect or augment the TopLink cache with an alternate cache mechanism. EclipseLink's configurated IdentityMaps will be passed to the Interceptor constructor. As with IdentityMaps an entire class inheritance hierarchy will share the same interceptor.- See Also:
CacheInterceptor
-
setCacheInvalidationPolicy
public void setCacheInvalidationPolicy(CacheInvalidationPolicy policy)
PUBLIC: Set the Cache Invalidation Policy for this descriptor.- See Also:
CacheInvalidationPolicy
-
setConstraintDependencies
public void setConstraintDependencies(java.util.Vector constraintDependencies)
ADVANCED: automatically orders database access through the foreign key information provided in 1:1 and 1:m mappings. In some case when 1:1 are not defined it may be required to tell the descriptor about a constraint, this defines that this descriptor has a foreign key constraint to another class and must be inserted after instances of the other class.
-
setCopyPolicy
public void setCopyPolicy(CopyPolicy policy)
INTERNAL: Set the copy policy. This would be 'protected' but the EJB stuff in another package needs it to be public
-
setCopyPolicyClassName
public void setCopyPolicyClassName(java.lang.String className)
INTERNAL: Sets the name of a Class that implements CopyPolicy Will be instantiatied as a copy policy at initialization times using the no-args constructor
-
setDefaultTable
public void setDefaultTable(org.eclipse.persistence.internal.helper.DatabaseTable defaultTable)
INTERNAL: The descriptors default table can be configured if the first table is not desired.
-
setDefaultTableName
public void setDefaultTableName(java.lang.String defaultTableName)
PUBLIC: The descriptors default table can be configured if the first table is not desired.
-
setDescriptorCustomizerClassName
public void setDescriptorCustomizerClassName(java.lang.String descriptorCustomizerClassName)
INTERNAL: Sets the JPA DescriptorCustomizer class name. DescriptorCustomizer is the JPA equivalent of an amendment method.
-
setDescriptorType
public void setDescriptorType(int descriptorType)
ADVANCED: set the descriptor type (NORMAL by default, others include INTERFACE, AGGREGATE, AGGREGATE COLLECTION)
-
setDescriptorTypeValue
public void setDescriptorTypeValue(java.lang.String value)
INTERNAL: This method is explicitly used by the XML reader.
-
setEventManager
public void setEventManager(DescriptorEventManager eventManager)
INTERNAL: Set the event manager for the descriptor. The event manager is responsible for managing the pre/post selectors.- Specified by:
setEventManagerin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
setExistenceChecking
public void setExistenceChecking(java.lang.String token) throws DescriptorExceptionINTERNAL: OBSOLETE - old reader. This method is explicitly used by the Builder only.- Throws:
DescriptorException
-
setFields
public void setFields(java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseField> fields)
INTERNAL: Set the fields used by this descriptor.
-
setForeignKeyFieldNamesForMultipleTable
public void setForeignKeyFieldNamesForMultipleTable(java.util.Vector associations) throws DescriptorExceptionINTERNAL: This method is used by the XML Deployment ClassDescriptor to read and write these mappings- Throws:
DescriptorException
-
setFullyMergeEntity
public void setFullyMergeEntity(boolean fullyMergeEntity)
- Parameters:
fullyMergeEntity- the fullyMergeEntity to set
-
setIdentityMapClass
public void setIdentityMapClass(java.lang.Class theIdentityMapClass)
PUBLIC: Set the class of identity map to be used by this descriptor. The default is the "FullIdentityMap".
-
setIdentityMapSize
public void setIdentityMapSize(int identityMapSize)
PUBLIC: Set the size of the identity map to be used by this descriptor. The default is the 100.
-
setInheritancePolicy
public void setInheritancePolicy(InheritancePolicy inheritancePolicy)
INTERNAL: Sets the inheritance policy.- Specified by:
setInheritancePolicyin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
setReturningPolicy
public void setReturningPolicy(ReturningPolicy returningPolicy)
PUBLIC: Sets the returning policy.
-
setInitializationStage
protected void setInitializationStage(int initializationStage)
INTERNAL:
-
setInstantiationPolicy
public void setInstantiationPolicy(org.eclipse.persistence.internal.descriptors.InstantiationPolicy instantiationPolicy)
INTERNAL: Sets the instantiation policy.- Specified by:
setInstantiationPolicyin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
setInterfaceInitializationStage
protected void setInterfaceInitializationStage(int interfaceInitializationStage)
INTERNAL:
-
setInterfacePolicy
public void setInterfacePolicy(InterfacePolicy interfacePolicy)
INTERNAL: Sets the interface policy.
-
setInternalDefaultTable
public void setInternalDefaultTable()
INTERNAL: Set the default table if one if not already set. This method will extract the default table.
-
setInternalDefaultTable
public void setInternalDefaultTable(org.eclipse.persistence.internal.helper.DatabaseTable defaultTable)
INTERNAL: Set the default table if one if not already set. This method will set the table that is provided as the default.
-
setIsIsolated
@Deprecated public void setIsIsolated(boolean isIsolated)
Deprecated.as of EclipseLink 2.2PUBLIC: Used to set if the class that this descriptor represents should be isolated from the shared cache. Isolated objects will only be cached locally in the ClientSession, never in the ServerSession cache. This is the best method for disabling caching. Note: Calling this method with true will also set the cacheSynchronizationType to DO_NOT_SEND_CHANGES since isolated objects cannot be sent by cache synchronization.- See Also:
setCacheIsolation(CacheIsolationType)
-
setCacheable
public void setCacheable(java.lang.Boolean cacheable)
INTERNAL: Set entity @Cacheable annotation value in cache configuration object.- Parameters:
cacheable- Entity @Cacheable annotation value for current class ornullif @Cacheable annotation is not set. Parent values are ignored, value shall refer to current class only. This value should be set only when SharedCacheMode allows to override caching on entity level (DISABLE_SELECTIVE or ENABLE_SELECTIVE).
-
getCacheIsolation
public CacheIsolationType getCacheIsolation()
PUBLIC: Controls how the Entity instances will be cached. See the CacheIsolationType for details on the options.- Returns:
- the isolationType
-
setCacheIsolation
public void setCacheIsolation(CacheIsolationType isolationType)
PUBLIC: Controls how the Entity instances and data will be cached. See the CacheIsolationType for details on the options. To disable all second level caching simply set CacheIsolationType.ISOLATED. Note that setting the isolation will automatically set the corresponding cacheSynchronizationType. ISOLATED = DO_NOT_SEND_CHANGES, PROTECTED and SHARED = SEND_OBJECT_CHANGES
-
shouldIsolateObjectsInUnitOfWork
public boolean shouldIsolateObjectsInUnitOfWork()
INTERNAL: Return if the unit of work should by-pass the session cache. Objects will be built in the unit of work, and never merged into the session cache.
-
shouldIsolateProtectedObjectsInUnitOfWork
public boolean shouldIsolateProtectedObjectsInUnitOfWork()
INTERNAL: Return if the unit of work should by-pass the IsolatedSession cache. Objects will be built/merged into the unit of work and into the session cache. but not built/merge into the IsolatedClientSession cache.
-
shouldIsolateObjectsInUnitOfWorkEarlyTransaction
public boolean shouldIsolateObjectsInUnitOfWorkEarlyTransaction()
INTERNAL: Return if the unit of work should by-pass the session cache after an early transaction.
-
shouldUseSessionCacheInUnitOfWorkEarlyTransaction
public boolean shouldUseSessionCacheInUnitOfWorkEarlyTransaction()
INTERNAL: Return if the unit of work should use the session cache after an early transaction.
-
getUnconvertedProperties
public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getUnconvertedProperties()
INTERNAL: Used to store un-converted properties, which are subsequenctly converted at runtime (through the convertClassNamesToClasses method.
-
getUnitOfWorkCacheIsolationLevel
public int getUnitOfWorkCacheIsolationLevel()
ADVANCED: Return the unit of work cache isolation setting. This setting configures how the session cache will be used in a unit of work.- See Also:
setUnitOfWorkCacheIsolationLevel(int)
-
setUnitOfWorkCacheIsolationLevel
public void setUnitOfWorkCacheIsolationLevel(int unitOfWorkCacheIsolationLevel)
ADVANCED: This setting configures how the session cache will be used in a unit of work. Most of the options only apply to a unit of work in an early transaction, such as a unit of work that was flushed (writeChanges), issued a modify query, or acquired a pessimistic lock.USE_SESSION_CACHE_AFTER_TRANSACTION - Objects built from new data accessed after a unit of work early transaction are stored in the session cache. This options is the most efficient as it allows the cache to be used after an early transaction. This should only be used if it is known that this class is not modified in the transaction, otherwise this could cause uncommitted data to be loaded into the session cache. ISOLATE_NEW_DATA_AFTER_TRANSACTION - Default (when using caching): Objects built from new data accessed after a unit of work early transaction are only stored in the unit of work. This still allows previously cached objects to be accessed in the unit of work after an early transaction, but ensures uncommitted data will never be put in the session cache by storing any object built from new data only in the unit of work. ISOLATE_CACHE_AFTER_TRANSACTION - After a unit of work early transaction the session cache is no longer used for this class. Objects will be directly built from the database data and only stored in the unit of work, even if previously cached. Note that this may lead to poor performance as the session cache is bypassed after an early transaction. ISOLATE_CACHE_ALWAYS - Default (when using isolated cache): The session cache will never be used for this class. Objects will be directly built from the database data and only stored in the unit of work. New objects and changes will also never be merged into the session cache. Note that this may lead to poor performance as the session cache is bypassed, however if this class is isolated or pessimistic locked and always accessed in a transaction, this can avoid having to build two copies of the object.
-
setHasRelationships
public void setHasRelationships(boolean hasRelationships)
INTERNAL: set whether this descriptor has any relationships through its mappings, through inheritance, or through aggregates- Parameters:
hasRelationships-
-
setJavaClass
public void setJavaClass(java.lang.Class theJavaClass)
PUBLIC: Set the Java class that this descriptor maps. Every descriptor maps one and only one class.- Specified by:
setJavaClassin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
setJavaClassName
public void setJavaClassName(java.lang.String theJavaClassName)
INTERNAL: Return the java class name, used by the MW.
-
setJavaInterface
public void setJavaInterface(java.lang.Class theJavaInterface)
PUBLIC: Sets the descriptor to be for an interface. An interface descriptor allows for other classes to reference an interface or one of several other classes. The implementor classes can be completely unrelated in term of the database stored in distinct tables. Queries can also be done for the interface which will query each of the implementor classes. An interface descriptor cannot define any mappings as an interface is just API and not state, a interface descriptor should define the common query key of its implementors to allow querying. An interface descriptor also does not define a primary key or table or other settings. If an interface only has a single implementor (i.e. a classes public interface or remote) then an interface descriptor should not be defined for it and relationships should be to the implementor class not the interface, in this case the implementor class can add the interface through its interface policy to map queries on the interface to it.
-
setJavaInterfaceName
public void setJavaInterfaceName(java.lang.String theJavaInterfaceName)
INTERNAL: Return the java interface name, used by the MW.
-
setLockableMappings
public void setLockableMappings(java.util.List<DatabaseMapping> lockableMappings)
INTERNAL: Set the list of lockable mappings for this project This method is provided for CMP use. Normally, the lockable mappings are initialized at descriptor initialization time.
-
setMappings
public void setMappings(java.util.Vector<DatabaseMapping> mappings)
INTERNAL: Set the mappings.
-
setMultipleTableForeignKeys
protected void setMultipleTableForeignKeys(java.util.Map<org.eclipse.persistence.internal.helper.DatabaseTable,java.util.Set<org.eclipse.persistence.internal.helper.DatabaseTable>> newValue)
INTERNAL:- See Also:
getMultipleTableForeignKeys()
-
setMultipleTableInsertOrder
public void setMultipleTableInsertOrder(java.util.List<org.eclipse.persistence.internal.helper.DatabaseTable> newValue)
ADVANCED: Sets the List of DatabaseTables in the order which INSERTS should take place. This is normally computed correctly by , however in advanced cases in it may be overridden.
-
setMultitenantPolicy
public void setMultitenantPolicy(MultitenantPolicy multitenantPolicy)
INTERNAL: Set a multitenant policy on the descriptor.
-
isCascadeOnDeleteSetOnDatabaseOnSecondaryTables
public boolean isCascadeOnDeleteSetOnDatabaseOnSecondaryTables()
ADVANCED: Return if delete cascading has been set on the database for the descriptor's multiple tables.
-
setIsCascadeOnDeleteSetOnDatabaseOnSecondaryTables
public void setIsCascadeOnDeleteSetOnDatabaseOnSecondaryTables(boolean isCascadeOnDeleteSetOnDatabaseOnSecondaryTables)
ADVANCED: Set if delete cascading has been set on the database for the descriptor's multiple tables. This will avoid the delete SQL being generated for those tables.
-
setObjectBuilder
protected void setObjectBuilder(org.eclipse.persistence.internal.descriptors.ObjectBuilder builder)
INTERNAL: Set the ObjectBuilder.- Specified by:
setObjectBuilderin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
setOptimisticLockingPolicy
public void setOptimisticLockingPolicy(org.eclipse.persistence.internal.descriptors.OptimisticLockingPolicy optimisticLockingPolicy)
PUBLIC: Set the OptimisticLockingPolicy. This can be one of the provided locking policies or a user defined policy.
-
setPrimaryKeyFieldName
public void setPrimaryKeyFieldName(java.lang.String fieldName)
PUBLIC: Specify the primary key field of the descriptors table. This should only be called if it is a singlton primary key field, otherwise addPrimaryKeyFieldName should be called. If the descriptor has many tables, this must be the primary key in all of the tables.- See Also:
addPrimaryKeyFieldName(String)
-
setPrimaryKeyFieldNames
public void setPrimaryKeyFieldNames(java.util.Vector primaryKeyFieldsName)
PUBLIC: User can specify a vector of all the primary key field names if primary key is composite.- Specified by:
setPrimaryKeyFieldNamesin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>- See Also:
addPrimaryKeyFieldName(String)
-
setPrimaryKeyFields
public void setPrimaryKeyFields(java.util.List<org.eclipse.persistence.internal.helper.DatabaseField> thePrimaryKeyFields)
INTERNAL: Set the primary key fields- Specified by:
setPrimaryKeyFieldsin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>- See Also:
addPrimaryKeyFieldName(String)
-
setProperties
public void setProperties(java.util.Map properties)
INTERNAL: Set the user defined properties.
-
setProperty
public void setProperty(java.lang.String name, java.lang.Object value)PUBLIC: Set the user defined property.
-
setQueryKeys
public void setQueryKeys(java.util.Map<java.lang.String,QueryKey> queryKeys)
INTERNAL: Set the query keys.
-
setQueryManager
public void setQueryManager(DescriptorQueryManager queryManager)
INTERNAL: Set the query manager.
-
setRemoteIdentityMapClass
public void setRemoteIdentityMapClass(java.lang.Class theIdentityMapClass)
PUBLIC: Set the class of identity map to be used by this descriptor. The default is the "FullIdentityMap".
-
setRemoteIdentityMapSize
public void setRemoteIdentityMapSize(int identityMapSize)
PUBLIC: Set the size of the identity map to be used by this descriptor. The default is the 100.
-
setSequenceNumberField
public void setSequenceNumberField(org.eclipse.persistence.internal.helper.DatabaseField sequenceNumberField)
INTERNAL: Set the sequence number field.
-
setSequenceNumberFieldName
public void setSequenceNumberFieldName(java.lang.String fieldName)
PUBLIC: Set the sequence number field name. This is the field in the descriptors table that needs its value to be generated. This is normally the primary key field of the descriptor.
-
setSequenceNumberName
public void setSequenceNumberName(java.lang.String name)
PUBLIC: Set the sequence number name. This is the seq_name part of the row stored in the sequence table for this descriptor. If using Oracle native sequencing this is the name of the Oracle sequence object. If using Sybase native sequencing this name has no meaning, but should still be set for compatibility. The name does not have to be unique among descriptors, as having descriptors share sequences can improve pre-allocation performance.
-
setSessionName
protected void setSessionName(java.lang.String sessionName)
INTERNAL: Set the name of the session local to this descriptor. This is used by the session broker.
-
setShouldAlwaysConformResultsInUnitOfWork
public void setShouldAlwaysConformResultsInUnitOfWork(boolean shouldAlwaysConformResultsInUnitOfWork)
PUBLIC: set if the descriptor is defined to always conform the results in unit of work in read query.
-
setShouldAlwaysRefreshCache
public void setShouldAlwaysRefreshCache(boolean shouldAlwaysRefreshCache)
PUBLIC: When theshouldAlwaysRefreshCacheargument passed into this method istrue, this method configures aClassDescriptorto always refresh the cache if data is received from the database by any query.However, if a query hits the cache, data is not refreshed regardless of how this setting is configured. For example, by default, when a query for a single object based on its primary key is executed, OracleAS TopLink will first look in the cache for the object. If the object is in the cache, the cached object is returned and data is not refreshed. To avoid cache hits, use the
disableCacheHits()method.Also note that the
UnitOfWorkwill not refresh its registered objects.Use this property with caution because it can lead to poor performance and may refresh on queries when it is not desired. Normally, if you require fresh data, it is better to configure a query with
ObjectLevelReadQuery.refreshIdentityMapResult(). To ensure that refreshes are only done when required, use this method in conjunction withonlyRefreshCacheIfNewerVersion().When the
shouldAlwaysRefreshCacheargument passed into this method isfalse, this method ensures that aClassDescriptoris not configured to always refresh the cache if data is received from the database by any query.- See Also:
alwaysRefreshCache(),dontAlwaysRefreshCache()
-
setShouldAlwaysRefreshCacheOnRemote
public void setShouldAlwaysRefreshCacheOnRemote(boolean shouldAlwaysRefreshCacheOnRemote)
PUBLIC: When theshouldAlwaysRefreshCacheOnRemoteargument passed into this method istrue, this method configures aClassDescriptorto always remotely refresh the cache if data is received from the database by any query in aRemoteSession. However, if a query hits the cache, data is not refreshed regardless of how this setting is configured. For example, by default, when a query for a single object based on its primary key is executed, OracleAS TopLink will first look in the cache for the object. If the object is in the cache, the cached object is returned and data is not refreshed. To avoid cache hits, use thedisableCacheHitsOnRemote()method.Also note that the
UnitOfWorkwill not refresh its registered objects.Use this property with caution because it can lead to poor performance and may refresh on queries when it is not desired. Normally, if you require fresh data, it is better to configure a query with
ObjectLevelReadQuery.refreshIdentityMapResult(). To ensure that refreshes are only done when required, use this method in conjunction withonlyRefreshCacheIfNewerVersion().When the
shouldAlwaysRefreshCacheOnRemoteargument passed into this method isfalse, this method ensures that aClassDescriptoris not configured to always remotely refresh the cache if data is received from the database by any query in aRemoteSession.
-
setShouldBeReadOnly
public void setShouldBeReadOnly(boolean shouldBeReadOnly)
PUBLIC: Define if the descriptor reference class is read-only
-
setReadOnly
public void setReadOnly()
PUBLIC: Set the descriptor to be read-only. Declaring a descriptor is read-only means that instances of the reference class will never be modified. Read-only descriptor is usually used in the unit of work to gain performance as there is no need for the registration, clone and merge for the read-only classes.
-
setShouldDisableCacheHits
public void setShouldDisableCacheHits(boolean shouldDisableCacheHits)
PUBLIC: Set if cache hits on primary key read object queries should be disabled.- See Also:
alwaysRefreshCache()
-
setShouldDisableCacheHitsOnRemote
public void setShouldDisableCacheHitsOnRemote(boolean shouldDisableCacheHitsOnRemote)
PUBLIC: Set if the remote session cache hits on primary key read object queries is allowed or not.- See Also:
disableCacheHitsOnRemote()
-
setShouldLockForClone
public void setShouldLockForClone(boolean shouldLockForClone)
ADVANCED: When set to false, this setting will allow the UOW to avoid locking the shared cache instance in order to perform a clone. Caution should be taken as setting this to false may allow cloning of partial updates
-
setShouldOnlyRefreshCacheIfNewerVersion
public void setShouldOnlyRefreshCacheIfNewerVersion(boolean shouldOnlyRefreshCacheIfNewerVersion)
PUBLIC: When theshouldOnlyRefreshCacheIfNewerVersionargument passed into this method istrue, this method configures aClassDescriptorto only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field) and as long as one of the following is true:- the
ClassDescriptorwas configured by callingalwaysRefreshCache()oralwaysRefreshCacheOnRemote(), - the query was configured by calling
ObjectLevelReadQuery.refreshIdentityMapResult(), or - the query was a call to
Session.refreshObject(java.lang.Object)
However, if a query hits the cache, data is not refreshed regardless of how this setting is configured. For example, by default, when a query for a single object based on its primary key is executed, OracleAS TopLink will first look in the cache for the object. If the object is in the cache, the cached object is returned and data is not refreshed. To avoid cache hits, use the
disableCacheHits()method.Also note that the
UnitOfWorkwill not refresh its registered objects.When the
shouldOnlyRefreshCacheIfNewerVersionargument passed into this method isfalse, this method ensures that aClassDescriptoris not configured to only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field). - the
-
setShouldOrderMappings
public void setShouldOrderMappings(boolean shouldOrderMappings)
PUBLIC: This is set to turn off the ordering of mappings. By Default this is set to true. By ordering the mappings insures that object are merged in the right order. If the order of the mappings needs to be specified by the developer then set this to false and will use the order that the mappings were added to the descriptor
-
setShouldRegisterResultsInUnitOfWork
public void setShouldRegisterResultsInUnitOfWork(boolean shouldRegisterResultsInUnitOfWork)
INTERNAL: Set to false to have queries conform to a UnitOfWork without registering any additional objects not already in that UnitOfWork.- See Also:
shouldRegisterResultsInUnitOfWork- Related Bugs:
- 2612601
-
setTableName
public void setTableName(java.lang.String tableName) throws DescriptorExceptionPUBLIC: Specify the table name for the class of objects the receiver describes. If the table has a qualifier it should be specified using the dot notation, (i.e. "userid.employee"). This method is used for single table.- Throws:
DescriptorException
-
setTableNames
public void setTableNames(java.util.Vector tableNames)
PUBLIC: Specify the all table names for the class of objects the receiver describes. If the table has a qualifier it should be specified using the dot notation, (i.e. "userid.employee"). This method is used for multiple tables
-
setTablePerClassPolicy
public void setTablePerClassPolicy(TablePerClassPolicy tablePerClassPolicy)
INTERNAL: Sets the table per class policy.
-
setTableQualifier
public void setTableQualifier(java.lang.String tableQualifier)
PUBLIC: Set the table Qualifier for this descriptor. This table creator will be used for all tables in this descriptor
-
setTables
public void setTables(java.util.Vector<org.eclipse.persistence.internal.helper.DatabaseTable> theTables)
INTERNAL: Sets the tables
-
setWrapperPolicy
public void setWrapperPolicy(WrapperPolicy wrapperPolicy)
ADVANCED: Sets the WrapperPolicy for this descriptor. This advanced feature can be used to wrap objects with other classes such as CORBA TIE objects or EJBs.
-
shouldAlwaysConformResultsInUnitOfWork
public boolean shouldAlwaysConformResultsInUnitOfWork()
PUBLIC: Return if the descriptor is defined to always conform the results in unit of work in read query.
-
shouldAlwaysRefreshCache
public boolean shouldAlwaysRefreshCache()
PUBLIC: This method returnstrueif theClassDescriptoris configured to always refresh the cache if data is received from the database by any query. Otherwise, it returnsfalse.- See Also:
setShouldAlwaysRefreshCache(boolean)
-
shouldAlwaysRefreshCacheOnRemote
public boolean shouldAlwaysRefreshCacheOnRemote()
PUBLIC: This method returnstrueif theClassDescriptoris configured to always remotely refresh the cache if data is received from the database by any query in aRemoteSession. Otherwise, it returnsfalse.
-
shouldBeReadOnly
public boolean shouldBeReadOnly()
PUBLIC: Return if the descriptor reference class is defined as read-only
-
shouldDisableCacheHits
public boolean shouldDisableCacheHits()
PUBLIC: Return if for cache hits on primary key read object queries to be disabled.- See Also:
disableCacheHits()
-
shouldDisableCacheHitsOnRemote
public boolean shouldDisableCacheHitsOnRemote()
PUBLIC: Return if the remote server session cache hits on primary key read object queries is aloowed or not.- See Also:
disableCacheHitsOnRemote()
-
shouldOnlyRefreshCacheIfNewerVersion
public boolean shouldOnlyRefreshCacheIfNewerVersion()
PUBLIC: This method returnstrueif theClassDescriptoris configured to only refresh the cache if the data received from the database by a query is newer than the data in the cache (as determined by the optimistic locking field). Otherwise, it returnsfalse.
-
shouldOrderMappings
public boolean shouldOrderMappings()
INTERNAL: Return if mappings should be ordered or not. By default this is set to true to prevent attributes from being merged in the wrong order
-
hasSimplePrimaryKey
public boolean hasSimplePrimaryKey()
INTERNAL: PERF: Return if the primary key is simple (direct-mapped) to allow fast extraction.
-
hasTablePerClassPolicy
public boolean hasTablePerClassPolicy()
INTERNAL: Return if this descriptor is involved in a table per class inheritance.
-
setHasSimplePrimaryKey
public void setHasSimplePrimaryKey(boolean hasSimplePrimaryKey)
INTERNAL: PERF: Set if the primary key is simple (direct-mapped) to allow fast extraction.
-
shouldAcquireCascadedLocks
public boolean shouldAcquireCascadedLocks()
INTERNAL: PERF: Return if deferred locks should be used. Used to optimize read locking. This is determined based on if any relationships do not use indirection.
-
setShouldAcquireCascadedLocks
public void setShouldAcquireCascadedLocks(boolean shouldAcquireCascadedLocks)
INTERNAL: PERF: Set if deferred locks should be used. This is determined based on if any relationships do not use indirection, but this provides a backdoor hook to force on if require because of events usage etc.
-
shouldUseAdditionalJoinExpression
public boolean shouldUseAdditionalJoinExpression()
PUBLIC: Return true if this descriptor should using an additional join expresison.
-
shouldUseCacheIdentityMap
public boolean shouldUseCacheIdentityMap()
PUBLIC: Return true if this descriptor is using CacheIdentityMap
-
shouldUseFullIdentityMap
public boolean shouldUseFullIdentityMap()
PUBLIC: Return true if this descriptor is using FullIdentityMap
-
shouldUseSoftIdentityMap
public boolean shouldUseSoftIdentityMap()
PUBLIC: Return true if this descriptor is using SoftIdentityMap
-
shouldUseRemoteSoftIdentityMap
public boolean shouldUseRemoteSoftIdentityMap()
PUBLIC: Return true if this descriptor is using SoftIdentityMap
-
shouldUseHardCacheWeakIdentityMap
public boolean shouldUseHardCacheWeakIdentityMap()
PUBLIC: Return true if this descriptor is using HardCacheWeakIdentityMap.
-
shouldUseNoIdentityMap
public boolean shouldUseNoIdentityMap()
PUBLIC: Return true if this descriptor is using NoIdentityMap
-
shouldRegisterResultsInUnitOfWork
public boolean shouldRegisterResultsInUnitOfWork()
INTERNAL: Allows one to do conforming in a UnitOfWork without registering. Queries executed on a UnitOfWork will only return working copies for objects that have already been registered.Extreme care should be taken in using this feature, for a user will get back a mix of registered and original (unregistered) objects.
Best used with a WrapperPolicy where invoking on an object will trigger its registration (CMP). Without a WrapperPolicy
registerExistingObjectshould be called on any object that you intend to change.- Returns:
- true by default.
- See Also:
setShouldRegisterResultsInUnitOfWork(boolean),ObjectBuildingQuery.shouldRegisterResultsInUnitOfWork- Related Bugs:
- 2612601
-
shouldUseRemoteCacheIdentityMap
public boolean shouldUseRemoteCacheIdentityMap()
PUBLIC: Return true if this descriptor is using CacheIdentityMap
-
shouldUseRemoteFullIdentityMap
public boolean shouldUseRemoteFullIdentityMap()
PUBLIC: Return true if this descriptor is using FullIdentityMap
-
shouldUseRemoteHardCacheWeakIdentityMap
public boolean shouldUseRemoteHardCacheWeakIdentityMap()
PUBLIC: Return true if this descriptor is using HardCacheWeakIdentityMap
-
shouldUseRemoteNoIdentityMap
public boolean shouldUseRemoteNoIdentityMap()
PUBLIC: Return true if this descriptor is using NoIdentityMap
-
shouldUseRemoteSoftCacheWeakIdentityMap
public boolean shouldUseRemoteSoftCacheWeakIdentityMap()
PUBLIC: Return true if this descriptor is using SoftCacheWeakIdentityMap
-
shouldUseRemoteWeakIdentityMap
public boolean shouldUseRemoteWeakIdentityMap()
PUBLIC: Return true if this descriptor is using WeakIdentityMap
-
shouldUseSoftCacheWeakIdentityMap
public boolean shouldUseSoftCacheWeakIdentityMap()
PUBLIC: Return true if this descriptor is using SoftCacheWeakIdentityMap.
-
shouldUseWeakIdentityMap
public boolean shouldUseWeakIdentityMap()
PUBLIC: Return true if this descriptor is using WeakIdentityMap
-
supportsChangeTracking
public boolean supportsChangeTracking(Project project)
INTERNAL: Returns whether this descriptor is capable of supporting weaved change tracking. This method is used before the project is initialized.
-
toString
public java.lang.String toString()
PUBLIC: Returns a brief string representation of the receiver.- Overrides:
toStringin classjava.lang.Object
-
useAllFieldsLocking
public void useAllFieldsLocking()
PUBLIC: Set the locking policy an all fields locking policy. A field locking policy is base on locking on all fields by comparing with their previous values to detect field-level collisions. Note: the unit of work must be used for all updates when using field locking.- See Also:
AllFieldsLockingPolicy
-
useCacheIdentityMap
public void useCacheIdentityMap()
PUBLIC: Set the class of identity map to be the cache identity map. This map caches the LRU instances read from the database. Note: This map does not guarantee object identity. The default is the "SoftCacheWeakIdentityMap".
-
useChangedFieldsLocking
public void useChangedFieldsLocking()
PUBLIC: Set the locking policy a changed fields locking policy. A field locking policy is base on locking on all changed fields by comparing with their previous values to detect field-level collisions. Note: the unit of work must be used for all updates when using field locking.- See Also:
ChangedFieldsLockingPolicy
-
useCloneCopyPolicy
public void useCloneCopyPolicy()
PUBLIC: Specifies that the creation of clones within a unit of work is done by sending the #clone() method to the original object. The #clone() method must return a logical shallow copy of the original object. This can be used if the default mechanism of creating a new instance does not handle the object's non-persistent attributes correctly.- See Also:
useCloneCopyPolicy(String)
-
useCloneCopyPolicy
public void useCloneCopyPolicy(java.lang.String cloneMethodName)
PUBLIC: Specifies that the creation of clones within a unit of work is done by sending the cloneMethodName method to the original object. This method must return a logical shallow copy of the original object. This can be used if the default mechanism of creating a new instance does not handle the object's non-persistent attributes correctly.- See Also:
useCloneCopyPolicy()
-
useInstantiationCopyPolicy
public void useInstantiationCopyPolicy()
PUBLIC: Specifies that the creation of clones within a unit of work is done by building a new instance using the technique indicated by the descriptor's instantiation policy (which by default is to use the the default constructor). This new instance is then populated by using the descriptor's mappings to copy attributes from the original to the clone. This is the default. If another mechanism is desired the copy policy allows for a clone method to be called.
-
useDefaultConstructorInstantiationPolicy
public void useDefaultConstructorInstantiationPolicy()
PUBLIC: Use the default constructor to create new instances of objects built from the database. This is the default. The descriptor's class must either define a default constructor or define no constructors at all.
-
useFactoryInstantiationPolicy
public void useFactoryInstantiationPolicy(java.lang.Class factoryClass, java.lang.String methodName)PUBLIC: Use an object factory to create new instances of objects built from the database. The methodName is the name of the method that will be invoked on the factory. When invoked, it must return a new instance of the descriptor's class. The factory will be created by invoking the factoryClass's default constructor.
-
useFactoryInstantiationPolicy
public void useFactoryInstantiationPolicy(java.lang.String factoryClassName, java.lang.String methodName)INTERNAL: Set the factory class name, used by the MW.
-
useFactoryInstantiationPolicy
public void useFactoryInstantiationPolicy(java.lang.Class factoryClass, java.lang.String methodName, java.lang.String factoryMethodName)PUBLIC: Use an object factory to create new instances of objects built from the database. The factoryMethodName is a static method declared by the factoryClass. When invoked, it must return an instance of the factory. The methodName is the name of the method that will be invoked on the factory. When invoked, it must return a new instance of the descriptor's class.
-
useFactoryInstantiationPolicy
public void useFactoryInstantiationPolicy(java.lang.String factoryClassName, java.lang.String methodName, java.lang.String factoryMethodName)INTERNAL: Set the factory class name, used by the MW.
-
useFactoryInstantiationPolicy
public void useFactoryInstantiationPolicy(java.lang.Object factory, java.lang.String methodName)PUBLIC: Use an object factory to create new instances of objects built from the database. The methodName is the name of the method that will be invoked on the factory. When invoked, it must return a new instance of the descriptor's class.
-
useFullIdentityMap
public void useFullIdentityMap()
PUBLIC: Set the class of identity map to be the full identity map. This map caches all instances read and grows to accomodate them. The default is the "SoftCacheWeakIdentityMap".
-
useHardCacheWeakIdentityMap
public void useHardCacheWeakIdentityMap()
PUBLIC: Set the class of identity map to be the hard cache weak identity map. This map uses weak references to only cache object in-memory. It also includes a secondary fixed sized hard cache to improve caching performance. This is provided because some Java VM's implement soft references differently. The default is the "SoftCacheWeakIdentityMap".
-
useSoftIdentityMap
public void useSoftIdentityMap()
PUBLIC: Set the class of identity map to be the soft identity map. This map uses soft references to only cache all object in-memory, until memory is low. Note that "low" is interpreted differently by different JVM's. The default is the "SoftCacheWeakIdentityMap".
-
useRemoteSoftIdentityMap
public void useRemoteSoftIdentityMap()
PUBLIC: Set the class of identity map to be the soft identity map. This map uses soft references to only cache all object in-memory, until memory is low. Note that "low" is interpreted differently by different JVM's. The default is the "SoftCacheWeakIdentityMap".
-
useMethodInstantiationPolicy
public void useMethodInstantiationPolicy(java.lang.String staticMethodName)
PUBLIC: Use the specified static method to create new instances of objects built from the database. This method must be statically declared by the descriptor's class, and it must return a new instance of the descriptor's class.
-
useNoIdentityMap
public void useNoIdentityMap()
PUBLIC: Set the class of identity map to be the no identity map. This map does no caching. Note: This map does not maintain object identity. In general if caching is not desired a WeakIdentityMap should be used with an isolated descriptor. The default is the "SoftCacheWeakIdentityMap".- See Also:
setIsIsolated(boolean)
-
useRemoteCacheIdentityMap
public void useRemoteCacheIdentityMap()
PUBLIC: Set the class of identity map to be the cache identity map. This map caches the LRU instances read from the database. The default is the "SoftCacheWeakIdentityMap".
-
useRemoteFullIdentityMap
public void useRemoteFullIdentityMap()
PUBLIC: Set the class of identity map to be the full identity map. This map caches all instances read and grows to accomodate them. The default is the "SoftCacheWeakIdentityMap".
-
useRemoteHardCacheWeakIdentityMap
public void useRemoteHardCacheWeakIdentityMap()
PUBLIC: Set the class of identity map to be the hard cache weak identity map. This map uses weak references to only cache object in-memory. It also includes a secondary fixed sized soft cache to improve caching performance. This is provided because some Java VM's do not implement soft references correctly. The default is the "SoftCacheWeakIdentityMap".
-
useRemoteNoIdentityMap
public void useRemoteNoIdentityMap()
PUBLIC: Set the class of identity map to be the no identity map. This map does no caching. The default is the "SoftCacheWeakIdentityMap".
-
useRemoteSoftCacheWeakIdentityMap
public void useRemoteSoftCacheWeakIdentityMap()
PUBLIC: Set the class of identity map to be the soft cache weak identity map. The SoftCacheIdentityMap holds a fixed number of objects is memory (using SoftReferences) to improve caching. The default is the "SoftCacheWeakIdentityMap".
-
useRemoteWeakIdentityMap
public void useRemoteWeakIdentityMap()
PUBLIC: Set the class of identity map to be the weak identity map. The default is the "SoftCacheWeakIdentityMap".
-
useSelectedFieldsLocking
public void useSelectedFieldsLocking(java.util.Vector fieldNames)
PUBLIC: Set the locking policy a selected fields locking policy. A field locking policy is base on locking on the specified fields by comparing with their previous values to detect field-level collisions. Note: the unit of work must be used for all updates when using field locking.- See Also:
SelectedFieldsLockingPolicy
-
usesFieldLocking
public boolean usesFieldLocking()
INTERNAL: Return true if the receiver uses either all or changed fields for optimistic locking.
-
useSoftCacheWeakIdentityMap
public void useSoftCacheWeakIdentityMap()
PUBLIC: Set the class of identity map to be the soft cache weak identity map. The SoftCacheIdentityMap holds a fixed number of objects is memory (using SoftReferences) to improve caching. The default is the "SoftCacheWeakIdentityMap".
-
usesOptimisticLocking
public boolean usesOptimisticLocking()
PUBLIC: Return true if the receiver uses write (optimistic) locking.
-
usesVersionLocking
public boolean usesVersionLocking()
PUBLIC: Return true if the receiver uses version optimistic locking.
-
usesSequenceNumbers
public boolean usesSequenceNumbers()
PUBLIC: Return true if the receiver uses sequence numbers.
-
useTimestampLocking
public void useTimestampLocking(java.lang.String writeLockFieldName)
PUBLIC: Use the Timestamps locking policy and storing the value in the cache key #see useVersionLocking(String)
-
useTimestampLocking
public void useTimestampLocking(java.lang.String writeLockFieldName, boolean shouldStoreInCache)PUBLIC: Set the locking policy to use timestamp version locking. This updates the timestamp field on all updates, first comparing that the field has not changed to detect locking conflicts. Note: many database have limited precision of timestamps which can be an issue is highly concurrent systems. The parameter 'shouldStoreInCache' configures the version lock value to be stored in the cache or in the object. Note: if using a stateless model where the object can be passed to a client and then later updated in a different transaction context, then the version lock value should not be stored in the cache, but in the object to ensure it is the correct value for that object.- See Also:
VersionLockingPolicy
-
useVersionLocking
public void useVersionLocking(java.lang.String writeLockFieldName)
PUBLIC: Default to use the version locking policy and storing the value in the cache key #see useVersionLocking(String)
-
useVersionLocking
public void useVersionLocking(java.lang.String writeLockFieldName, boolean shouldStoreInCache)PUBLIC: Set the locking policy to use numeric version locking. This updates the version field on all updates, first comparing that the field has not changed to detect locking conflicts. The parameter 'shouldStoreInCache' configures the version lock value to be stored in the cache or in the object. Note: if using a stateless model where the object can be passed to a client and then later updated in a different transaction context, then the version lock value should not be stored in the cache, but in the object to ensure it is the correct value for that object.- See Also:
TimestampLockingPolicy
-
useWeakIdentityMap
public void useWeakIdentityMap()
PUBLIC: Set the class of identity map to be the weak identity map. The default is the "SoftCacheWeakIdentityMap".
-
validateAfterInitialization
protected void validateAfterInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Validate the entire post-initialization descriptor.
-
validateBeforeInitialization
protected void validateBeforeInitialization(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Validate the entire pre-initialization descriptor.
-
verifyTableQualifiers
protected void verifyTableQualifiers(org.eclipse.persistence.internal.databaseaccess.Platform platform)
INTERNAL: Check that the qualifier on the table names are properly set.
-
getCMPPolicy
public CMPPolicy getCMPPolicy()
ADVANCED: Return the cmp descriptor that holds cmp specific information. A null return will mean that the descriptor does not represent an Entity, however it may still represent a MappedSuperclass. It will be null if it is not being used.
-
setCMPPolicy
public void setCMPPolicy(CMPPolicy newCMPPolicy)
ADVANCED: Set the cmp descriptor that holds cmp specific information.
-
getCachePolicy
public CachePolicy getCachePolicy()
Return the cache policy. The cache policy allows for the configuration of caching options.
-
setCachePolicy
public void setCachePolicy(CachePolicy cachePolicy)
ADVANCED: Set cache policy for the descriptor.
-
hasPessimisticLockingPolicy
public boolean hasPessimisticLockingPolicy()
INTERNAL:
-
getFetchGroupManager
public FetchGroupManager getFetchGroupManager()
PUBLIC: Get the fetch group manager for the descriptor. The fetch group manager is responsible for managing the fetch group behaviors and operations. To use the fetch group, the domain object must implement FetchGroupTracker interface. Otherwise, a descriptor validation exception would throw during initialization.- See Also:
FetchGroupTracker
-
getFullyMergeEntity
public boolean getFullyMergeEntity()
- Returns:
- the fullyMergeEntity
-
setFetchGroupManager
public void setFetchGroupManager(FetchGroupManager fetchGroupManager)
PUBLIC: Set the fetch group manager for the descriptor. The fetch group manager is responsible for managing the fetch group behaviors and operations.
-
hasFetchGroupManager
public boolean hasFetchGroupManager()
INTERNAL: Return if the descriptor has a fetch group manager associated with.
-
hasCascadeLockingPolicies
public boolean hasCascadeLockingPolicies()
INTERNAL:
-
hasCMPPolicy
public boolean hasCMPPolicy()
INTERNAL: Return if the descriptor has a CMP policy.
-
getDefaultFetchGroup
public FetchGroup getDefaultFetchGroup()
INTERNAL: Return the default fetch group on the descriptor. All read object and read all queries will use the default fetch group if no fetch group is explicitly defined for the query.
-
isReturnTypeRequiredForReturningPolicy
public boolean isReturnTypeRequiredForReturningPolicy()
INTERNAL: Indicates if a return type is required for the field set on the returning policy. For relational descriptors, this should always return true.
-
setIsNativeConnectionRequired
public void setIsNativeConnectionRequired(boolean isNativeConnectionRequired)
ADVANCED: Set if the descriptor requires usage of a native (unwrapped) JDBC connection. This may be required for some Oracle JDBC support when a wrapping DataSource is used.
-
isNativeConnectionRequired
public boolean isNativeConnectionRequired()
ADVANCED: Return if the descriptor requires usage of a native (unwrapped) JDBC connection. This may be required for some Oracle JDBC support when a wrapping DataSource is used.
-
setIdValidation
public void setIdValidation(IdValidation idValidation)
ADVANCED: Set what types are allowed as a primary key (id).
-
getIdValidation
public IdValidation getIdValidation()
ADVANCED: Return what types are allowed as a primary key (id).
-
getPrimaryKeyIdValidations
public java.util.List<IdValidation> getPrimaryKeyIdValidations()
ADVANCED: Return what types are allowed in each primary key field (id).
-
setPrimaryKeyIdValidations
public void setPrimaryKeyIdValidations(java.util.List<IdValidation> primaryKeyIdValidations)
ADVANCED: Return what types are allowed in each primary key field (id).
-
setCacheKeyType
public void setCacheKeyType(CacheKeyType cacheKeyType)
ADVANCED: Set what cache key type to use to store the object in the cache.
-
getCacheKeyType
public CacheKeyType getCacheKeyType()
ADVANCED: Return what cache key type to use to store the object in the cache.
-
getDefaultQueryRedirector
public QueryRedirector getDefaultQueryRedirector()
A Default Query Redirector will be applied to any executing object query that does not have a more precise default (like the default ReadObjectQuery Redirector) or a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultQueryRedirector
public void setDefaultQueryRedirector(QueryRedirector defaultRedirector)
A Default Query Redirector will be applied to any executing object query that does not have a more precise default (like the default ReadObjectQuery Redirector) or a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
getDefaultReadAllQueryRedirector
public QueryRedirector getDefaultReadAllQueryRedirector()
A Default ReadAllQuery Redirector will be applied to any executing ReadAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultReadAllQueryRedirector
public void setDefaultReadAllQueryRedirector(QueryRedirector defaultReadAllQueryRedirector)
A Default ReadAllQuery Redirector will be applied to any executing ReadAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
getDefaultReadObjectQueryRedirector
public QueryRedirector getDefaultReadObjectQueryRedirector()
A Default ReadObjectQuery Redirector will be applied to any executing ReadObjectQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultReadObjectQueryRedirector
public void setDefaultReadObjectQueryRedirector(QueryRedirector defaultReadObjectQueryRedirector)
A Default ReadObjectQuery Redirector will be applied to any executing ReadObjectQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
getDefaultReportQueryRedirector
public QueryRedirector getDefaultReportQueryRedirector()
A Default ReportQuery Redirector will be applied to any executing ReportQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultReportQueryRedirector
public void setDefaultReportQueryRedirector(QueryRedirector defaultReportQueryRedirector)
A Default ReportQuery Redirector will be applied to any executing ReportQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
getDefaultUpdateObjectQueryRedirector
public QueryRedirector getDefaultUpdateObjectQueryRedirector()
A Default UpdateObjectQuery Redirector will be applied to any executing UpdateObjectQuery or UpdateAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultUpdateObjectQueryRedirector
public void setDefaultUpdateObjectQueryRedirector(QueryRedirector defaultUpdateQueryRedirector)
A Default UpdateObjectQuery Redirector will be applied to any executing UpdateObjectQuery or UpdateAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
getDefaultInsertObjectQueryRedirector
public QueryRedirector getDefaultInsertObjectQueryRedirector()
A Default InsertObjectQuery Redirector will be applied to any executing InsertObjectQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultInsertObjectQueryRedirector
public void setDefaultInsertObjectQueryRedirector(QueryRedirector defaultInsertQueryRedirector)
A Default InsertObjectQuery Redirector will be applied to any executing InsertObjectQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
getDefaultDeleteObjectQueryRedirector
public QueryRedirector getDefaultDeleteObjectQueryRedirector()
A Default DeleteObjectQuery Redirector will be applied to any executing DeleteObjectQuery or DeleteAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultDeleteObjectQueryRedirector
public void setDefaultDeleteObjectQueryRedirector(QueryRedirector defaultDeleteObjectQueryRedirector)
A Default DeleteObjectQuery Redirector will be applied to any executing DeleteObjectQuery or DeleteAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultQueryRedirectorClassName
public void setDefaultQueryRedirectorClassName(java.lang.String defaultQueryRedirectorClassName)
A Default Query Redirector will be applied to any executing object query that does not have a more precise default (like the default ReadObjectQuery Redirector) or a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultReadAllQueryRedirectorClassName
public void setDefaultReadAllQueryRedirectorClassName(java.lang.String defaultReadAllQueryRedirectorClassName)
A Default ReadAllQuery Redirector will be applied to any executing ReadAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query exection preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultReadObjectQueryRedirectorClassName
public void setDefaultReadObjectQueryRedirectorClassName(java.lang.String defaultReadObjectQueryRedirectorClassName)
A Default ReadObjectQuery Redirector will be applied to any executing ReadObjectQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultReportQueryRedirectorClassName
public void setDefaultReportQueryRedirectorClassName(java.lang.String defaultReportQueryRedirectorClassName)
A Default ReportQuery Redirector will be applied to any executing ReportQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultUpdateObjectQueryRedirectorClassName
public void setDefaultUpdateObjectQueryRedirectorClassName(java.lang.String defaultUpdateObjectQueryRedirectorClassName)
A Default UpdateObjectQuery Redirector will be applied to any executing UpdateObjectQuery or UpdateAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query execution preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultInsertObjectQueryRedirectorClassName
public void setDefaultInsertObjectQueryRedirectorClassName(java.lang.String defaultInsertObjectQueryRedirectorClassName)
A Default InsertObjectQuery Redirector will be applied to any executing InsertObjectQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query exection preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
setDefaultDeleteObjectQueryRedirectorClassName
public void setDefaultDeleteObjectQueryRedirectorClassName(java.lang.String defaultDeleteObjectQueryRedirectorClassName)
A Default DeleteObjectQuery Redirector will be applied to any executing DeleteObjectQuery or DeleteAllQuery that does not have a redirector set directly on the query. Query redirectors allow the user to intercept query exection preventing it or alternately performing some side effect like auditing.- See Also:
QueryRedirector
-
getSequence
public Sequence getSequence()
Return the descriptor's sequence. This is normally set when the descriptor is initialized.
-
setSequence
public void setSequence(Sequence sequence)
Set the descriptor's sequence. This is normally set when the descriptor is initialized.
-
getMappingsPostCalculateChanges
public java.util.List<DatabaseMapping> getMappingsPostCalculateChanges()
Mappings that require postCalculateChanges method to be called
-
hasMappingsPostCalculateChanges
public boolean hasMappingsPostCalculateChanges()
Are there any mappings that require postCalculateChanges method to be called.
-
addMappingsPostCalculateChanges
public void addMappingsPostCalculateChanges(DatabaseMapping mapping)
Add a mapping to the list of mappings that require postCalculateChanges method to be called.
-
getMappingsPostCalculateChangesOnDeleted
public java.util.List<DatabaseMapping> getMappingsPostCalculateChangesOnDeleted()
Mappings that require mappingsPostCalculateChangesOnDeleted method to be called
-
hasMappingsPostCalculateChangesOnDeleted
public boolean hasMappingsPostCalculateChangesOnDeleted()
Are there any mappings that require mappingsPostCalculateChangesOnDeleted method to be called.
-
addMappingsPostCalculateChangesOnDeleted
public void addMappingsPostCalculateChangesOnDeleted(DatabaseMapping mapping)
Add a mapping to the list of mappings that require mappingsPostCalculateChangesOnDeleted method to be called.
-
hasMultipleTableConstraintDependecy
public boolean hasMultipleTableConstraintDependecy()
Return if any mapping reference a field in a secondary table. This is used to disable deferring multiple table writes.
-
hasMultitenantPolicy
public boolean hasMultitenantPolicy()
Return true if the descriptor has a multitenant policy
-
hasTablePerMultitenantPolicy
public boolean hasTablePerMultitenantPolicy()
PUBLIC- Returns:
- true if this descriptor is configured with a table per tenant policy.
-
hasUnconvertedProperties
public boolean hasUnconvertedProperties()
INTERNAL: Used to store un-converted properties, which are subsequenctly converted at runtime (through the convertClassNamesToClasses method.
-
setHasMultipleTableConstraintDependecy
public void setHasMultipleTableConstraintDependecy(boolean hasMultipleTableConstraintDependecy)
Set if any mapping reference a field in a secondary table. This is used to disable deferring multiple table writes.
-
usesPropertyAccessForWeaving
public boolean usesPropertyAccessForWeaving()
INTERNAL: Return whether this descriptor uses property access. This information is used to modify the behavior of some of our weaving features
-
usePropertyAccessForWeaving
public void usePropertyAccessForWeaving()
INTERNAL: Record that this descriptor uses property access. This information is used to modify the behavior of some of our weaving features
-
getVirtualAttributeMethods
public java.util.List<org.eclipse.persistence.internal.descriptors.VirtualAttributeMethodInfo> getVirtualAttributeMethods()
INTERNAL: Return the list of virtual methods sets for this Entity. This list is used to control which methods are weaved
-
setVirtualAttributeMethods
public void setVirtualAttributeMethods(java.util.List<org.eclipse.persistence.internal.descriptors.VirtualAttributeMethodInfo> virtualAttributeMethods)
INTERNAL: Set the list of methods used my mappings with virtual access this list is used to determine which methods to weave
-
hasTargetForeignKeyMapping
public boolean hasTargetForeignKeyMapping(org.eclipse.persistence.internal.sessions.AbstractSession session)
INTERNAL: Indicates whether descriptor has at least one target foreign key mapping
-
getAttributeGroup
public AttributeGroup getAttributeGroup(java.lang.String name)
Description copied from class:CoreDescriptorPUBLIC: Returns the attribute group corresponding to the name provided. If no group is found with the specified name, null is returned.- Overrides:
getAttributeGroupin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
getAttributeGroups
public java.util.Map<java.lang.String,AttributeGroup> getAttributeGroups()
Description copied from class:CoreDescriptorADVANCED: Returns the attribute groups for this Descriptor.- Overrides:
getAttributeGroupsin classCoreDescriptor<AttributeGroup,DescriptorEventManager,org.eclipse.persistence.internal.helper.DatabaseField,InheritancePolicy,org.eclipse.persistence.internal.descriptors.InstantiationPolicy,java.util.Vector,org.eclipse.persistence.internal.descriptors.ObjectBuilder>
-
clearReferencingClasses
public void clearReferencingClasses()
INTERNAL: Cleans referencingClasses set. Called from ClientSession for proper cleanup and avoid memory leak.
-
-