| java.lang.Object org.netbeans.modules.sql.project.dbmodel.TableColumn
TableColumn | public class TableColumn (Code) | | Captures metadata information for a database table column.
author: Susan Chen version: |
Constructor Summary | |
public | TableColumn() Constructs an instance of TableColumn. | public | TableColumn(String newName) Constructs an instance of TableColumn using the given name. | public | TableColumn(String newName, String newJavaType) Constructs an instance of TableColumn using the given name and
Java type. | public | TableColumn(String newName, String newJavaType, boolean newIsNullable, boolean newIsSelected, boolean newIsPrimaryKey, boolean newIsForeignKey, int newSqlTypeCode) Constructs a new instance of TableColumn using the given attributes. | public | TableColumn(TableColumn tCol) |
TableColumn | public TableColumn()(Code) | | Constructs an instance of TableColumn.
|
TableColumn | public TableColumn(String newName)(Code) | | Constructs an instance of TableColumn using the given name.
Parameters: newName - name of this new instance |
TableColumn | public TableColumn(String newName, String newJavaType)(Code) | | Constructs an instance of TableColumn using the given name and
Java type.
Parameters: newName - name of new instance Parameters: newJavaType - Java type of this new instance |
TableColumn | public TableColumn(String newName, String newJavaType, boolean newIsNullable, boolean newIsSelected, boolean newIsPrimaryKey, boolean newIsForeignKey, int newSqlTypeCode)(Code) | | Constructs a new instance of TableColumn using the given attributes.
Parameters: newName - name of new instance Parameters: newJavaType - Java type of new instance Parameters: newIsNullable - true if column is nullable, false otherwise Parameters: newIsSelected - true if column is selected, false otherwise Parameters: newIsPrimaryKey - true if column is PK, false otherwise Parameters: newIsForeignKey - true if column if FK, false otherwise Parameters: newSqlTypeCode - SQL type code as enumerated in java.sql.Types |
getDefaultValue | public String getDefaultValue()(Code) | | Gets String representation of default value for this column (may be
null).
default value, or null if none was defined |
getIsForeignKey | public boolean getIsForeignKey()(Code) | | Indicates whether column is foreign key
true if FK, false otherwise |
getIsNullable | public boolean getIsNullable()(Code) | | Indicates whether column is nullable
true if nullable, false otherwise |
getIsPrimaryKey | public boolean getIsPrimaryKey()(Code) | | Indicates whether column is primary key
true if PK, false otherwise |
getIsSelected | public boolean getIsSelected()(Code) | | Indicates whether column is selected
true if selected, false otherwise |
getJavaType | public String getJavaType()(Code) | | Gets Java type.
Java type |
getName | public String getName()(Code) | | Gets name of column.
name |
getNumericPrecision | public int getNumericPrecision()(Code) | | Gets precision (for numeric types) or maximum number of characters
(for char or date types).
numeric precision or maximum number of characters, as determinedby column type |
getNumericRadix | public int getNumericRadix()(Code) | | Gets radix (number base) of this column, e.g., 10 (decimal), 2 (binary).
Meaningful only for numeric columns.
numeric radix of column; meaningless for non-numeric columns |
getNumericScale | public int getNumericScale()(Code) | | Gets numeric scale of this column. Meaningful only for numeric columns.
numeric scale of column; meaningless for non-numeric columns |
getOrdinalPosition | public int getOrdinalPosition()(Code) | | Gets ordinal position of column among siblings in its table.
ordinal position |
getSqlType | public String getSqlType()(Code) | | Gets JDBC SQL type.
JDBC SQL type (as String) |
getSqlTypeCode | public int getSqlTypeCode()(Code) | | Gets SQL type code.
Parameters: newCode - SQL code |
getValue | public String getValue()(Code) | | Gets String representation of value for this column (may be
null).
value, or null if none was defined |
setDefaultValue | public void setDefaultValue(String newDefault)(Code) | | Sets default value, if any, of column.
Parameters: newDefault - default value; set to null to indicate that nodefault exists. |
setIsForeignKey | public void setIsForeignKey(boolean newIsForeignKey)(Code) | | Sets whether column is a foreign key. Note that multiple columns
may participate in a composite FK.
Parameters: newIsForeignKey - true if FK; false otherwise |
setIsNullable | public void setIsNullable(boolean newIsNullable)(Code) | | Sets nullability of column
Parameters: newIsNullable - true if nullable; false otherwise |
setIsPrimaryKey | public void setIsPrimaryKey(boolean newIsPrimaryKey)(Code) | | Sets whether column is a primary key. Note that multiple columns
may participate in a composite PK.
Parameters: newIsPrimaryKey - true if PK; false otherwise |
setIsSelected | public void setIsSelected(boolean newIsSelected)(Code) | | Sets selection state of column.
Parameters: newIsSelected - true if selected; false otherwise |
setJavaType | public void setJavaType(String newJavaType)(Code) | | Sets Java type of column.
Parameters: newJavaType - new Java type of column |
setName | public void setName(String newName)(Code) | | Sets column name.
Parameters: newName - new name of column |
setNumericPrecision | public void setNumericPrecision(int newNumericPrecision)(Code) | | Sets numeric precision or maximum character width of column.
Parameters: newNumericPrecision - new precision of column |
setNumericRadix | public void setNumericRadix(int newNumericRadix)(Code) | | Sets numeric radix of column.
Parameters: newNumericRadix - new radix of column |
setNumericScale | public void setNumericScale(int newNumericScale)(Code) | | Sets numeric scale of column.
Parameters: newNumericScale - new scale of column |
setOrdinalPosition | public void setOrdinalPosition(int newPosition)(Code) | | Sets ordinal position of column.
Parameters: newPosition - new ordinal position of column |
setSqlType | public void setSqlType(String newSqlType)(Code) | | Sets JDBC SQL type of column
Parameters: newSqlType - new JDBC SQL type (expressed as String representation) |
setSqlTypeCode | public void setSqlTypeCode(int newCode)(Code) | | Sets SQL type code.
Parameters: newCode - SQL code |
setValue | public void setValue(String newValue)(Code) | | Sets value, if any, of column.
Parameters: newDefault - default value; set to null to indicate that nodefault exists. |
|
|