public class DatabaseInformationImpl extends Object implements DatabaseInformation, ExtractionContext.DatabaseObjectAccess
Constructor and Description |
---|
DatabaseInformationImpl(ServiceRegistry serviceRegistry,
JdbcEnvironment jdbcEnvironment,
JdbcConnectionAccess jdbcConnectionAccess,
Identifier defaultCatalogName,
Identifier defaultSchemaName) |
Modifier and Type | Method and Description |
---|---|
boolean |
catalogExists(Identifier catalog)
Check to see if the given catalog already exists.
|
void |
cleanup() |
SequenceInformation |
getSequenceInformation(Identifier catalogName,
Identifier schemaName,
Identifier sequenceName)
Obtain reference to the named SequenceInformation
|
SequenceInformation |
getSequenceInformation(Namespace.Name schemaName,
Identifier sequenceName)
Obtain reference to the named SequenceInformation
|
SequenceInformation |
getSequenceInformation(QualifiedSequenceName qualifiedSequenceName)
Obtain reference to the named SequenceInformation
|
TableInformation |
getTableInformation(Identifier catalogName,
Identifier schemaName,
Identifier tableName)
Obtain reference to the named TableInformation
|
TableInformation |
getTableInformation(Namespace.Name schemaName,
Identifier tableName)
Obtain reference to the named TableInformation
|
TableInformation |
getTableInformation(QualifiedTableName qualifiedTableName)
Obtain reference to the named TableInformation
|
SequenceInformation |
locateSequenceInformation(QualifiedSequenceName sequenceName) |
TableInformation |
locateTableInformation(QualifiedTableName tableName) |
void |
registerTable(TableInformation tableInformation) |
boolean |
schemaExists(Namespace.Name schema)
Check to see if the given schema already exists.
|
public DatabaseInformationImpl(ServiceRegistry serviceRegistry, JdbcEnvironment jdbcEnvironment, JdbcConnectionAccess jdbcConnectionAccess, Identifier defaultCatalogName, Identifier defaultSchemaName) throws SQLException
SQLException
public boolean schemaExists(Namespace.Name schema)
DatabaseInformation
schemaExists
in interface DatabaseInformation
schema
- The schema nametrue
indicates a schema with the given name already existspublic TableInformation getTableInformation(Identifier catalogName, Identifier schemaName, Identifier tableName)
DatabaseInformation
getTableInformation
in interface DatabaseInformation
catalogName
- The name of the catalog which contains the schema which the table belongs toschemaName
- The name of the schema the table belongs totableName
- The table namenull
if not found.public TableInformation getTableInformation(Namespace.Name schemaName, Identifier tableName)
DatabaseInformation
getTableInformation
in interface DatabaseInformation
schemaName
- The name of the schema the table belongs totableName
- The table namenull
if not found.public TableInformation getTableInformation(QualifiedTableName qualifiedTableName)
DatabaseInformation
getTableInformation
in interface DatabaseInformation
qualifiedTableName
- The qualfied table namenull
if not found.public void registerTable(TableInformation tableInformation)
registerTable
in interface DatabaseInformation
public SequenceInformation getSequenceInformation(Identifier catalogName, Identifier schemaName, Identifier sequenceName)
DatabaseInformation
getSequenceInformation
in interface DatabaseInformation
catalogName
- The name of the catalog which contains the schema which the sequence belongs toschemaName
- The name of the schema the sequence belongs tosequenceName
- The sequence namenull
if not found.public SequenceInformation getSequenceInformation(Namespace.Name schemaName, Identifier sequenceName)
DatabaseInformation
getSequenceInformation
in interface DatabaseInformation
schemaName
- The name of the schema the table belongs tosequenceName
- The sequence namenull
if not found.public SequenceInformation getSequenceInformation(QualifiedSequenceName qualifiedSequenceName)
DatabaseInformation
getSequenceInformation
in interface DatabaseInformation
qualifiedSequenceName
- The qualified sequence namenull
if not found.public boolean catalogExists(Identifier catalog)
DatabaseInformation
catalogExists
in interface DatabaseInformation
catalog
- The catalog nametrue
indicates a catalog with the given name already existspublic TableInformation locateTableInformation(QualifiedTableName tableName)
locateTableInformation
in interface ExtractionContext.DatabaseObjectAccess
public SequenceInformation locateSequenceInformation(QualifiedSequenceName sequenceName)
locateSequenceInformation
in interface ExtractionContext.DatabaseObjectAccess
public void cleanup()
cleanup
in interface DatabaseInformation
Copyright © 2001-2017 Red Hat, Inc. All Rights Reserved.