|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jpox.store.rdbms.table.AbstractTable
org.jpox.store.rdbms.table.TableImpl
org.jpox.store.rdbms.table.SchemaTable
public class SchemaTable
Class defining JPOX schema definition tables. Represents a table in the datastore storing the class and table mappings. This table is used when restarting a JPOX system so that it is 'aware' of what classes were supported the previous time this datastore was used. It uses this information to pre-populate the RDBMSManager with the classes stored in this table. The table names are not used as such, other than as a record of what table a class maps to - because it goes off and finds the MetaData for the class which, with the JPOX naming scheme, defines the table name anyway.
| Field Summary |
|---|
| Fields inherited from class org.jpox.store.rdbms.table.AbstractTable |
|---|
columns, columnsByName, completeDdl, dba, ddlWriter, existsInDatastore, identifier, LOCALISER, state, storeMgr |
| Fields inherited from interface org.jpox.store.rdbms.table.Table |
|---|
TABLE_STATE_INITIALIZED, TABLE_STATE_INITIALIZED_MODIFIED, TABLE_STATE_NEW, TABLE_STATE_PK_INITIALIZED, TABLE_STATE_VALIDATED, TABLE_TYPE_MISSING, TABLE_TYPE_TABLE, TABLE_TYPE_UNKNOWN, TABLE_TYPE_VIEW |
| Constructor Summary | |
|---|---|
SchemaTable(RDBMSManager storeMgr,
java.lang.String tableName)
Constructor. |
|
| Method Summary | |
|---|---|
void |
addClass(org.jpox.store.mapped.MappedStoreData data,
org.jpox.ManagedConnection conn)
Method to insert a row in the SchemaTable. |
void |
deleteAllClasses(org.jpox.ManagedConnection conn)
Method to delete all classes from the SchemaTable. |
void |
deleteClass(java.lang.String class_name,
org.jpox.ManagedConnection conn)
Method to delete a class from the SchemaTable. |
java.util.HashSet |
getAllClasses(org.jpox.ManagedConnection conn)
Accessor for the classes already supported by this Schema Table. |
org.jpox.store.mapped.mapping.JavaTypeMapping |
getFieldMapping(org.jpox.metadata.AbstractMemberMetaData fmd)
Accessor the for the mapping for a field store in this table |
org.jpox.store.mapped.mapping.JavaTypeMapping |
getIDMapping()
Accessor for a mapping for the ID (PersistenceCapable) for this table. |
void |
initialize(org.jpox.ClassLoaderResolver clr)
Method to initialise the table. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SchemaTable(RDBMSManager storeMgr,
java.lang.String tableName)
storeMgr - The RDBMSManager for this datastoretableName - Name of the starter table (optional, uses JPOX_TABLES when this is null)| Method Detail |
|---|
public void initialize(org.jpox.ClassLoaderResolver clr)
clr - The ClassLoaderResolverpublic org.jpox.store.mapped.mapping.JavaTypeMapping getIDMapping()
public java.util.HashSet getAllClasses(org.jpox.ManagedConnection conn)
throws java.sql.SQLException
conn - Connection for this datastore.
java.sql.SQLException - Thrown when an error occurs in the process.
public void addClass(org.jpox.store.mapped.MappedStoreData data,
org.jpox.ManagedConnection conn)
throws java.sql.SQLException
data - Data for the classconn - Connection to the datastore
java.sql.SQLException - Thrown when an error occurs inserting the schema.
public void deleteClass(java.lang.String class_name,
org.jpox.ManagedConnection conn)
throws java.sql.SQLException
class_name - Name of class to deleteconn - Connection to the datastore
java.sql.SQLException - Thrown when an error occurs deleting the schema.
public void deleteAllClasses(org.jpox.ManagedConnection conn)
throws java.sql.SQLException
conn - Connection to the datastore
java.sql.SQLException - Thrown when an error occurs deleting the schema.public org.jpox.store.mapped.mapping.JavaTypeMapping getFieldMapping(org.jpox.metadata.AbstractMemberMetaData fmd)
fmd - MetaData for the field whose mapping we want
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||