|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ujac.util.db.DatabaseSchemaReader
public class DatabaseSchemaReader
Name: DatabaseSchemaReader
Description: Reads informations from database schema using DatabaseMetaData.
| Constructor Summary | |
|---|---|
DatabaseSchemaReader(Connection cxn)
Constructs a DatabaseSchemaReader with specific attributes. |
|
DatabaseSchemaReader(Connection cxn,
DataTypeMapper dataTypeMapper)
Constructs a DatabaseSchemaReader with specific attributes. |
|
DatabaseSchemaReader(String driver,
String url,
String user,
String passwd)
Constructs a DatabaseSchemaReader with specific attributes. |
|
DatabaseSchemaReader(String driver,
String url,
String user,
String passwd,
DataTypeMapper dataTypeMapper)
Constructs a DatabaseSchemaReader with specific attributes. |
|
| Method Summary | |
|---|---|
static String |
getJavaName(String columnName)
Gets the java attribute name for the given column name. |
TableDefinition |
getTableDefinition(String tableName)
Gets the definition for the given table name. |
static void |
main(String[] args)
The main method for testing purposes. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DatabaseSchemaReader(Connection cxn)
cxn - The database connection to use.
public DatabaseSchemaReader(Connection cxn,
DataTypeMapper dataTypeMapper)
cxn - The database connection to use.dataTypeMapper - The data type mapper to use.
public DatabaseSchemaReader(String driver,
String url,
String user,
String passwd)
driver - The driver class name.url - The JDBC URL.user - The database user.passwd - The user's password.
public DatabaseSchemaReader(String driver,
String url,
String user,
String passwd,
DataTypeMapper dataTypeMapper)
driver - The driver class name.url - The JDBC URL.user - The database user.passwd - The user's password.dataTypeMapper - The data type mapper to use.| Method Detail |
|---|
public TableDefinition getTableDefinition(String tableName)
throws SQLException
tableName - The name of the desired table.
SQLException - In case a JDBC problem occurred.public static final String getJavaName(String columnName)
columnName - The column name.
public static void main(String[] args)
args - The command line arguments.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||