public abstract class ElementContainerTable extends JoinTable
| Modifier and Type | Field and Description |
|---|---|
protected JavaTypeMapping |
elementMapping
Mapping of an element.
|
protected JavaTypeMapping |
orderMapping
Order mapping, to provide part of the primary key.
|
protected JavaTypeMapping |
relationDiscriminatorMapping
Optional mapping for a column used to discriminate between elements of one collection from another.
|
protected String |
relationDiscriminatorValue
Value to use with any relation discriminator column for objects of this field placed in the join table.
|
mmd, ownerMapping, ownerTable, ownerTypecolumns, columnsByIdentifier, dba, existsInDatastore, identifier, state, storeMgr, TABLE_STATE_INITIALIZED, TABLE_STATE_INITIALIZED_MODIFIED, TABLE_STATE_NEW, TABLE_STATE_PK_INITIALIZED, TABLE_STATE_VALIDATED| Constructor and Description |
|---|
ElementContainerTable(Table ownerTable,
DatastoreIdentifier tableName,
org.datanucleus.metadata.AbstractMemberMetaData mmd,
RDBMSStoreManager storeMgr)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
applyUserPrimaryKeySpecification(org.datanucleus.metadata.PrimaryKeyMetaData pkmd)
Convenience method to apply the user specification of <primary-key> columns
|
JavaTypeMapping |
getElementMapping()
Accessor for the "element" mapping end of the relationship.
|
abstract String |
getElementType()
Access the element type class name
|
protected List |
getExpectedCandidateKeys()
Accessor for the candidate keys for this table.
|
List |
getExpectedForeignKeys(org.datanucleus.ClassLoaderResolver clr)
Accessor for the expected foreign keys for this table.
|
protected Set |
getExpectedIndices(org.datanucleus.ClassLoaderResolver clr)
Accessor for the indices for this table.
|
protected ForeignKey |
getForeignKeyToElement(DatastoreClass elementTable,
boolean autoMode,
JavaTypeMapping m)
Convenience method to generate a ForeignKey from this join table to an element table
using the specified mapping.
|
protected ForeignKey |
getForeignKeyToOwner(DatastoreClass ownerTable,
boolean autoMode)
Convenience method to generate a ForeignKey from this join table to an owner table.
|
JavaTypeMapping |
getMemberMapping(org.datanucleus.metadata.AbstractMemberMetaData mmd)
Accessor not used by this table.
|
JavaTypeMapping |
getOrderMapping()
Accessor for the order mapping.
|
JavaTypeMapping |
getRelationDiscriminatorMapping()
Accessor for the element discriminator mapping.
|
String |
getRelationDiscriminatorValue()
Accessor for the element discriminator value.
|
void |
initialize(org.datanucleus.ClassLoaderResolver clr)
Method to initialise the table definition.
|
getIdMapping, getOwnerMapping, getOwnerMemberMetaData, getOwnerTable, getPrimaryKey, requiresPrimaryKeycreateConstraints, dropConstraints, getSQLAddCandidateKeyStatements, getSQLAddFKStatements, getSQLCreateIndexStatements, getSQLCreateStatements, getSQLDropStatements, initializeColumnInfoForPrimaryKeyColumns, initializeColumnInfoFromDatastore, logMapping, postInitialize, preInitialize, validate, validateColumns, validateConstraints, validatePrimaryKeyaddColumn, addColumnInternal, allowDDLOutput, assertIsInitialized, assertIsInitializedModified, assertIsPKInitialized, assertIsPKUninitialized, assertIsUninitialized, assertIsValidated, create, drop, equals, executeDdlStatement, executeDdlStatementList, exists, getCatalogName, getClassMetaData, getColumn, getColumnForName, getColumnForPosition, getColumns, getDatastoreIdentifierFullyQualified, getDiscriminatorMetaData, getIdentifier, getMemberColumnMappingForEmbeddedMember, getMemberColumnMappingForMember, getMemberColumnMappings, getName, getNumberOfColumns, getSchemaName, getStoreManager, getSurrogateColumn, getSurrogateMapping, getVersionMetaData, hasColumn, hasColumnName, hashCode, isInitialized, isInitializedModified, isPKInitialized, isValidated, tableExistsInDatastore, toStringprotected JavaTypeMapping elementMapping
protected JavaTypeMapping orderMapping
protected JavaTypeMapping relationDiscriminatorMapping
protected String relationDiscriminatorValue
public ElementContainerTable(Table ownerTable, DatastoreIdentifier tableName, org.datanucleus.metadata.AbstractMemberMetaData mmd, RDBMSStoreManager storeMgr)
ownerTable - Table of the owner of this membertableName - Identifier name of this tablemmd - MetaData for the member owning this join tablestoreMgr - The Store Manager managing these tables.public void initialize(org.datanucleus.ClassLoaderResolver clr)
clr - The ClassLoaderResolverpublic abstract String getElementType()
protected void applyUserPrimaryKeySpecification(org.datanucleus.metadata.PrimaryKeyMetaData pkmd)
pkmd - MetaData for the primary keypublic JavaTypeMapping getMemberMapping(org.datanucleus.metadata.AbstractMemberMetaData mmd)
mmd - MetaData for the field whose mapping we wantpublic JavaTypeMapping getElementMapping()
public JavaTypeMapping getOrderMapping()
public JavaTypeMapping getRelationDiscriminatorMapping()
public String getRelationDiscriminatorValue()
protected ForeignKey getForeignKeyToOwner(DatastoreClass ownerTable, boolean autoMode)
ownerTable - The owner tableautoMode - Whether we are in auto mode (where we generate the keys regardless of what the metadata says)protected ForeignKey getForeignKeyToElement(DatastoreClass elementTable, boolean autoMode, JavaTypeMapping m)
elementTable - The element tableautoMode - Whether we are in auto mode (where we generate the keys regardless of what the metadata says)m - The mapping to the element tablepublic List getExpectedForeignKeys(org.datanucleus.ClassLoaderResolver clr)
getExpectedForeignKeys in class TableImplclr - The ClassLoaderResolverprotected Set getExpectedIndices(org.datanucleus.ClassLoaderResolver clr)
getExpectedIndices in class TableImplclr - The ClassLoaderResolverprotected List getExpectedCandidateKeys()
getExpectedCandidateKeys in class TableImplCopyright © 2020. All rights reserved.