|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--snap.database.DatabaseSchema
This class retrieves schema information from the database.
Field Summary | |
static int |
MANY_TO_ONE
|
static int |
NO_RELATION
|
static int |
ONE_TO_MANY
|
static int |
ONE_TO_ONE
|
Constructor Summary | |
DatabaseSchema(java.sql.Connection connection)
This is the default constructor for the DatabaseSchema object |
Method Summary | |
java.util.Vector |
getColumns(java.lang.String table)
Returns a Vector of column names for a given table |
java.lang.String |
getPrimaryKey(java.lang.String table)
Gets the primary key for a particular table. |
int |
getRelation(java.lang.String tableSrc,
java.lang.String tableDest)
Check from hashtable and return the relation. |
java.util.Vector |
getTables()
Returns a Vector of table names |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int NO_RELATION
public static final int ONE_TO_ONE
public static final int ONE_TO_MANY
public static final int MANY_TO_ONE
Constructor Detail |
public DatabaseSchema(java.sql.Connection connection)
Method Detail |
public java.lang.String getPrimaryKey(java.lang.String table)
public java.util.Vector getTables()
public java.util.Vector getColumns(java.lang.String table)
public int getRelation(java.lang.String tableSrc, java.lang.String tableDest)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |