public class ClassView extends ViewImpl implements DatastoreClass
columns, 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 |
|---|
ClassView(DatastoreIdentifier tableName,
RDBMSStoreManager storeMgr,
org.datanucleus.metadata.ClassMetaData cmd)
Constructor for class view.
|
| Modifier and Type | Method and Description |
|---|---|
DatastoreClass |
getBaseDatastoreClass()
Accessor for the base datastore class.
|
DatastoreClass |
getBaseDatastoreClassWithMember(org.datanucleus.metadata.AbstractMemberMetaData mmd)
Accessor for the base datastore class (table) managing the given field.
|
org.datanucleus.metadata.DiscriminatorMetaData |
getDiscriminatorMetaData()
Accessor for Discriminator MetaData
|
JavaTypeMapping |
getExternalMapping(org.datanucleus.metadata.AbstractMemberMetaData mmd,
MappingType mappingType)
Accessor for the external mapping for the specified member of the specified mapping type.
|
org.datanucleus.metadata.AbstractMemberMetaData |
getFieldMetaData(String fieldName)
Accessor for the MetaData for the named field
|
org.datanucleus.metadata.IdentityType |
getIdentityType()
Accessor for the identity type in use.
|
JavaTypeMapping |
getIdMapping()
Accessor for a mapping for the ID.
|
String[] |
getManagedClasses()
Accessor for the names of all classes managed by this table.
|
JavaTypeMapping |
getMemberMapping(org.datanucleus.metadata.AbstractMemberMetaData mmd)
Accessor for the mapping for the specified field/property.
|
JavaTypeMapping |
getMemberMapping(String fieldName)
Accessor for the field mapping for the specified field name.
|
JavaTypeMapping |
getMemberMappingInDatastoreClass(org.datanucleus.metadata.AbstractMemberMetaData mmd)
Accessor for the mapping for the specified field only in this datastore class.
|
org.datanucleus.metadata.AbstractMemberMetaData |
getMetaDataForExternalMapping(JavaTypeMapping mapping,
MappingType mappingType)
Accessor for the owner field metadata for the specified external mapping of the specified type
|
Collection |
getSecondaryDatastoreClasses()
Accessor for any secondary tables for this table.
|
protected List<String> |
getSQLCreateStatements(Properties props)
Method to return the necessary SQL create statements for this table.
|
DatastoreClass |
getSuperDatastoreClass()
Accessor for the supertable for this table.
|
Column |
getSurrogateColumn(org.datanucleus.store.schema.table.SurrogateColumnType colType) |
String |
getType()
Accessor for the type of the class being represented by this view.
|
org.datanucleus.metadata.VersionMetaData |
getVersionMetaData()
Accessor for Version MetaData
|
void |
initialize(org.datanucleus.ClassLoaderResolver clr)
Method to initialise the view.
|
boolean |
isBaseDatastoreClass()
Accessor for whether this is a base datastore class (root in a hierarchy).
|
boolean |
isObjectIdDatastoreAttributed()
Accessor for whether the object ID is attributed in the datastore.
|
boolean |
isSuperDatastoreClass(DatastoreClass table)
Accessor whether the supplied DatastoreClass is a supertable of this table.
|
boolean |
managesClass(String className)
Accessor for whether this table manages the specified class
|
boolean |
managesMapping(JavaTypeMapping mapping)
Convenience method to return if this table manages the columns for the supplied mapping.
|
void |
postInitialize(org.datanucleus.ClassLoaderResolver clr)
Post initilize.
|
void |
provideExternalMappings(MappingConsumer consumer,
MappingType mappingType)
Instruction to provide all external mappings to the passed consumer.
|
void |
provideMappingsForMembers(MappingConsumer consumer,
org.datanucleus.metadata.AbstractMemberMetaData[] fieldNumbers,
boolean includeSecondaryTables)
Provide the mappings to the consumer for all specified members.
|
void |
provideNonPrimaryKeyMappings(MappingConsumer consumer)
Provide the mappings to the consumer for all non primary-key fields mapped to this table.
|
void |
providePrimaryKeyMappings(MappingConsumer consumer)
Provide the mappings to the consumer for all primary-key fields mapped to
this table (for application identity).
|
void |
provideSurrogateMapping(org.datanucleus.store.schema.table.SurrogateColumnType colType,
MappingConsumer consumer)
Provide the mapping for the specified surrogate column (if present).
|
void |
provideUnmappedColumns(MappingConsumer consumer)
Method to provide all unmapped columns to the consumer.
|
addColumnInternal, getSQLDropStatements, preInitialize, validateaddColumn, allowDDLOutput, assertIsInitialized, assertIsInitializedModified, assertIsPKInitialized, assertIsPKUninitialized, assertIsUninitialized, assertIsValidated, create, drop, equals, executeDdlStatement, executeDdlStatementList, exists, getCatalogName, getClassMetaData, getColumn, getColumnForName, getColumnForPosition, getColumns, getDatastoreIdentifierFullyQualified, getIdentifier, getMemberColumnMappingForEmbeddedMember, getMemberColumnMappingForMember, getMemberColumnMappings, getName, getNumberOfColumns, getSchemaName, getStoreManager, getSurrogateMapping, hasColumn, hasColumnName, hashCode, isInitialized, isInitializedModified, isPKInitialized, isValidated, tableExistsInDatastore, toStringclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waittoStringaddColumn, create, drop, exists, getColumn, getIdentifier, getStoreManager, getSurrogateMapping, hasColumn, isInitialized, isInitializedModified, isValidated, preInitialize, validategetCatalogName, getClassMetaData, getColumnForName, getColumnForPosition, getColumns, getMemberColumnMappingForEmbeddedMember, getMemberColumnMappingForMember, getMemberColumnMappings, getName, getNumberOfColumns, getSchemaNamepublic ClassView(DatastoreIdentifier tableName, RDBMSStoreManager storeMgr, org.datanucleus.metadata.ClassMetaData cmd)
tableName - The name of the view.storeMgr - The RDBMS manager managing this viewcmd - The metadata for the class represented by this view.public void initialize(org.datanucleus.ClassLoaderResolver clr)
clr - The ClassLoaderResolverpublic void postInitialize(org.datanucleus.ClassLoaderResolver clr)
postInitialize in class ViewImplclr - the ClassLoaderResolverpublic JavaTypeMapping getIdMapping()
public DatastoreClass getBaseDatastoreClassWithMember(org.datanucleus.metadata.AbstractMemberMetaData mmd)
getBaseDatastoreClassWithMember in interface DatastoreClassmmd - MetaData for the fieldpublic DatastoreClass getSuperDatastoreClass()
getSuperDatastoreClass in interface DatastoreClasspublic boolean isSuperDatastoreClass(DatastoreClass table)
isSuperDatastoreClass in interface DatastoreClasstable - The DatastoreClass to checkpublic Collection getSecondaryDatastoreClasses()
getSecondaryDatastoreClasses in interface DatastoreClasspublic boolean managesClass(String className)
managesClass in interface DatastoreClassclassName - Name of the classpublic String[] getManagedClasses()
DatastoreClassgetManagedClasses in interface DatastoreClasspublic boolean managesMapping(JavaTypeMapping mapping)
managesMapping in interface DatastoreClassmapping - The mappingpublic org.datanucleus.metadata.AbstractMemberMetaData getFieldMetaData(String fieldName)
fieldName - Name of the fieldpublic org.datanucleus.metadata.IdentityType getIdentityType()
getIdentityType in interface DatastoreClasspublic boolean isBaseDatastoreClass()
isBaseDatastoreClass in interface DatastoreClasspublic DatastoreClass getBaseDatastoreClass()
DatastoreClassgetBaseDatastoreClass in interface DatastoreClasspublic boolean isObjectIdDatastoreAttributed()
isObjectIdDatastoreAttributed in interface DatastoreClasspublic void provideSurrogateMapping(org.datanucleus.store.schema.table.SurrogateColumnType colType,
MappingConsumer consumer)
DatastoreClassprovideSurrogateMapping in interface DatastoreClasscolType - Type of surrogate columnconsumer - The consumer for the mappingpublic void provideMappingsForMembers(MappingConsumer consumer, org.datanucleus.metadata.AbstractMemberMetaData[] fieldNumbers, boolean includeSecondaryTables)
DatastoreClassprovideMappingsForMembers in interface DatastoreClassconsumer - Consumer for the mappingsfieldNumbers - MetaData of the fields/properties to provide mappings forincludeSecondaryTables - Whether to supply fields in secondary tablespublic void providePrimaryKeyMappings(MappingConsumer consumer)
DatastoreClassprovidePrimaryKeyMappings in interface DatastoreClassconsumer - Consumer for the mappingspublic void provideNonPrimaryKeyMappings(MappingConsumer consumer)
DatastoreClassprovideNonPrimaryKeyMappings in interface DatastoreClassconsumer - Consumer for the mappingspublic void provideExternalMappings(MappingConsumer consumer, MappingType mappingType)
DatastoreClassprovideExternalMappings in interface DatastoreClassconsumer - The consumer for the mappingsmappingType - Type of external mapping to providepublic void provideUnmappedColumns(MappingConsumer consumer)
provideUnmappedColumns in interface DatastoreClassconsumer - Consumer of informationpublic String getType()
getType in interface DatastoreClasspublic JavaTypeMapping getMemberMapping(org.datanucleus.metadata.AbstractMemberMetaData mmd)
getMemberMapping in interface DatastoreClassmmd - Metadata for the field/propertypublic JavaTypeMapping getMemberMappingInDatastoreClass(org.datanucleus.metadata.AbstractMemberMetaData mmd)
getMemberMappingInDatastoreClass in interface DatastoreClassmmd - Metadata of the field/propertypublic JavaTypeMapping getMemberMapping(String fieldName)
getMemberMapping in interface DatastoreClassfieldName - Name of the fieldprotected List<String> getSQLCreateStatements(Properties props)
getSQLCreateStatements in class AbstractTableprops - Properties for controlling the creation of viewspublic Column getSurrogateColumn(org.datanucleus.store.schema.table.SurrogateColumnType colType)
getSurrogateColumn in interface org.datanucleus.store.schema.table.TablegetSurrogateColumn in class AbstractTablepublic final org.datanucleus.metadata.DiscriminatorMetaData getDiscriminatorMetaData()
getDiscriminatorMetaData in class AbstractTablepublic final org.datanucleus.metadata.VersionMetaData getVersionMetaData()
getVersionMetaData in class AbstractTablepublic JavaTypeMapping getExternalMapping(org.datanucleus.metadata.AbstractMemberMetaData mmd, MappingType mappingType)
DatastoreClassgetExternalMapping in interface DatastoreClassmmd - MetaData for the (external) field/propertymappingType - The type of mappingpublic org.datanucleus.metadata.AbstractMemberMetaData getMetaDataForExternalMapping(JavaTypeMapping mapping, MappingType mappingType)
DatastoreClassgetMetaDataForExternalMapping in interface DatastoreClassmapping - The external mappingmappingType - The type of mappingCopyright © 2020. All rights reserved.