public class RDBMSStoreManager
extends org.datanucleus.store.AbstractStoreManager
implements org.datanucleus.store.BackedSCOStoreManager, org.datanucleus.store.schema.SchemaAwareStoreManager, org.datanucleus.store.schema.SchemaScriptAwareStoreManager
The RDBMS manager's responsibilities extend those for StoreManager to add :
Modifier and Type | Field and Description |
---|---|
protected String |
catalogName
Catalog name for the database (if supported).
|
protected DatastoreAdapter |
dba
Adapter for the datastore being used.
|
protected SQLExpressionFactory |
expressionFactory
Factory for expressions using the generic query SQL mechanism.
|
protected IdentifierFactory |
identifierFactory
Factory for identifiers for this datastore.
|
protected Map<org.datanucleus.state.ObjectProvider,DatastoreClass> |
insertedDatastoreClassByObjectProvider
Map of DatastoreClass keyed by ObjectProvider, for objects currently being inserted.
|
protected MappingManager |
mappingManager
Manager for the mapping between Java and datastore types.
|
static String |
METADATA_NONDURABLE_REQUIRES_TABLE |
protected ReadWriteLock |
schemaLock
Lock object aimed at providing a lock on the schema definition managed here, preventing
reads while it is being updated etc.
|
protected String |
schemaName
Schema name for the database (if supported).
|
connectionMgr, flushProcess, namingFactory, nucleusContext, persistenceHandler, queryMgr, schemaHandler, storeDataMgr, storeManagerKey, valueGenerationMgr
OPTION_APPLICATION_COMPOSITE_ID, OPTION_APPLICATION_ID, OPTION_DATASTORE_ID, OPTION_DATASTORE_TIME_STORES_MILLISECS, OPTION_DATASTORE_TIME_STORES_NANOSECS, OPTION_DATASTORE_TIMEOUT, OPTION_NONDURABLE_ID, OPTION_ORM, OPTION_ORM_EMBEDDED_ARRAY, OPTION_ORM_EMBEDDED_ARRAY_NESTED, OPTION_ORM_EMBEDDED_COLLECTION, OPTION_ORM_EMBEDDED_COLLECTION_NESTED, OPTION_ORM_EMBEDDED_MAP, OPTION_ORM_EMBEDDED_MAP_NESTED, OPTION_ORM_EMBEDDED_PC, OPTION_ORM_EMBEDDED_PC_NESTED, OPTION_ORM_FOREIGN_KEYS, OPTION_ORM_INHERITANCE_COMPLETE_TABLE, OPTION_ORM_INHERITANCE_JOINED_TABLE, OPTION_ORM_INHERITANCE_SINGLE_TABLE, OPTION_ORM_SECONDARY_TABLE, OPTION_ORM_SERIALISED_ARRAY_ELEMENT, OPTION_ORM_SERIALISED_COLLECTION_ELEMENT, OPTION_ORM_SERIALISED_MAP_KEY, OPTION_ORM_SERIALISED_MAP_VALUE, OPTION_ORM_SERIALISED_PC, OPTION_QUERY_CANCEL, OPTION_QUERY_JDOQL_BITWISE_OPS, OPTION_QUERY_JDOQL_BULK_DELETE, OPTION_QUERY_JDOQL_BULK_INSERT, OPTION_QUERY_JDOQL_BULK_UPDATE, OPTION_QUERY_JPQL_BULK_DELETE, OPTION_QUERY_JPQL_BULK_INSERT, OPTION_QUERY_JPQL_BULK_UPDATE, OPTION_TRANSACTION_ACID, OPTION_TXN_ISOLATION_READ_COMMITTED, OPTION_TXN_ISOLATION_READ_UNCOMMITTED, OPTION_TXN_ISOLATION_REPEATABLE_READ, OPTION_TXN_ISOLATION_SERIALIZABLE, RELATION_IDENTITY_STORAGE_PERSISTABLE_IDENTITY
Constructor and Description |
---|
RDBMSStoreManager(org.datanucleus.ClassLoaderResolver clr,
org.datanucleus.PersistenceNucleusContext ctx,
Map<String,Object> props)
Constructs a new RDBMSManager.
|
Modifier and Type | Method and Description |
---|---|
void |
addSchemaCallback(String className,
org.datanucleus.metadata.AbstractMemberMetaData mmd) |
protected void |
addSequenceForMetaData(org.datanucleus.metadata.MetaData md,
String seq,
org.datanucleus.ClassLoaderResolver clr,
Set<String> sequencesGenerated,
FileWriter ddlWriter) |
protected void |
addSequenceTableForMetaData(org.datanucleus.metadata.MetaData md,
org.datanucleus.ClassLoaderResolver clr,
Set<String> seqTablesGenerated) |
void |
addWrittenDdlStatement(String stmt)
When we are in SchemaTool DDL mode, add a new DDL statement.
|
boolean |
allowsBatching()
Convenience method to return if the datastore supports batching and the user wants batching.
|
protected static Set<String> |
cleanInputClassNames(org.datanucleus.NucleusContext ctx,
Set<String> inputClassNames)
Method to generate a set of class names using the input list.
|
void |
close()
Release of resources
|
void |
createDatabase(String catalogName,
String schemaName,
Properties props) |
void |
createSchemaForClasses(Set<String> inputClassNames,
Properties props) |
protected void |
createSchemaSequences(Set<String> classNames,
org.datanucleus.ClassLoaderResolver clr,
FileWriter ddlWriter) |
void |
deleteDatabase(String catalogName,
String schemaName,
Properties props) |
void |
deleteSchemaForClasses(Set<String> inputClassNames,
Properties props) |
void |
executeScript(String script) |
org.datanucleus.store.types.scostore.Store |
getBackingStoreForField(org.datanucleus.ClassLoaderResolver clr,
org.datanucleus.metadata.AbstractMemberMetaData mmd,
Class type)
Accessor for the backing store for the specified member.
|
Calendar |
getCalendarForDateTimezone()
Accessor for the Calendar to be used in handling all timezone issues with the datastore.
|
String |
getCatalogName()
Accessor for the (default) RDBMS catalog name.
|
org.datanucleus.metadata.AbstractClassMetaData[] |
getClassesManagingTableForClass(org.datanucleus.metadata.AbstractClassMetaData cmd,
org.datanucleus.ClassLoaderResolver clr)
Method to return the class(es) that has a table managing the persistence of
the fields of the supplied class.
|
String |
getClassNameForObjectID(Object id,
org.datanucleus.ClassLoaderResolver clr,
org.datanucleus.ExecutionContext ec)
Returns the class corresponding to the given object identity.
|
RDBMSColumnInfo |
getColumnInfoForColumnName(Table table,
Connection conn,
DatastoreIdentifier column)
Returns the column info for a column name.
|
List<org.datanucleus.store.schema.StoreSchemaData> |
getColumnInfoForTable(Table table,
Connection conn)
Returns the column info for a database table.
|
boolean |
getCompleteDDL()
Accessor for whether we should generate complete DDL when in that mode.
|
DatastoreAdapter |
getDatastoreAdapter()
Gets the DatastoreAdapter to use for this store.
|
DatastoreClass |
getDatastoreClass(DatastoreIdentifier name)
Returns the datastore table having the given identifier.
|
DatastoreClass |
getDatastoreClass(String className,
org.datanucleus.ClassLoaderResolver clr)
Returns the primary datastore table serving as backing for the given class.
|
Date |
getDatastoreDate()
Get the date/time of the datastore.
|
Writer |
getDdlWriter()
Accessor for the writer for DDL (if set).
|
String |
getDefaultIdentifierCase()
Method to return the default identifier case.
|
String |
getDefaultObjectProviderClassName() |
org.datanucleus.store.types.scostore.Store |
getExistingBackingStoreForMember(org.datanucleus.metadata.AbstractMemberMetaData mmd) |
IdentifierFactory |
getIdentifierFactory()
Accessor for the factory for creating identifiers (table/column names etc).
|
Collection<Table> |
getManagedTables(String catalog,
String schema)
Convenience accessor of the Table objects managed in this datastore at this point.
|
MappingManager |
getMappingManager()
Gets the MappingManager to use for this store.
|
String |
getNativeQueryLanguage() |
protected Object |
getNextValueForValueGenerator(org.datanucleus.store.valuegenerator.ValueGenerator generator,
org.datanucleus.ExecutionContext ec)
Accessor for the next value from the specified ValueGenerator.
|
org.datanucleus.store.NucleusConnection |
getNucleusConnection(org.datanucleus.ExecutionContext ec)
Method to return a NucleusConnection for the ExecutionContext.
|
org.datanucleus.store.NucleusSequence |
getNucleusSequence(org.datanucleus.ExecutionContext ec,
org.datanucleus.metadata.SequenceMetaData seqmd)
Method to return a datastore sequence for this datastore matching the passed sequence MetaData.
|
protected Properties |
getPropertiesForValueGenerator(org.datanucleus.metadata.AbstractClassMetaData cmd,
int absoluteFieldNumber,
org.datanucleus.ClassLoaderResolver clr,
org.datanucleus.metadata.SequenceMetaData seqmd,
org.datanucleus.metadata.TableGeneratorMetaData tablegenmd)
Method to return the properties to pass to the ValueGenerator for the specified field.
|
String |
getQueryCacheKey() |
Object |
getResultValueAtPosition(ResultSet rs,
JavaTypeMapping mapping,
int position)
Method to return the value from the results for the mapping at the specified position.
|
org.datanucleus.util.MultiMap |
getSchemaCallbacks() |
String |
getSchemaName()
Accessor for the (default) RDBMS schema name.
|
SQLController |
getSQLController()
Accessor for the SQL controller.
|
SQLExpressionFactory |
getSQLExpressionFactory()
Accessor for the SQL expression factory to use when generating SQL statements.
|
SQLTypeInfo |
getSQLTypeInfoForJDBCType(int jdbcType)
Accessor for the SQL type info for the specified JDBC type
|
SQLTypeInfo |
getSQLTypeInfoForJDBCType(int jdbcType,
String sqlType)
Accessor for the SQL type info for the specified JDBC type.
|
org.datanucleus.store.StoreData[] |
getStoreDataForDatastoreContainerObject(DatastoreIdentifier tableIdentifier)
Utility to return all StoreData for a Datastore Container identifier.
|
Collection |
getSupportedOptions()
Accessor for the supported options in string form
|
Collection<String> |
getSupportedQueryLanguages() |
Table |
getTable(org.datanucleus.metadata.AbstractMemberMetaData mmd)
Returns the datastore container (table) for the specified field.
|
String |
getValueGenerationStrategyForNative(org.datanucleus.metadata.AbstractClassMetaData cmd,
int absFieldNumber)
Method defining which value-strategy to use when the user specifies "native".
|
boolean |
hasWrittenDdlStatement(String stmt)
When we are in SchemaTool DDL mode, return if the supplied statement is already present.
|
protected void |
initialiseIdentifierFactory(org.datanucleus.NucleusContext nucleusContext)
Method to create the IdentifierFactory to be used by this store.
|
boolean |
insertValuesOnInsert(DatastoreMapping datastoreMapping)
Accessor for whether this mapping requires values inserting on an INSERT.
|
void |
invalidateColumnInfoForTable(Table table)
Method to invalidate the cached column info for a table.
|
boolean |
isJdbcStore() |
boolean |
isObjectInserted(org.datanucleus.state.ObjectProvider op,
int fieldNumber)
Accessor for whether the specified field of the object is inserted in the datastore yet.
|
boolean |
isObjectInserted(org.datanucleus.state.ObjectProvider op,
String className)
Returns whether this object is inserted in the datastore far enough to be considered to be the
supplied type.
|
protected void |
logConfiguration()
Convenience method to log the configuration of this store manager.
|
void |
manageClasses(org.datanucleus.ClassLoaderResolver clr,
String... classNames)
Method to add several persistable classes to the store manager's set of supported classes.
|
Table |
newJoinTable(Table ownerTable,
org.datanucleus.metadata.AbstractMemberMetaData mmd,
org.datanucleus.ClassLoaderResolver clr)
Called by (container) Mapping objects to request the creation of a join table.
|
org.datanucleus.store.query.Query |
newQuery(String language,
org.datanucleus.ExecutionContext ec) |
org.datanucleus.store.query.Query |
newQuery(String language,
org.datanucleus.ExecutionContext ec,
org.datanucleus.store.query.Query q) |
org.datanucleus.store.query.Query |
newQuery(String language,
org.datanucleus.ExecutionContext ec,
String queryString) |
void |
printInformation(String category,
PrintStream ps)
Method to output particular information owned by this datastore.
|
void |
registerTableInitialized(Table table) |
void |
resolveIdentifierMacro(org.datanucleus.util.MacroString.IdentifierMacro im,
org.datanucleus.ClassLoaderResolver clr)
Resolves an identifier macro.
|
void |
setObjectIsInsertedToLevel(org.datanucleus.state.ObjectProvider op,
DatastoreClass table)
Method to set that the specified object is inserted down to the defined datastore class.
|
boolean |
supportsQueryLanguage(String language) |
boolean |
supportsValueGenerationStrategy(String strategy)
Accessor for whether this value strategy is supported.
|
void |
unmanageAllClasses(org.datanucleus.ClassLoaderResolver clr)
Utility to remove all classes that we are managing.
|
boolean |
useBackedSCOWrapperForMember(org.datanucleus.metadata.AbstractMemberMetaData mmd,
org.datanucleus.ExecutionContext ec) |
boolean |
usesBackedSCOWrappers() |
void |
validateSchemaForClasses(Set<String> inputClassNames,
Properties props) |
void |
validateTable(TableImpl table,
org.datanucleus.ClassLoaderResolver clr)
Utility to validate the specified table.
|
deregisterAllStoreData, getApiAdapter, getBooleanObjectProperty, getBooleanProperty, getBooleanProperty, getConnectionManager, getConnectionPassword, getExtent, getFlushProcess, getIntProperty, getMetaDataManager, getNamingFactory, getNucleusContext, getPersistenceHandler, getProperty, getQueryManager, getSchemaHandler, getStoreDataForClass, getStoreManagerKey, getStringProperty, getSubClassesForClass, getValueGenerationManager, getValueGenerationStrategyValue, getValueGeneratorForMember, hasProperty, isValueGenerationStrategyDatastoreAttributed, manageClassForIdentity, managesClass, newStoreData, registerConnectionMgr, registerStoreData, unmanageClass
getFrequentProperties, hasPropertyNotNull, setPropertyInternal
public static final String METADATA_NONDURABLE_REQUIRES_TABLE
protected DatastoreAdapter dba
protected IdentifierFactory identifierFactory
protected String catalogName
protected String schemaName
protected MappingManager mappingManager
protected Map<org.datanucleus.state.ObjectProvider,DatastoreClass> insertedDatastoreClassByObjectProvider
protected ReadWriteLock schemaLock
protected SQLExpressionFactory expressionFactory
public RDBMSStoreManager(org.datanucleus.ClassLoaderResolver clr, org.datanucleus.PersistenceNucleusContext ctx, Map<String,Object> props)
clr
- the ClassLoaderResolverctx
- The corresponding Context. This factory's non-tx data source will be used to get database connections as needed to perform management functions.props
- Properties for the datastoreorg.datanucleus.exceptions.NucleusDataStoreException
- If the database could not be accessed or the name of the schema could not be determined.public String getQueryCacheKey()
getQueryCacheKey
in interface org.datanucleus.store.StoreManager
protected void initialiseIdentifierFactory(org.datanucleus.NucleusContext nucleusContext)
nucleusContext
- contextpublic IdentifierFactory getIdentifierFactory()
public DatastoreAdapter getDatastoreAdapter()
public MappingManager getMappingManager()
public String getDefaultObjectProviderClassName()
getDefaultObjectProviderClassName
in interface org.datanucleus.store.StoreManager
getDefaultObjectProviderClassName
in class org.datanucleus.store.AbstractStoreManager
public org.datanucleus.store.StoreData[] getStoreDataForDatastoreContainerObject(DatastoreIdentifier tableIdentifier)
tableIdentifier
- Identifier for the tablepublic Table getTable(org.datanucleus.metadata.AbstractMemberMetaData mmd)
mmd
- The metadata for the field.public DatastoreClass getDatastoreClass(String className, org.datanucleus.ClassLoaderResolver clr)
manageClasses(org.datanucleus.ClassLoaderResolver, java.lang.String...)
is called
to add it. Classes which have inheritance strategy of "new-table" and
"superclass-table" will return a table here, whereas "subclass-table" will
return null since it doesn't have a table as such.
className
- Name of the class whose table is be returned.clr
- The ClassLoaderResolverNoTableManagedException
- If the given class has no table managed in the database.public DatastoreClass getDatastoreClass(DatastoreIdentifier name)
name
- The identifier name of the table.public org.datanucleus.metadata.AbstractClassMetaData[] getClassesManagingTableForClass(org.datanucleus.metadata.AbstractClassMetaData cmd, org.datanucleus.ClassLoaderResolver clr)
cmd
- The supplied class.clr
- ClassLoader resolverpublic boolean isObjectInserted(org.datanucleus.state.ObjectProvider op, int fieldNumber)
op
- ObjectProvider for the objectfieldNumber
- (Absolute) field number for the objectpublic boolean isObjectInserted(org.datanucleus.state.ObjectProvider op, String className)
op
- ObjectProvider for the objectclassName
- Name of class that we want to check the insertion level for.public void setObjectIsInsertedToLevel(org.datanucleus.state.ObjectProvider op, DatastoreClass table)
op
- ObjectProvider for the objecttable
- Table to which it is now insertedpublic org.datanucleus.store.types.scostore.Store getExistingBackingStoreForMember(org.datanucleus.metadata.AbstractMemberMetaData mmd)
public org.datanucleus.store.types.scostore.Store getBackingStoreForField(org.datanucleus.ClassLoaderResolver clr, org.datanucleus.metadata.AbstractMemberMetaData mmd, Class type)
getBackingStoreForField
in interface org.datanucleus.store.BackedSCOStoreManager
clr
- The ClassLoaderResolvermmd
- metadata for the member to be persisted by this Storetype
- instantiated type or prefered typepublic String getDefaultIdentifierCase()
public org.datanucleus.util.MultiMap getSchemaCallbacks()
public void addSchemaCallback(String className, org.datanucleus.metadata.AbstractMemberMetaData mmd)
public boolean isJdbcStore()
isJdbcStore
in interface org.datanucleus.store.StoreManager
isJdbcStore
in class org.datanucleus.store.AbstractStoreManager
public String getNativeQueryLanguage()
getNativeQueryLanguage
in interface org.datanucleus.store.StoreManager
public Collection<String> getSupportedQueryLanguages()
getSupportedQueryLanguages
in interface org.datanucleus.store.StoreManager
getSupportedQueryLanguages
in class org.datanucleus.store.AbstractStoreManager
public boolean supportsQueryLanguage(String language)
supportsQueryLanguage
in interface org.datanucleus.store.StoreManager
supportsQueryLanguage
in class org.datanucleus.store.AbstractStoreManager
public org.datanucleus.store.query.Query newQuery(String language, org.datanucleus.ExecutionContext ec)
newQuery
in interface org.datanucleus.store.StoreManager
public org.datanucleus.store.query.Query newQuery(String language, org.datanucleus.ExecutionContext ec, String queryString)
newQuery
in interface org.datanucleus.store.StoreManager
public org.datanucleus.store.query.Query newQuery(String language, org.datanucleus.ExecutionContext ec, org.datanucleus.store.query.Query q)
newQuery
in interface org.datanucleus.store.StoreManager
protected void logConfiguration()
logConfiguration
in class org.datanucleus.store.AbstractStoreManager
public void close()
close
in interface org.datanucleus.store.StoreManager
close
in class org.datanucleus.store.AbstractStoreManager
public org.datanucleus.store.NucleusSequence getNucleusSequence(org.datanucleus.ExecutionContext ec, org.datanucleus.metadata.SequenceMetaData seqmd)
getNucleusSequence
in interface org.datanucleus.store.StoreManager
ec
- execution contextseqmd
- SequenceMetaDatapublic org.datanucleus.store.NucleusConnection getNucleusConnection(org.datanucleus.ExecutionContext ec)
getNucleusConnection
in interface org.datanucleus.store.StoreManager
getNucleusConnection
in class org.datanucleus.store.AbstractStoreManager
ec
- execution contextpublic SQLController getSQLController()
public SQLExpressionFactory getSQLExpressionFactory()
public String getCatalogName()
public String getSchemaName()
public Date getDatastoreDate()
getDatastoreDate
in interface org.datanucleus.store.StoreManager
public void manageClasses(org.datanucleus.ClassLoaderResolver clr, String... classNames)
manageClasses
in interface org.datanucleus.store.StoreManager
manageClasses
in class org.datanucleus.store.AbstractStoreManager
clr
- The ClassLoaderResolverclassNames
- Name of the class(es) to be added.public void unmanageAllClasses(org.datanucleus.ClassLoaderResolver clr)
unmanageAllClasses
in interface org.datanucleus.store.StoreManager
unmanageAllClasses
in class org.datanucleus.store.AbstractStoreManager
clr
- The ClassLoaderResolverpublic Writer getDdlWriter()
public boolean getCompleteDDL()
public boolean hasWrittenDdlStatement(String stmt)
stmt
- The statementpublic void addWrittenDdlStatement(String stmt)
stmt
- The statementpublic void validateTable(TableImpl table, org.datanucleus.ClassLoaderResolver clr)
table
- The table to validateclr
- The ClassLoaderResolverpublic String getClassNameForObjectID(Object id, org.datanucleus.ClassLoaderResolver clr, org.datanucleus.ExecutionContext ec)
getClassNameForObjectID
in interface org.datanucleus.store.StoreManager
getClassNameForObjectID
in class org.datanucleus.store.AbstractStoreManager
id
- The identity of some object.clr
- ClassLoader resolverec
- execution context (optional - to allow check inheritance level in datastore)public Object getResultValueAtPosition(ResultSet rs, JavaTypeMapping mapping, int position)
rs
- The resultsmapping
- The mappingposition
- The position in the resultsorg.datanucleus.exceptions.NucleusDataStoreException
- if an error occurs accessing the resultsprotected Object getNextValueForValueGenerator(org.datanucleus.store.valuegenerator.ValueGenerator generator, org.datanucleus.ExecutionContext ec)
getNextValueForValueGenerator
in class org.datanucleus.store.AbstractStoreManager
generator
- The generatorec
- execution contextprotected Properties getPropertiesForValueGenerator(org.datanucleus.metadata.AbstractClassMetaData cmd, int absoluteFieldNumber, org.datanucleus.ClassLoaderResolver clr, org.datanucleus.metadata.SequenceMetaData seqmd, org.datanucleus.metadata.TableGeneratorMetaData tablegenmd)
getPropertiesForValueGenerator
in class org.datanucleus.store.AbstractStoreManager
cmd
- MetaData for the classabsoluteFieldNumber
- Number of the field (-1 = datastore identity)clr
- ClassLoader resolverseqmd
- Any sequence metadatatablegenmd
- Any table generator metadatapublic boolean supportsValueGenerationStrategy(String strategy)
supportsValueGenerationStrategy
in interface org.datanucleus.store.StoreManager
supportsValueGenerationStrategy
in class org.datanucleus.store.AbstractStoreManager
strategy
- The strategypublic String getValueGenerationStrategyForNative(org.datanucleus.metadata.AbstractClassMetaData cmd, int absFieldNumber)
getValueGenerationStrategyForNative
in interface org.datanucleus.store.StoreManager
getValueGenerationStrategyForNative
in class org.datanucleus.store.AbstractStoreManager
public SQLTypeInfo getSQLTypeInfoForJDBCType(int jdbcType) throws UnsupportedDataTypeException
jdbcType
- JDBC typeUnsupportedDataTypeException
- If the JDBC type is not foundpublic SQLTypeInfo getSQLTypeInfoForJDBCType(int jdbcType, String sqlType) throws UnsupportedDataTypeException
jdbcType
- JDBC typesqlType
- The SQL type name (if known, otherwise uses the default for this JDBC type).UnsupportedDataTypeException
- If the JDBC type is not foundpublic RDBMSColumnInfo getColumnInfoForColumnName(Table table, Connection conn, DatastoreIdentifier column) throws SQLException
Where possible, this method loads and caches column info for more than just the table being requested, improving performance by reducing the overall number of calls made to DatabaseMetaData.getColumns() (each of which usually results in one or more database queries).
table
- The table/viewconn
- JDBC connection to the database.column
- the columnSQLException
- Thrown if an error occurspublic List<org.datanucleus.store.schema.StoreSchemaData> getColumnInfoForTable(Table table, Connection conn) throws SQLException
Where possible, this method loads and caches column info for more than just the table being requested, improving performance by reducing the overall number of calls made to DatabaseMetaData.getColumns() (each of which usually results in one or more database queries).
table
- The table/viewconn
- JDBC connection to the database.SQLException
- Thrown if an error occurspublic void invalidateColumnInfoForTable(Table table)
table
- The tablepublic Collection<Table> getManagedTables(String catalog, String schema)
catalog
- Name of the catalog to restrict the collection by (or null to not restrict)schema
- Name of the schema to restrict the collection by (or null to not restrict)public void resolveIdentifierMacro(org.datanucleus.util.MacroString.IdentifierMacro im, org.datanucleus.ClassLoaderResolver clr)
im
- The macro to resolve.clr
- The ClassLoaderResolverpublic void printInformation(String category, PrintStream ps) throws Exception
printInformation
in interface org.datanucleus.store.StoreManager
printInformation
in class org.datanucleus.store.AbstractStoreManager
category
- Category of informationps
- PrintStreamException
- Thrown if an error occurs in the output processpublic Table newJoinTable(Table ownerTable, org.datanucleus.metadata.AbstractMemberMetaData mmd, org.datanucleus.ClassLoaderResolver clr)
ownerTable
- The table that owns this member.mmd
- The metadata describing the field/property.clr
- The ClassLoaderResolverpublic void registerTableInitialized(Table table)
public Collection getSupportedOptions()
getSupportedOptions
in interface org.datanucleus.store.StoreManager
getSupportedOptions
in class org.datanucleus.store.AbstractStoreManager
public boolean insertValuesOnInsert(DatastoreMapping datastoreMapping)
datastoreMapping
- The datastore mappingpublic boolean allowsBatching()
public boolean usesBackedSCOWrappers()
usesBackedSCOWrappers
in interface org.datanucleus.store.StoreManager
public boolean useBackedSCOWrapperForMember(org.datanucleus.metadata.AbstractMemberMetaData mmd, org.datanucleus.ExecutionContext ec)
useBackedSCOWrapperForMember
in interface org.datanucleus.store.StoreManager
useBackedSCOWrapperForMember
in class org.datanucleus.store.AbstractStoreManager
public Calendar getCalendarForDateTimezone()
public void createDatabase(String catalogName, String schemaName, Properties props)
createDatabase
in interface org.datanucleus.store.schema.SchemaAwareStoreManager
public void deleteDatabase(String catalogName, String schemaName, Properties props)
deleteDatabase
in interface org.datanucleus.store.schema.SchemaAwareStoreManager
public void createSchemaForClasses(Set<String> inputClassNames, Properties props)
createSchemaForClasses
in interface org.datanucleus.store.schema.SchemaAwareStoreManager
protected void createSchemaSequences(Set<String> classNames, org.datanucleus.ClassLoaderResolver clr, FileWriter ddlWriter)
protected void addSequenceTableForMetaData(org.datanucleus.metadata.MetaData md, org.datanucleus.ClassLoaderResolver clr, Set<String> seqTablesGenerated)
protected void addSequenceForMetaData(org.datanucleus.metadata.MetaData md, String seq, org.datanucleus.ClassLoaderResolver clr, Set<String> sequencesGenerated, FileWriter ddlWriter)
public void deleteSchemaForClasses(Set<String> inputClassNames, Properties props)
deleteSchemaForClasses
in interface org.datanucleus.store.schema.SchemaAwareStoreManager
public void validateSchemaForClasses(Set<String> inputClassNames, Properties props)
validateSchemaForClasses
in interface org.datanucleus.store.schema.SchemaAwareStoreManager
public void executeScript(String script)
executeScript
in interface org.datanucleus.store.schema.SchemaScriptAwareStoreManager
protected static Set<String> cleanInputClassNames(org.datanucleus.NucleusContext ctx, Set<String> inputClassNames)
ctx
- NucleusContextinputClassNames
- Class names to start fromCopyright © 2019. All rights reserved.