| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.datatools.connectivity.sqm.loader.JDBCBaseLoader
org.eclipse.datatools.connectivity.sqm.loader.JDBCTableConstraintLoader
public class JDBCTableConstraintLoader
Base loader implementation for loading a table's constraint objects (e.g. PK, FK, etc.). This class may be specialized as necessary to meet a particular vendor's needs.
| Field Summary | |
|---|---|
| static java.lang.String | COLUMN_COLUMN_NAMEThe column name containing the column's name. | 
| static java.lang.String | COLUMN_DEFERRABILITYThe column name containing the constraint's deferrability. | 
| static java.lang.String | COLUMN_DELETE_RULEThe column name containing the constraint's delete rule. | 
| static java.lang.String | COLUMN_FK_NAMEThe column name containing the foreign key's name. | 
| static java.lang.String | COLUMN_FKCOLUMN_NAMEThe column name containing the foreign key's name. | 
| static java.lang.String | COLUMN_KEY_SEQThe column name containing the column's key sequence. | 
| static java.lang.String | COLUMN_PK_NAMEThe column name containing the primary key's name. | 
| static java.lang.String | COLUMN_PKCOLUMN_NAMEThe column name containing a primary key's column name. | 
| static java.lang.String | COLUMN_PKTABLE_CATThe column name containing the primary key's catalog. | 
| static java.lang.String | COLUMN_PKTABLE_NAMEThe column name containing the primary key's table. | 
| static java.lang.String | COLUMN_PKTABLE_SCHEMThe column name containing the primary key's schema. | 
| static java.lang.String | COLUMN_UPDATE_RULEThe column name containing the constraint's update rule. | 
| Constructor Summary | |
|---|---|
| JDBCTableConstraintLoader(ICatalogObject catalogObject)This constructs the loader using no filter. | |
| JDBCTableConstraintLoader(ICatalogObject catalogObject,
                          IConnectionFilterProvider connectionFilterProvider) | |
| Method Summary | |
|---|---|
|  void | clearConstraints(org.eclipse.emf.common.util.EList constraintContainer,
                 java.util.List remove)Removes the specified constraints from the model. | 
|  java.util.Collection | loadForeignKeys()Deprecated. see loadForeignKeys(List, Collection) | 
|  void | loadForeignKeys(java.util.List containmentList,
                java.util.Collection existingFKs)Loads the "foreign key" objects from the database. | 
|  PrimaryKey | loadPrimaryKey()Deprecated. see loadPrimaryKey(PrimaryKey) | 
|  PrimaryKey | loadPrimaryKey(PrimaryKey existingPK)Loads the "primary key" object from the database. | 
|  java.util.Collection | loadUniqueConstraints(PrimaryKey pk)Deprecated. see loadUniqueConstraints(PrimaryKey, List, Collection) | 
|  void | loadUniqueConstraints(PrimaryKey pk,
                      java.util.List containmentList,
                      java.util.Collection existingUCs)Loads the "unique constraint" objects from the database. | 
| Methods inherited from class org.eclipse.datatools.connectivity.sqm.loader.JDBCBaseLoader | 
|---|
| getCatalogObject, setCatalogObject | 
| Methods inherited from class java.lang.Object | 
|---|
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static final java.lang.String COLUMN_COLUMN_NAME
java.sql.DatabaseMetaData.getExportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_KEY_SEQ
java.sql.DatabaseMetaData.getExportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_PK_NAME
java.sql.DatabaseMetaData.getExportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_PKCOLUMN_NAME
java.sql.DatabaseMetaData.getExportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_PKTABLE_CAT
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_PKTABLE_SCHEM
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_PKTABLE_NAME
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_FKCOLUMN_NAME
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_UPDATE_RULE
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_DELETE_RULE
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_FK_NAME
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Valuespublic static final java.lang.String COLUMN_DEFERRABILITY
java.sql.DatabaseMetaData.getImportedKeys(), 
Constant Field Values| Constructor Detail | 
|---|
public JDBCTableConstraintLoader(ICatalogObject catalogObject)
catalogObject - the Table object upon which this loader operates.
public JDBCTableConstraintLoader(ICatalogObject catalogObject,
                                 IConnectionFilterProvider connectionFilterProvider)
catalogObject - the Catalog object upon which this loader operates.connectionFilterProvider - the filter provider used for filtering
        the "constraint" objects being loaded| Method Detail | 
|---|
public PrimaryKey loadPrimaryKey()
                          throws java.sql.SQLException
loadPrimaryKey(PrimaryKey)
java.sql.SQLException - if an error occurred during loading.
public PrimaryKey loadPrimaryKey(PrimaryKey existingPK)
                          throws java.sql.SQLException
existingPK - the existing primary key, if one exists.
java.sql.SQLException - if an error occurred during loading.
public java.util.Collection loadUniqueConstraints(PrimaryKey pk)
                                           throws java.sql.SQLException
loadUniqueConstraints(PrimaryKey, List, Collection)
pk - the table's primary key. Used to prevent duplicating the PK
        constraint.
java.sql.SQLException - if an error occurred during loading.
public void loadUniqueConstraints(PrimaryKey pk,
                                  java.util.List containmentList,
                                  java.util.Collection existingUCs)
                           throws java.sql.SQLException
pk - the table's primary key. Used to prevent duplicating the PK
        constraint.containmentList - the containment list held by parentexistingUCs - the catalog objects which were previously loaded
java.sql.SQLException - if an error occurred during loading.
public java.util.Collection loadForeignKeys()
                                     throws java.sql.SQLException
loadForeignKeys(List, Collection)
java.sql.SQLException - if an error occurred during loading.
public void loadForeignKeys(java.util.List containmentList,
                            java.util.Collection existingFKs)
                     throws java.sql.SQLException
containmentList - the containment list held by parentexistingFKs - the catalog objects which were previously loaded
java.sql.SQLException - if an error occurred during loading.
public void clearConstraints(org.eclipse.emf.common.util.EList constraintContainer,
                             java.util.List remove)
constraintContainer - the constraints containerremove - the constraints to remove.| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||