Class Project

All Implemented Interfaces:
Serializable, Cloneable
Direct Known Subclasses:
DBWSModelProject, org.eclipse.persistence.internal.sessions.factories.NamespaceResolvableProject

public class Project extends CoreProject<ClassDescriptor,Login,DatabaseSession> implements Serializable, Cloneable
Purpose: Maintain all of the EclipseLink configuration information for a system.

Responsibilities:

  • Project options and defaults
  • Database login information
  • Descriptors
  • Validate Descriptors
  • Maintain sequencing information & other project options
See Also:
  • Field Details

    • name

      protected String name
    • datasourceLogin

      protected Login datasourceLogin
    • descriptors

      protected Map<Class,ClassDescriptor> descriptors
    • orderedDescriptors

      protected List<ClassDescriptor> orderedDescriptors
    • multitenantPolicy

      protected MultitenantPolicy multitenantPolicy
    • defaultReadOnlyClasses

      protected Vector defaultReadOnlyClasses
      Holds the default set of read-only classes that apply to each UnitOfWork.
    • aliasDescriptors

      protected Map aliasDescriptors
      Cache the EJBQL descriptor aliases.
    • hasIsolatedClasses

      protected boolean hasIsolatedClasses
      Cache if any descriptor is isolated. (set during initialization)
    • hasNonIsolatedUOWClasses

      protected boolean hasNonIsolatedUOWClasses
      Cache if all descriptors are isolated in the unit of work. (set during initialization)
    • hasGenericHistorySupport

      protected boolean hasGenericHistorySupport
      Cache if any descriptor has history. (set during initialization)
    • hasProxyIndirection

      protected boolean hasProxyIndirection
      Cache if any descriptor is using ProxyIndirection. (set during initialization
    • sqlResultSetMappings

      protected Map<String,SQLResultSetMapping> sqlResultSetMappings
      This a collection of 'maps' that allow users to map custom SQL to query results
    • jpqlParseCache

      protected transient org.eclipse.persistence.internal.helper.ConcurrentFixedCache jpqlParseCache
      PERF: Provide an JPQL parse cache to optimize dynamic JPQL.
    • defaultTemporalMutable

      protected boolean defaultTemporalMutable
      Define the default setting for configuring if dates and calendars are mutable.
    • hasMappingsPostCalculateChangesOnDeleted

      protected transient boolean hasMappingsPostCalculateChangesOnDeleted
      Indicates whether there is at least one descriptor that has at least on mapping that require a call on deleted objects to update change sets.
    • defaultIdentityMapClass

      protected Class defaultIdentityMapClass
      Default value for ClassDescriptor.identityMapClass.
    • defaultIdentityMapSize

      protected int defaultIdentityMapSize
      Default value for ClassDescriptor.identityMapSize.
    • defaultCacheIsolation

      protected CacheIsolationType defaultCacheIsolation
      Default value for ClassDescriptor.isIsolated.
    • defaultQueryResultsCachePolicy

      protected QueryResultsCachePolicy defaultQueryResultsCachePolicy
      Default value for query caching options for all named queries.
    • defaultIdValidation

      protected IdValidation defaultIdValidation
      Default value for ClassDescriptor.idValidation.
    • queries

      protected List<DatabaseQuery> queries
      List of queries - once Project is initialized, these are copied to the Session.
    • attributeGroups

      protected Map<String,AttributeGroup> attributeGroups
      List of named AttributeGroups - once Project is initialized, these are copied to the Session.
    • jpaQueries

      protected List<DatabaseQuery> jpaQueries
      List of queries from JPA that need special processing before execution.
    • jpaTablePerTenantQueries

      protected List<DatabaseQuery> jpaTablePerTenantQueries
      List of queries from JPA that may special processing and handling before execution.
    • allowNativeSQLQueries

      protected boolean allowNativeSQLQueries
      Flag that allows native queries or not
    • allowTablePerMultitenantDDLGeneration

      protected boolean allowTablePerMultitenantDDLGeneration
      Flag that allows DDL generation of table per tenant multitenant descriptors
    • allowSQLDeferral

      protected boolean allowSQLDeferral
      Flag that allows call deferral to be disabled
    • namingIntoIndexed

      protected boolean namingIntoIndexed
      Flag that allows transform named stored procedure parameters into positional/index based
    • allowExtendedCacheLogging

      protected boolean allowExtendedCacheLogging
      Flag that allows extended logging of JPA L2 cache or not.
    • allowExtendedThreadLogging

      protected boolean allowExtendedThreadLogging
      Flag that allows extended thread logging or not.
    • allowExtendedThreadLoggingThreadDump

      protected boolean allowExtendedThreadLoggingThreadDump
      Flag that allows add to extended thread logging output thread stack trace or not.
    • allowQueryResultsCacheValidation

      protected boolean allowQueryResultsCacheValidation
      Flag that allows query result cache validation or not.
    • mappedSuperclassDescriptors

      protected Map<String,ClassDescriptor> mappedSuperclassDescriptors
      Mapped Superclasses (JPA 2) collection of parent non-relational descriptors keyed on MetadataClass without creating a compile time dependency on JPA. The descriptor values of this map must not be replaced by a put() so that the mappings on the initial descriptor are not overwritten.

      These descriptors are only to be used by Metamodel generation.

    • metamodelIdClassMap

      protected Map<String,List<String>> metamodelIdClassMap
      Store the IdClass Id attributes for exclusive use by the Metamodel API Keyed on the fully qualified accessible object owner class name. Value is a List of the fully qualified id class name or id attribute name.
    • partitioningPolicies

      protected Map<String,PartitioningPolicy> partitioningPolicies
      Map of named partitioning policies, keyed by their name.
    • descriptorsLock

      protected Object descriptorsLock
      Ensures that only one thread at a time can add/remove descriptors
    • vpdIdentifier

      protected String vpdIdentifier
      VPD connection settings
    • vpdLastIdentifierClassName

      protected String vpdLastIdentifierClassName
    • classNamesForWeaving

      protected Collection<String> classNamesForWeaving
      used for Caching JPA projects
    • structConverters

      protected Collection<String> structConverters
    • queryCacheForceDeferredLocks

      protected boolean queryCacheForceDeferredLocks
      Force all queries and relationships to use deferred lock strategy during object building and L2 cache population.
  • Constructor Details

    • Project

      public Project()
      PUBLIC: Create a new project.
    • Project

      public Project(Login login)
      PUBLIC: Create a new project that will connect through the login information. This method can be used if the project is being create in code instead of being read from a file.
    • Project

      public Project(DatabaseLogin login)
      PUBLIC: Create a new project that will connect through JDBC using the login information. This method can be used if the project is being create in code instead of being read from a file.
  • Method Details

    • getDefaultQueryResultsCachePolicy

      public QueryResultsCachePolicy getDefaultQueryResultsCachePolicy()
      PUBLIC: Return the default values for query caching options for all named queries.
    • setDefaultQueryResultsCachePolicy

      public void setDefaultQueryResultsCachePolicy(QueryResultsCachePolicy defaultQueryResultsCachePolicy)
      PUBLIC: Set the default values for query caching options for all named queries. By default no query caching is used.
    • isQueryCacheForceDeferredLocks

      public boolean isQueryCacheForceDeferredLocks()
      PUBLIC: Get property to Force all queries and relationships to use deferred lock strategy during object building and L2 cache population.
    • setQueryCacheForceDeferredLocks

      public void setQueryCacheForceDeferredLocks(boolean queryCacheForceDeferredLocks)
      PUBLIC: Set property to Force all queries and relationships to use deferred lock strategy during object building and L2 cache population. By default there is false value - use use mixed object cache locking strategy (depends on relationship and fetch type)
    • getDefaultTemporalMutable

      public boolean getDefaultTemporalMutable()
      PUBLIC: Return the default setting for configuring if dates and calendars are mutable. Mutable means that changes to the date's year/month/day are detected. By default they are treated as not mutable.
    • setDefaultTemporalMutable

      public void setDefaultTemporalMutable(boolean defaultTemporalMutable)
      PUBLIC: Set the default setting for configuring if dates and calendars are mutable. Mutable means that changes to the date's year/month/day are detected. By default they are treated as not mutable.
    • getJPAQueries

      public List<DatabaseQuery> getJPAQueries()
      INTERNAL: Return all pre-defined not yet parsed JPQL queries.
    • getJPATablePerTenantQueries

      public List<DatabaseQuery> getJPATablePerTenantQueries()
      INTERNAL: Return all pre-defined not yet parsed JPQL queries to table per tenant entities.
    • getJPQLParseCache

      public org.eclipse.persistence.internal.helper.ConcurrentFixedCache getJPQLParseCache()
      INTERNAL: Return the JPQL parse cache. This is used to optimize dynamic JPQL.
    • setJPQLParseCacheMaxSize

      public void setJPQLParseCacheMaxSize(int maxSize)
      ADVANCED: Set the JPQL parse cache max size. This is used to optimize dynamic JPQL.
    • getJPQLParseCacheMaxSize

      public int getJPQLParseCacheMaxSize()
      ADVANCED: Return the JPQL parse cache max size. This is used to optimize dynamic JPQL.
    • setJPQLParseCache

      protected void setJPQLParseCache(org.eclipse.persistence.internal.helper.ConcurrentFixedCache jpqlParseCache)
      INTERNAL: Set the JPQL parse cache. This is used to optimize dynamic JPQL.
    • getQueries

      public List<DatabaseQuery> getQueries()
      INTERNAL: List of queries that upon initialization are copied over to the session
    • setQueries

      public void setQueries(List<DatabaseQuery> queries)
      INTERNAL:
      Parameters:
      queries -
    • getAttributeGroups

      public Map<String,AttributeGroup> getAttributeGroups()
      INTERNAL: List of named AttributesGroups that will be copied to the session at initialization time.
    • setVPDIdentifier

      public void setVPDIdentifier(String vpdIdentifier)
      INTERNAL: Set the VPD identifier for this project. This identifier should be populated from a descriptor VPDMultitenantPolicy and should not be set directly.
    • setVPDLastIdentifierClassName

      public void setVPDLastIdentifierClassName(String vpdLastIdentifierClassName)
      INTERNAL: Set from individual descriptors from the project that set a VPD identifier and used in validation exception.
    • addDefaultReadOnlyClass

      public void addDefaultReadOnlyClass(Class readOnlyClass)
      PUBLIC: Add the read-only class which apply to each UnitOfWork created by default.
    • addDescriptor

      public void addDescriptor(ClassDescriptor descriptor)
      PUBLIC: Add the descriptor to the project.
      Specified by:
      addDescriptor in class CoreProject<ClassDescriptor,Login,DatabaseSession>
    • addDescriptor

      public void addDescriptor(ClassDescriptor descriptor, org.eclipse.persistence.internal.sessions.DatabaseSessionImpl session)
      INTERNAL: Used by the BuilderInterface when reading a Project from INI files.
      Parameters:
      descriptor - The descriptor to be added to the session and the project.
      session - The current database session.
    • addDescriptors

      public void addDescriptors(Collection descriptors, org.eclipse.persistence.internal.sessions.DatabaseSessionImpl session)
      INTERNAL: Add the descriptors to the session. All persistent classes must have a descriptor registered for them with the session. This method allows for a batch of descriptors to be added at once so that EclipseLink can resolve the dependencies between the descriptors and perform initialization optimally.
      Parameters:
      descriptors - The descriptors to be added to the session and the project.
      session - The current database session.
    • addDescriptors

      public void addDescriptors(Project project, org.eclipse.persistence.internal.sessions.DatabaseSessionImpl session)
      PUBLIC: Merge the descriptors from another project into this one. All persistent classes must have a descriptor registered for them with the session. This method allows for a batch of descriptors to be added at once so that EclipseLink can resolve the dependencies between the descriptors and perform initialization optimally.
    • addSQLResultSetMapping

      public void addSQLResultSetMapping(SQLResultSetMapping sqlResultSetMapping)
      PUBLIC: Add a named SQLResultSetMapping to this project. These SQLResultSetMappings can be later used by ResultSetMappingQueries to map Custom sql results to results as defined by the SQLResultSetMappings.
    • conformAllDescriptors

      public void conformAllDescriptors()
      PUBLIC: Set all this project's descriptors to conform all read queries within the context of the unit of work.
    • convertClassNamesToClasses

      public void convertClassNamesToClasses(ClassLoader classLoader)
      INTERNAL: Convert all the class-name-based settings in this project to actual class-based settings. This will also reset any class references to the version of the class from the class loader.
      Specified by:
      convertClassNamesToClasses in class CoreProject<ClassDescriptor,Login,DatabaseSession>
    • assumeExistenceForDoesExist

      public void assumeExistenceForDoesExist()
      PUBLIC: Switch all descriptors to assume existence for non-null primary keys.
    • checkCacheForDoesExist

      public void checkCacheForDoesExist()
      PUBLIC: Switch all descriptors to check the cache for existence.
    • checkDatabaseForDoesExist

      public void checkDatabaseForDoesExist()
      PUBLIC: Switch all descriptors to check the database for existence.
    • clone

      public Project clone()
      INTERNAL: Clones the descriptor
      Overrides:
      clone in class Object
    • createDatabaseSession

      public DatabaseSession createDatabaseSession()
      PUBLIC: Factory method to create session. This returns an implementor of the DatabaseSession interface, which can be used to login and add descriptors from other projects. The Session interface however should be used for reading and writing once connected for complete portability.
      Specified by:
      createDatabaseSession in class CoreProject<ClassDescriptor,Login,DatabaseSession>
    • createServerSession

      public Server createServerSession()
      PUBLIC: Factory method to create a server session. This returns an implementor of the Server interface, which can be used to login and add descriptors from other projects, configure connection pooling and acquire client sessions.
      By default the ServerSession has a single shared read/write connection pool with 32 min/max connections and an initial of 1 connection.
    • createServerSession

      public Server createServerSession(int min, int max)
      PUBLIC: Factory method to create a server session. This returns an implementor of the Server interface, which can be used to login and add descriptors from other projects, configure connection pooling and acquire client sessions. Configure the min and max number of connections for the default shared read/write pool.
    • createServerSession

      public Server createServerSession(int initial, int min, int max)
      PUBLIC: Factory method to create a server session. This returns an implementor of the Server interface, which can be used to login and add descriptors from other projects, configure connection pooling and acquire client sessions. Configure the min and max number of connections for the default shared read/write pool.
    • createServerSession

      public Server createServerSession(ConnectionPolicy defaultConnectionPolicy)
      PUBLIC: Factory method to create a server session. This returns an implementor of the Server interface, which can be used to login and add descriptors from other projects, configure connection pooling and acquire client sessions. Configure the default connection policy to be used. This policy is used on the "acquireClientSession()" protocol.
      By default the ServerSession has a single shared read/write connection pool with 32 min/max connections and an initial of 1 connection.
    • getDefaultReadOnlyClasses

      public Vector getDefaultReadOnlyClasses()
      PUBLIC: Returns the default set of read-only classes.
    • getDefaultIdentityMapClass

      public Class getDefaultIdentityMapClass()
      PUBLIC: Return default value for descriptor cache type.
    • getDefaultIdentityMapSize

      public int getDefaultIdentityMapSize()
      PUBLIC: Return default value descriptor cache size.
    • getDefaultCacheIsolation

      public CacheIsolationType getDefaultCacheIsolation()
      PUBLIC: Return the project level default for class cache isolation;
    • getDefaultIdValidation

      public IdValidation getDefaultIdValidation()
      PUBLIC: Return default value for descriptor primary key validation.
    • getClassDescriptor

      public ClassDescriptor getClassDescriptor(Class theClass)
      PUBLIC: Return the descriptor specified for the class. If the passed Class parameter is null, null will be returned.
    • getDescriptor

      public ClassDescriptor getDescriptor(Class theClass)
      PUBLIC: Return the descriptor specified for the class.
      Specified by:
      getDescriptor in class CoreProject<ClassDescriptor,Login,DatabaseSession>
    • getDescriptors

      public Map<Class,ClassDescriptor> getDescriptors()
      PUBLIC: Return the descriptors in a ClassDescriptors Map keyed on the Java class.
    • getOrderedDescriptors

      public List<ClassDescriptor> getOrderedDescriptors()
      INTERNAL: Return the descriptors in the order added. Used to maintain consistent order in XML.
      Specified by:
      getOrderedDescriptors in class CoreProject<ClassDescriptor,Login,DatabaseSession>
    • setOrderedDescriptors

      public void setOrderedDescriptors(List<ClassDescriptor> orderedDescriptors)
      INTERNAL: Set the descriptors order. Used to maintain consistent order in XML.
    • getClassNamesForWeaving

      public Collection<String> getClassNamesForWeaving()
      INTERNAL: Returns all classes in this project that are needed for weaving. This list currently includes entity, embeddables and mappedSuperClasses.
    • setClassNamesForWeaving

      public void setClassNamesForWeaving(Collection<String> classNamesForWeaving)
      INTERNAL: Returns all classes in this project that are needed for weaving. This list currently includes entity, embeddables and mappedSuperClasses.
    • getLogin

      public DatabaseLogin getLogin()
      OBSOLETE: Return the login, the login holds any database connection information given. This has been replaced by getDatasourceLogin to make use of the Login interface to support non-relational datasources, if DatabaseLogin API is required it will need to be cast.
    • getDatasourceLogin

      public Login getDatasourceLogin()
      PUBLIC: Return the login, the login holds any database connection information given. This return the Login interface and may need to be cast to the datasource specific implementation.
      Specified by:
      getDatasourceLogin in class CoreProject<ClassDescriptor,Login,DatabaseSession>
    • getName

      public String getName()
      PUBLIC: get the name of the project.
    • getSQLResultSetMapping

      public SQLResultSetMapping getSQLResultSetMapping(String sqlResultSetMapping)
      PUBLIC: Get a named SQLResultSetMapping from this project. These SQLResultSetMappings can be used by ResultSetMappingQueries to map Custom sql results to results as defined by the SQLResultSetMappings.
    • getStructConverters

      public Collection<String> getStructConverters()
      INTERNAL: Returns structure converter class names that would be set on the databasePlatform instance This is used to avoid the platform instance changing at login.
    • setStructConverters

      public void setStructConverters(Collection<String> structConverters)
      INTERNAL: Returns structure converter class names that would be set on the databasePlatform instance This is used to avoid the platform instance changing at login.
    • getVPDLastIdentifierClassName

      public String getVPDLastIdentifierClassName()
      INTERNAL: Return the name of the last class to set a VPD identifiers.
    • getVPDIdentifier

      public String getVPDIdentifier()
      INTERNAL: Return the VPD identifier for this project.
    • getMultitenantPolicy

      public MultitenantPolicy getMultitenantPolicy()
      INTERNAL:
    • hasGenericHistorySupport

      public boolean hasGenericHistorySupport()
      INTERNAL: Answers if at least one Descriptor or Mapping had a HistoryPolicy at initialize time.
    • setDefaultReadOnlyClasses

      public void setDefaultReadOnlyClasses(Collection newValue)
      PUBLIC: Set the read-only classes which apply to each UnitOfWork create by default.
    • setDefaultIdentityMapClass

      public void setDefaultIdentityMapClass(Class defaultIdentityMapClass)
      PUBLIC: Set default value for descriptor cache type.
    • setDefaultIdentityMapSize

      public void setDefaultIdentityMapSize(int defaultIdentityMapSize)
      PUBLIC: Set default value descriptor cache size.
    • setDefaultCacheIsolation

      public void setDefaultCacheIsolation(CacheIsolationType isolationType)
      PUBLIC: Set project level default value for class cache isolation.
    • setDefaultIdValidation

      public void setDefaultIdValidation(IdValidation defaultIdValidation)
      PUBLIC: Set default value for descriptor primary key validation.
    • setDescriptors

      public void setDescriptors(Map descriptors)
      INTERNAL: Set the descriptors registered with this session.
    • setDeferModificationsUntilCommit

      public void setDeferModificationsUntilCommit(int deferralLevel)
      ADVANCED: This method is a 'helper' method for updating all of the descriptors within this project to have a particular deferral level. The levels are as follows ClassDescriptor.ALL_MODIFICATIONS - this is the default and recommended. The writing of all changes will be deferred until the end of the transaction ClassDescriptor.UPDATE_MODIFICATIONS - this will cause the update changes to be deferred and all other changes to be written immediately. ClassDescriptor.NONE - this will cause all changes to be written on each container call.
    • setHasGenericHistorySupport

      public void setHasGenericHistorySupport(boolean hasGenericHistorySupport)
      INTERNAL: Set to true during descriptor initialize if any descriptor has history.
    • hasIsolatedCacheClassWithoutUOWIsolation

      public boolean hasIsolatedCacheClassWithoutUOWIsolation()
      INTERNAL: Return whether this project has a descriptor that is both Isolated and has a cache isolation level other than ISOLATE_CACHE_ALWAYS
      Returns:
    • hasIsolatedClasses

      public boolean hasIsolatedClasses()
      INTERNAL: Return if any descriptors are isolated. Set to true during descriptor initialize if any descriptor is isolated. Determines if an isolated client session is required.
    • setHasIsolatedClasses

      public void setHasIsolatedClasses(boolean hasIsolatedClasses)
      INTERNAL: Set to true during descriptor initialize if any descriptor is isolated. Determines if an isolated client session is required.
    • hasNonIsolatedUOWClasses

      public boolean hasNonIsolatedUOWClasses()
      INTERNAL: Return if any descriptors are not isolated to the unit of work. Set to true during descriptor initialize if any descriptor is not isolated. Allows uow merge to be bypassed.
    • setHasNonIsolatedUOWClasses

      public void setHasNonIsolatedUOWClasses(boolean hasNonIsolatedUOWClasses)
      INTERNAL: Set if any descriptors are not isolated to the unit of work. Set to true during descriptor initialize if any descriptor is not isolated. Allows uow merge to be bypassed.
    • hasProxyIndirection

      public boolean hasProxyIndirection()
      INTERNAL: Return if any descriptors use ProxyIndirection. Set to true during descriptor initialize if any descriptor uses ProxyIndirection Determines if ProxyIndirectionPolicy.getValueFromProxy should be called.
    • hasSQLResultSetMapping

      public boolean hasSQLResultSetMapping(String sqlResultSetMapping)
      PUBLIC: Return true if the sql result set mapping name exists.
    • hasVPDIdentifier

      public boolean hasVPDIdentifier(org.eclipse.persistence.internal.sessions.AbstractSession session)
      PUBLIC: Return true if there is a VPD identifier for this project. Will not be set till after descriptor initialization.
    • setHasProxyIndirection

      public void setHasProxyIndirection(boolean hasProxyIndirection)
      INTERNAL: Set to true during descriptor initialize if any descriptor uses ProxyIndirection Determines if ProxyIndirectionPolicy.getValueFromProxy should be called.
    • setLogin

      public void setLogin(DatabaseLogin datasourceLogin)
      PUBLIC: Set the login to be used to connect to the database for this project.
    • setMultitenantPolicy

      public void setMultitenantPolicy(MultitenantPolicy policy)
      INTERNAL: Set the multitenant policy.
    • setLogin

      public void setLogin(Login datasourceLogin)
      PUBLIC: Set the login to be used to connect to the database for this project.
      Specified by:
      setLogin in class CoreProject<ClassDescriptor,Login,DatabaseSession>
    • setDatasourceLogin

      public void setDatasourceLogin(Login datasourceLogin)
      PUBLIC: Set the login to be used to connect to the database for this project.
    • setName

      public void setName(String name)
      PUBLIC: Set the name of the project.
    • toString

      public String toString()
      INTERNAL:
      Overrides:
      toString in class Object
    • useCacheIdentityMap

      public void useCacheIdentityMap()
      PUBLIC: Switch all descriptors to use the cache identity map.
    • useCacheIdentityMap

      public void useCacheIdentityMap(int cacheSize)
      PUBLIC: Switch all descriptors to use the cache identity map the size.
    • useFullIdentityMap

      public void useFullIdentityMap()
      PUBLIC: Switch all descriptors to use the full identity map.
    • useFullIdentityMap

      public void useFullIdentityMap(int initialCacheSize)
      PUBLIC: Switch all descriptors to use the full identity map with initial cache size.
    • useNoIdentityMap

      public void useNoIdentityMap()
      PUBLIC: Switch all descriptors to use no identity map.
    • useSoftCacheWeakIdentityMap

      public void useSoftCacheWeakIdentityMap()
      PUBLIC: Switch all descriptors to use the soft cache weak identity map.
    • useSoftCacheWeakIdentityMap

      public void useSoftCacheWeakIdentityMap(int cacheSize)
      PUBLIC: Switch all descriptors to use the soft cache weak identity map with soft cache size.
    • usesOptimisticLocking

      public boolean usesOptimisticLocking()
      INTERNAL: Asks each descriptor if is uses optimistic locking.
    • usesSequencing

      public boolean usesSequencing()
      INTERNAL: Asks each descriptor if is uses sequencing.
    • useWeakIdentityMap

      public void useWeakIdentityMap()
      PUBLIC: Switch all descriptors to use the weak identity map.
    • useWeakIdentityMap

      public void useWeakIdentityMap(int initialCacheSize)
      PUBLIC: Switch all descriptors to use the weak identity map.
    • applyLogin

      public void applyLogin()
      INTERNAL: Default apply login implementation. Defined for generated subclasses that may not have a login. BUG#2669342
    • getAliasDescriptors

      public Map getAliasDescriptors()
      INTERNAL: Returns the alias descriptors hashtable.
    • addAlias

      public void addAlias(String alias, ClassDescriptor descriptor)
      PUBLIC: Add an alias for the descriptor.
    • allowTablePerMultitenantDDLGeneration

      public boolean allowTablePerMultitenantDDLGeneration()
      INTERNAL: Return true if native sql is allowed on this project.
    • allowNativeSQLQueries

      public boolean allowNativeSQLQueries()
      INTERNAL: Return true if native sql is allowed on this project.
    • allowSQLDeferral

      public boolean allowSQLDeferral()
      INTERNAL: Return true if SQL calls can defer to EOT on this project.
    • namingIntoIndexed

      public boolean namingIntoIndexed()
      INTERNAL: Return true is allowed to transform named stored procedure parameters into positional/index based.
    • allowExtendedCacheLogging

      public boolean allowExtendedCacheLogging()
      INTERNAL: Return true if extended logging of JPA L2 cache usage is allowed on this project.
    • allowExtendedThreadLogging

      public boolean allowExtendedThreadLogging()
      INTERNAL: Return true if extended thread logging is allowed on this project.
    • allowExtendedThreadLoggingThreadDump

      public boolean allowExtendedThreadLoggingThreadDump()
      INTERNAL: Return true if thread dumps will be added to extended thread logging.
    • isAllowQueryResultsCacheValidation

      public boolean isAllowQueryResultsCacheValidation()
      INTERNAL: Flag that allows query result cache validation or not. If true result is presented via log messages.
    • getDescriptorForAlias

      public ClassDescriptor getDescriptorForAlias(String alias)
      PUBLIC: Return the descriptor for the alias
    • setAliasDescriptors

      public void setAliasDescriptors(Map aHashtable)
      INTERNAL: Set the alias descriptors hashtable.
    • setAllowTablePerMultitenantDDLGeneration

      public void setAllowTablePerMultitenantDDLGeneration(boolean allowTablePerMultitenantDDLGeneration)
      INTERNAL: Set whether ddl generation should allowed for table per tenant multitenant descriptors. This will only be true when a non shared emf is used and all the tenant context properties are provided at deploy time.
    • setAllowNativeSQLQueries

      public void setAllowNativeSQLQueries(boolean allowNativeSQLQueries)
      INTERNAL: Set whether native sql is allowed on this project.
    • setAllowSQLDeferral

      public void setAllowSQLDeferral(boolean allowSQLDeferral)
      INTERNAL: Set whether sql deferral is allowed on this project
    • setNamingIntoIndexed

      public void setNamingIntoIndexed(boolean namingIntoIndexed)
      INTERNAL: Set whether named stored procedure parameters is allowed to transform into positional/index based.
    • setAllowExtendedCacheLogging

      public void setAllowExtendedCacheLogging(boolean allowExtendedCacheLogging)
      INTERNAL: Set whether extended logging of JPA L2 cache usage is allowed on this project.
    • setAllowExtendedThreadLogging

      public void setAllowExtendedThreadLogging(boolean allowExtendedThreadLogging)
      INTERNAL: Set whether extended thread logging is allowed on this project.
    • setAllowExtendedThreadLoggingThreadDump

      public void setAllowExtendedThreadLoggingThreadDump(boolean allowExtendedThreadLoggingThreadDump)
      INTERNAL: Set if thread dumps will be added to extended thread logging.
    • setAllowQueryResultsCacheValidation

      public void setAllowQueryResultsCacheValidation(boolean allowQueryResultsCacheValidation)
      INTERNAL: Set to true to enable query result cache validation or not. Result is presented via log messages.
    • hasMappingsPostCalculateChangesOnDeleted

      public boolean hasMappingsPostCalculateChangesOnDeleted()
      INTERNAL: Indicates whether there is at least one descriptor that has at least on mapping that require a call on deleted objects to update change sets.
    • setHasMappingsPostCalculateChangesOnDeleted

      public void setHasMappingsPostCalculateChangesOnDeleted(boolean hasMappingsPostCalculateChangesOnDeleted)
      INTERNAL: Indicates whether there is at least one descriptor that has at least on mapping that require a call on deleted objects to update change sets.
    • hasMappedSuperclasses

      public boolean hasMappedSuperclasses()
      INTERNAL: Return whether there any mappings that are mapped superclasses.
      Returns:
    • hasMappedSuperclass

      public boolean hasMappedSuperclass(String className)
      INTERNAL: Return whether the given class is mapped as superclass.
      Parameters:
      className -
      Returns:
    • addJPAQuery

      public void addJPAQuery(DatabaseQuery query)
      INTERNAL: Return all pre-defined not yet parsed EJBQL queries.
    • addJPATablePerTenantQuery

      public void addJPATablePerTenantQuery(DatabaseQuery query)
      INTERNAL: Return all pre-defined not yet parsed EJBQL queries to table per tenant entities.
    • addMappedSuperclass

      public void addMappedSuperclass(String key, ClassDescriptor value, boolean replace)
      INTERNAL: 266912: Add a descriptor to the Map of mappedSuperclass descriptors
      Parameters:
      key - (Metadata class)
      value - (RelationalDescriptor)
    • getMappedSuperclass

      public ClassDescriptor getMappedSuperclass(String key)
      INTERNAL: Use the Metadata key parameter to lookup the Descriptor from the Map of mappedSuperclass descriptors
      Parameters:
      key - - theMetadata class
    • getMappedSuperclassDescriptors

      public Map<String,ClassDescriptor> getMappedSuperclassDescriptors()
      INTERNAL: Return the Map of RelationalDescriptor objects representing mapped superclass parents keyed by className of the metadata class.
    • addMetamodelIdClassMapEntry

      public void addMetamodelIdClassMapEntry(String ownerName, String name)
      INTERNAL: Add an IdClass entry to the map of ids for a particular owner This function is used exclusively by the Metamodel API.
    • getMetamodelIdClassMap

      public Map<String,List<String>> getMetamodelIdClassMap()
      INTERNAL: Return the Map of IdClass attribute lists keyed on owner class name.
    • getPartitioningPolicies

      public Map<String,PartitioningPolicy> getPartitioningPolicies()
      PUBLIC: Return the map of partitioning policies, keyed by name.
    • setPartitioningPolicies

      public void setPartitioningPolicies(Map<String,PartitioningPolicy> partitioningPolicies)
      PUBLIC: Set the map of partitioning policies, keyed by name.
    • addPartitioningPolicy

      public void addPartitioningPolicy(PartitioningPolicy partitioningPolicy)
      PUBLIC: Set the map of partitioning policies, keyed by name.
    • getPartitioningPolicy

      public PartitioningPolicy getPartitioningPolicy(String name)
      PUBLIC: Return the partitioning policies for the name.