| java.lang.Object org.netbeans.modules.jdbcwizard.builder.dbmodel.impl.DBTableImpl
Inner Class :static class StringComparator implements Comparator | |
Constructor Summary | |
public | DBTableImpl(String aName, String aSchema, String aCatalog) Creates a new instance of DBTableImpl with the given name. | public | DBTableImpl(String aName, String aSchema, String aCatalog, String aType) Creates a new instance of DBTableImpl with the given name. | public | DBTableImpl(DBTable src) Creates a new instance of DBTableImpl, cloning the contents of the given DBTable
implementation instance. |
Method Summary | |
public boolean | addColumn(DBColumn theColumn) Adds a DBColumn instance to this table.
Parameters: theColumn - column to be added. | public boolean | addForeignKey(ForeignKeyImpl newFk) Adds the given ForeignKeyImpl, associating it with this DBTableImpl instance. | public boolean | addIndex(IndexImpl newIndex) Adds the given IndexImpl, associating it with this DBTableImpl instance. | public void | clearForeignKeys() Clears list of foreign keys. | public void | clearIndexes() Clears list of indexes. | public Object | clone() Clone a deep copy of DBTable. | public int | compareTo(Object refObj) Compares DBTable with another object for lexicographical ordering. | public void | copyFrom(DBTable source) Performs deep copy of contents of given DBTable. | public DBColumnImpl | createColumn(String columnName, int jdbcType, int scale, int precision, boolean isPK, boolean isFK, boolean isIndexed, boolean nullable) Convenience class to create DBColumnImpl instance (with the given column name, data source
name, JDBC type, scale, precision, and nullable), and add it to this DBTableImpl instance. | public boolean | deleteAllColumns() Deletes all columns associated with this table. | public boolean | deleteColumn(String columnName) Deletes DBColumn, if any, associated with the given name from this table.
Parameters: columnName - column name to be removed. | public boolean | equals(Object obj) Overrides default implementation to return value based on memberwise comparison. | public String | getCatalog() | public DBColumn | getColumn(String columnName) | public List | getColumnList() | public List | getColumnListInTablelOrder() Map of columns in the order the driver returns them. | public Map | getColumns() | public String | getDescription() | public ForeignKey | getForeignKey(String fkName) | public List | getForeignKeys() | public Index | getIndex(String indexName) | public List | getIndexes() | public int | getJDBCType(String dbType) | public String | getJavaName() Gets Java name for this table. | public String | getName() | public DatabaseModel | getParent() | public PrimaryKey | getPrimaryKey() | public ForeignKey | getReferenceFor(DBTable target) | public Set | getReferencedTables() | public String | getSQLType(int type) | public String | getSchema() | public String | getType() | public int | hashCode() Overrides default implementation to compute hashCode value for those members used in equals()
for comparison. | public boolean | isEditable() | public boolean | isSelected() | public boolean | isSelectedforAnOperation() | public boolean | references(DBTable pkTarget) | public boolean | removeForeignKey(ForeignKeyImpl oldKey) Dissociates the given ForeignKeyImpl from this DBTableImpl instance, removing it from its
internal FK collection. | public boolean | setAllColumns(Map theColumns) Clones contents of the given Map to this table's internal column map, overwriting any
previous mappings.
Parameters: theColumns - Map of columns to be substituted true if successful. | public void | setCatalog(String newCatalog) Sets catalog name to new value. | public void | setDescription(String newDesc) Sets description text for this instance. | public void | setEditable(boolean edit) | public void | setJavaName(String newName) Sets Java name for this table. | public void | setName(String newName) Sets table name to new value. | public void | setParent(DatabaseModelImpl newParent) Sets parent DatabaseModel to the given reference. | public boolean | setPrimaryKey(PrimaryKeyImpl newPk) Sets PrimaryKey instance for this DBTable to the given instance. | public void | setSchema(String newSchema) Sets schema name to new value. | public void | setSelected(boolean select) | public void | setSelectedforAllOperations(boolean setAll) | public void | setType(String newType) Sets type name to new value. |
catalog | protected String catalog(Code) | | catalog to which this table belongs.
|
columns | protected Map columns(Code) | | Map of column metadata.
|
columnsInTableOrder | protected ArrayList columnsInTableOrder(Code) | | Map of columns in the order the driver returns them. Order preserving to keep both JCE and
BPEL editors show the otd in the same way.
|
description | protected String description(Code) | | user-defined description
|
editable | protected boolean editable(Code) | | editable
|
foreignKeys | protected Map foreignKeys(Code) | | Map of names to ForeignKey instances for this table; may be empty.
|
indexes | protected Map indexes(Code) | | Map of names to Index instances for this table; may be empty.
|
javaName | protected String javaName(Code) | | Java name of this table; not in DatabaseModel but supplied as courtesy for WSDL
|
schema | protected String schema(Code) | | schema to which this table belongs.
|
selected | protected boolean selected(Code) | | selected
|
type | protected String type(Code) | | Type of this table, these are "TABLE" or "VIEW"
|
DBTableImpl | public DBTableImpl(String aName, String aSchema, String aCatalog)(Code) | | Creates a new instance of DBTableImpl with the given name.
Parameters: aName - name of new DBTable instance Parameters: aSchema - schema of new DBTable instance; may be null Parameters: aCatalog - catalog of new DBTable instance; may be null |
DBTableImpl | public DBTableImpl(String aName, String aSchema, String aCatalog, String aType)(Code) | | Creates a new instance of DBTableImpl with the given name.
Parameters: aName - name of new DBTable instance Parameters: aSchema - schema of new DBTable instance; may be null Parameters: aCatalog - catalog of new DBTable instance; may be null Parameters: aType - type of new DBTable instance; |
DBTableImpl | public DBTableImpl(DBTable src)(Code) | | Creates a new instance of DBTableImpl, cloning the contents of the given DBTable
implementation instance.
Parameters: src - DBTable instance to be cloned |
addColumn | public boolean addColumn(DBColumn theColumn)(Code) | | Adds a DBColumn instance to this table.
Parameters: theColumn - column to be added. true if successful. false if failed. |
addForeignKey | public boolean addForeignKey(ForeignKeyImpl newFk)(Code) | | Adds the given ForeignKeyImpl, associating it with this DBTableImpl instance.
Parameters: newFk - new ForeignKeyImpl instance to be added return true if addition succeeded, false otherwise |
addIndex | public boolean addIndex(IndexImpl newIndex)(Code) | | Adds the given IndexImpl, associating it with this DBTableImpl instance.
Parameters: newIndex - new IndexImpl instance to be added return true if addition succeeded, false otherwise |
clearForeignKeys | public void clearForeignKeys()(Code) | | Clears list of foreign keys.
|
clearIndexes | public void clearIndexes()(Code) | | Clears list of indexes.
|
clone | public Object clone()(Code) | | Clone a deep copy of DBTable.
a copy of DBTable. |
compareTo | public int compareTo(Object refObj)(Code) | | Compares DBTable with another object for lexicographical ordering. Null objects and those
DBTables with null names are placed at the end of any ordered collection using this method.
Parameters: refObj - Object to be compared. -1 if the column name is less than obj to be compared. 0 if the column name is thesame. 1 if the column name is greater than obj to be compared. |
copyFrom | public void copyFrom(DBTable source)(Code) | | Performs deep copy of contents of given DBTable. We deep copy (that is, the method clones all
child objects such as columns) because columns have a parent-child relationship that must be
preserved internally.
Parameters: source - JDBCTable providing contents to be copied. |
createColumn | public DBColumnImpl createColumn(String columnName, int jdbcType, int scale, int precision, boolean isPK, boolean isFK, boolean isIndexed, boolean nullable)(Code) | | Convenience class to create DBColumnImpl instance (with the given column name, data source
name, JDBC type, scale, precision, and nullable), and add it to this DBTableImpl instance.
Parameters: columnName - Column name Parameters: jdbcType - JDBC type defined in SQL.Types Parameters: scale - Scale Parameters: precision - Precision Parameters: nullable - Nullable new DBColumnImpl instance |
deleteAllColumns | public boolean deleteAllColumns()(Code) | | Deletes all columns associated with this table.
true if all columns were deleted successfully, false otherwise. |
deleteColumn | public boolean deleteColumn(String columnName)(Code) | | Deletes DBColumn, if any, associated with the given name from this table.
Parameters: columnName - column name to be removed. true if successful. false if failed. |
equals | public boolean equals(Object obj)(Code) | | Overrides default implementation to return value based on memberwise comparison.
Parameters: obj - Object against which we compare this instance true if obj is functionally identical to this JDBCTable instance; false otherwise |
getCatalog | public String getCatalog()(Code) | | See Also: com.stc.model.database.DBTable.getCatalog |
getColumn | public DBColumn getColumn(String columnName)(Code) | | Gets the DBColumn, if any, associated with the given name
Parameters: columnName - column name DBColumn associated with columnName, or null if none exists |
getColumnList | public List getColumnList()(Code) | | See Also: com.stc.model.database.DBTable.getColumnList |
getColumnListInTablelOrder | public List getColumnListInTablelOrder()(Code) | | Map of columns in the order the driver returns them. Order preserving to keep both JCE and
BPEL editors show the otd in the same way.
|
getColumns | public Map getColumns()(Code) | | See Also: com.stc.model.database.DBTable.getColumns |
getDescription | public String getDescription()(Code) | | See Also: com.stc.model.database.DBTable.getDescription |
getForeignKey | public ForeignKey getForeignKey(String fkName)(Code) | | See Also: com.stc.model.database.DBTable.getForeignKey(String) |
getForeignKeys | public List getForeignKeys()(Code) | | See Also: com.stc.model.database.DBTable.getForeignKeys |
getIndex | public Index getIndex(String indexName)(Code) | | See Also: com.stc.model.database.DBTable.getIndex |
getIndexes | public List getIndexes()(Code) | | See Also: com.stc.model.database.DBTable.getIndexes |
getJDBCType | public int getJDBCType(String dbType)(Code) | | Gets the JDBC Type for a given oracle8/oracle9 type
Parameters: dbType - for which jdbctype is returned java.sql.Types.* for given string jdbcType |
getJavaName | public String getJavaName()(Code) | | Gets Java name for this table.
normalized Java name for this table |
getName | public String getName()(Code) | | See Also: com.stc.model.database.DBTable.getName |
getParent | public DatabaseModel getParent()(Code) | | See Also: com.stc.model.database.DBTable.getParent |
getPrimaryKey | public PrimaryKey getPrimaryKey()(Code) | | See Also: com.stc.model.database.DBTable.getPrimaryKey |
getReferenceFor | public ForeignKey getReferenceFor(DBTable target)(Code) | | See Also: com.stc.model.database.DBTable.getReferenceFor |
getReferencedTables | public Set getReferencedTables()(Code) | | See Also: com.stc.model.database.DBTable.getReferencedTables |
getSQLType | public String getSQLType(int type)(Code) | | Gets the SQLType
Parameters: type - for which sql type is returned String for given jdbc type |
getSchema | public String getSchema()(Code) | | See Also: com.stc.model.database.DBTable.getSchema |
getType | public String getType()(Code) | | See Also: com.stc.model.database.DBTable.getType |
hashCode | public int hashCode()(Code) | | Overrides default implementation to compute hashCode value for those members used in equals()
for comparison.
hash code for this object See Also: java.lang.Object.hashCode |
isEditable | public boolean isEditable()(Code) | | Get editable
true/false |
isSelected | public boolean isSelected()(Code) | | |
isSelectedforAnOperation | public boolean isSelectedforAnOperation()(Code) | | |
references | public boolean references(DBTable pkTarget)(Code) | | See Also: com.stc.model.database.DBTable.references |
removeForeignKey | public boolean removeForeignKey(ForeignKeyImpl oldKey)(Code) | | Dissociates the given ForeignKeyImpl from this DBTableImpl instance, removing it from its
internal FK collection.
Parameters: newFk - new ForeignKeyImpl instance to be removed return true if removal succeeded, false otherwise |
setAllColumns | public boolean setAllColumns(Map theColumns)(Code) | | Clones contents of the given Map to this table's internal column map, overwriting any
previous mappings.
Parameters: theColumns - Map of columns to be substituted true if successful. false if failed. |
setCatalog | public void setCatalog(String newCatalog)(Code) | | Sets catalog name to new value.
Parameters: newCatalog - new value for catalog name |
setDescription | public void setDescription(String newDesc)(Code) | | Sets description text for this instance.
Parameters: newDesc - new descriptive text |
setEditable | public void setEditable(boolean edit)(Code) | | Set editable
Parameters: edit - - editable |
setJavaName | public void setJavaName(String newName)(Code) | | Sets Java name for this table.
Parameters: newName - new normalized Java name for this table; null if plain name is to be used. |
setName | public void setName(String newName)(Code) | | Sets table name to new value.
Parameters: newSchema - new value for schema name |
setParent | public void setParent(DatabaseModelImpl newParent)(Code) | | Sets parent DatabaseModel to the given reference.
Parameters: newParent - new DatabaseModel parent |
setPrimaryKey | public boolean setPrimaryKey(PrimaryKeyImpl newPk)(Code) | | Sets PrimaryKey instance for this DBTable to the given instance.
Parameters: newPk - new PrimaryKey instance to be associated true if association succeeded, false otherwise |
setSchema | public void setSchema(String newSchema)(Code) | | Sets schema name to new value.
Parameters: newSchema - new value for schema name |
setSelected | public void setSelected(boolean select)(Code) | | Parameters: select - |
setSelectedforAllOperations | public void setSelectedforAllOperations(boolean setAll)(Code) | | |
setType | public void setType(String newType)(Code) | | Sets type name to new value.
Parameters: newType - new value for type name |
|
|