|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.ddlutils.platform.DatabaseMetaDataWrapper
public class DatabaseMetaDataWrapper
Wrapper class for database meta data that stores additional info.
Constructor Summary | |
---|---|
DatabaseMetaDataWrapper()
|
Method Summary | |
---|---|
java.lang.String |
getCatalog()
Returns the catalog in the database to read. |
java.sql.ResultSet |
getColumns(java.lang.String tableNamePattern,
java.lang.String columnNamePattern)
Convenience method to return the column meta data using the configured catalog and schema pattern. |
java.sql.ResultSet |
getForeignKeys(java.lang.String tableNamePattern)
Convenience method to return the foreign key meta data using the configured catalog and schema pattern. |
java.sql.ResultSet |
getIndices(java.lang.String tableNamePattern,
boolean unique,
boolean approximate)
Convenience method to return the index meta data using the configured catalog and schema pattern. |
java.sql.DatabaseMetaData |
getMetaData()
Returns the database meta data. |
java.sql.ResultSet |
getPrimaryKeys(java.lang.String tableNamePattern)
Convenience method to return the primary key meta data using the configured catalog and schema pattern. |
java.lang.String |
getSchemaPattern()
Returns the schema in the database to read. |
java.sql.ResultSet |
getTables(java.lang.String tableNamePattern)
Convenience method to return the table meta data using the configured catalog, schema pattern and table types. |
java.lang.String[] |
getTableTypes()
Returns the table types to recognize. |
void |
setCatalog(java.lang.String catalog)
Sets the catalog in the database to read. |
void |
setMetaData(java.sql.DatabaseMetaData metaData)
Sets the database meta data. |
void |
setSchemaPattern(java.lang.String schema)
Sets the schema in the database to read. |
void |
setTableTypes(java.lang.String[] types)
Sets the table types to recognize. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DatabaseMetaDataWrapper()
Method Detail |
---|
public java.sql.DatabaseMetaData getMetaData()
public void setMetaData(java.sql.DatabaseMetaData metaData)
metaData
- The meta datapublic java.lang.String getCatalog()
public void setCatalog(java.lang.String catalog)
catalog
- The catalogpublic java.lang.String getSchemaPattern()
public void setSchemaPattern(java.lang.String schema)
schema
- The schemapublic java.lang.String[] getTableTypes()
public void setTableTypes(java.lang.String[] types)
types
- The table typespublic java.sql.ResultSet getTables(java.lang.String tableNamePattern) throws java.sql.SQLException
tableNamePattern
- The pattern identifying for which tables to return info
java.sql.SQLException
- If an error occurred retrieving the meta dataDatabaseMetaData.getTables(java.lang.String, java.lang.String, java.lang.String, java.lang.String[])
public java.sql.ResultSet getColumns(java.lang.String tableNamePattern, java.lang.String columnNamePattern) throws java.sql.SQLException
tableNamePattern
- The pattern identifying for which tables to return infocolumnNamePattern
- The pattern identifying for which columns to return info
java.sql.SQLException
- If an error occurred retrieving the meta dataDatabaseMetaData.getColumns(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
public java.sql.ResultSet getPrimaryKeys(java.lang.String tableNamePattern) throws java.sql.SQLException
tableNamePattern
- The pattern identifying for which tables to return info
java.sql.SQLException
- If an error occurred retrieving the meta dataDatabaseMetaData.getPrimaryKeys(java.lang.String, java.lang.String, java.lang.String)
public java.sql.ResultSet getForeignKeys(java.lang.String tableNamePattern) throws java.sql.SQLException
tableNamePattern
- The pattern identifying for which tables to return info
java.sql.SQLException
- If an error occurred retrieving the meta dataDatabaseMetaData.getImportedKeys(java.lang.String, java.lang.String, java.lang.String)
public java.sql.ResultSet getIndices(java.lang.String tableNamePattern, boolean unique, boolean approximate) throws java.sql.SQLException
tableNamePattern
- The pattern identifying for which tables to return infounique
- Whether to return only indices for unique valuesapproximate
- Whether the result is allowed to reflect approximate or out of data values
java.sql.SQLException
- If an error occurred retrieving the meta dataDatabaseMetaData.getIndexInfo(java.lang.String, java.lang.String, java.lang.String, boolean, boolean)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |