|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sourceforge.jdbcimporter.ColumnDef
The ColumnDef class defines a column in an entity.
Field Summary | |
static java.lang.String |
DATE_FORMAT
The date format. |
static java.lang.String |
DECIMAL_FORMAT
The decimal format. |
static java.lang.String |
FULL_NUMBER_FORMAT
The integer/long format. |
static java.lang.String |
TIME_FORMAT
The time format. |
static java.lang.String |
TIMESTAMP_FORMAT
The timestamp format. |
static int |
UNKNOWN_SQL_TYPE
Constant that indicates that the column's SQL Type is unknown. |
Constructor Summary | |
ColumnDef()
|
Method Summary | |
void |
addProperty(java.lang.String key,
java.lang.String value)
Add a property that is associated with the column def. |
protected int |
convertStringToSQLType(java.lang.String sqlString)
Converts the name (case-insensitive) of a static variable defined in java.sql.Types into the value of the static variable. |
protected void |
createFormat()
Create the format based on the SQL type and the pattern. |
java.lang.String |
getDefaultValue()
Returns the default value of the column. |
java.text.Format |
getFormat()
Returns the format used when parsing the data in the file. |
java.lang.String |
getFormatPattern()
Returns the format pattern used when parsing the data in the file. |
java.lang.String |
getName()
Returns the name of the column |
java.lang.String |
getProperty(java.lang.String key)
Returns the value of a property that is associated with the column def. |
int |
getType()
Returns the sql type of the column |
void |
setDefaultValue(java.lang.String newDefaultValue)
Sets the default value of the column. |
void |
setFormatPattern(java.lang.String pattern)
Sets the format pattern used when parsing the data in the file. |
void |
setName(java.lang.String newName)
Sets the name of the column. |
void |
setSQLType(java.lang.String newType)
Sets the sql type of the column. |
void |
setType(int newType)
Sets the sql type of the column |
java.lang.String |
toString()
Overrides Object.toString() |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int UNKNOWN_SQL_TYPE
public static final java.lang.String DATE_FORMAT
public static final java.lang.String TIME_FORMAT
public static final java.lang.String TIMESTAMP_FORMAT
public static final java.lang.String FULL_NUMBER_FORMAT
public static final java.lang.String DECIMAL_FORMAT
Constructor Detail |
public ColumnDef()
Method Detail |
public void setName(java.lang.String newName)
newName
- name of the columnpublic java.lang.String getName()
public void setSQLType(java.lang.String newType)
newType
- name (case-insensitive) of the sql type that equals
the name of a static variable defined in java.sql.Typespublic int getType()
public void setType(int newType)
newType
- value of a static variable defined in java.sql.Typespublic void setDefaultValue(java.lang.String newDefaultValue)
newDefaultValue
- default value for this columnpublic java.lang.String getDefaultValue()
public void setFormatPattern(java.lang.String pattern)
pattern
- the format patternpublic java.lang.String getFormatPattern()
public java.text.Format getFormat()
public void addProperty(java.lang.String key, java.lang.String value)
key
- the name of the propertyvalue
- the value of the propertypublic java.lang.String getProperty(java.lang.String key)
key
- the name of the property
protected int convertStringToSQLType(java.lang.String sqlString)
sqlString
- name of a static variable defined in java.sql.Typesprotected void createFormat()
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |