com.jdbwc.core.util
Class SQLField

java.lang.Object
  extended by com.jdbwc.core.util.SQLField

public class SQLField
extends java.lang.Object


Constructor Summary
SQLField(int serverType, java.lang.String fieldName, java.lang.String typeName, boolean isNullable, java.lang.String mode)
          Constructs a new instance of a ParameterMetaData Field.
Create a new Field Object containing database metadata populated with the supplied parameters.
Data is fetched for use from the Field Object using its public get methods.
Field Objects are not designed to have thier contents altered once instantiated.
SQLField(int serverType, java.lang.String columnName, java.lang.String columnAlias, java.lang.String table, java.lang.String database, java.lang.String collation, java.lang.String schema, java.lang.String engine, java.lang.String charsetName, java.lang.String sqlTypeName, java.lang.String valueDefault, boolean isAutoIndex, boolean isNullable, boolean isPrimaryKey, boolean isUniqueKey, boolean isIndex, int length, int autoindexValue)
          Constructs a new instance of a ResultSetMetaData Field.
Data is fetched for use from the Field Object using its public get methods.
Field Objects are not designed to have thier contents altered once instantiated.
Small portions of this constructor were copied from MySql-Connector/J
 
Method Summary
 int getAutoindexValue()
           
 java.lang.String getCharsetName()
           
 java.lang.String getClassName()
           
 java.lang.String getCollation()
           
 java.lang.String getColumnAlias()
           
 java.lang.String getColumnName()
           
 java.lang.String getDatabase()
           
 java.lang.String getEngine()
           
 java.lang.String getFieldName()
           
 int getGenericSqlType()
           
 java.lang.String getGenericSqlTypeName()
           
 int getJdbcSqlType()
           
 java.lang.String getJdbcSqlTypeName()
           
 java.lang.String getMode()
           
 int getPrecision()
           
 int getPrecisionAdjustFactor()
           
 int getScale()
           
 java.lang.String getSchema()
           
 java.lang.String getTable()
           
 java.lang.String getValueDefault()
           
 boolean isAutoIndex()
           
 boolean isIndex()
           
 boolean isNullable()
           
 boolean isPrimaryKey()
           
 boolean isSigned()
           
 boolean isUniqueKey()
           
 boolean isUnsigned()
           
 java.lang.String toString()
          This is for debugging to make it easy to see whats in this SQLField.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SQLField

public SQLField(int serverType,
                java.lang.String fieldName,
                java.lang.String typeName,
                boolean isNullable,
                java.lang.String mode)
Constructs a new instance of a ParameterMetaData Field.
Create a new Field Object containing database metadata populated with the supplied parameters.
Data is fetched for use from the Field Object using its public get methods.
Field Objects are not designed to have thier contents altered once instantiated.

Parameters:
fieldName - String
typeName - String
isNullable - boolean
mode - String

SQLField

public SQLField(int serverType,
                java.lang.String columnName,
                java.lang.String columnAlias,
                java.lang.String table,
                java.lang.String database,
                java.lang.String collation,
                java.lang.String schema,
                java.lang.String engine,
                java.lang.String charsetName,
                java.lang.String sqlTypeName,
                java.lang.String valueDefault,
                boolean isAutoIndex,
                boolean isNullable,
                boolean isPrimaryKey,
                boolean isUniqueKey,
                boolean isIndex,
                int length,
                int autoindexValue)
Constructs a new instance of a ResultSetMetaData Field.
Data is fetched for use from the Field Object using its public get methods.
Field Objects are not designed to have thier contents altered once instantiated.
Small portions of this constructor were copied from MySql-Connector/J

Parameters:
columnName - String
columnAlias - String
table - String
database - String
collation - String
schema - String
engine - String
charsetName - String
sqlTypeName - String
valueDefault - String
isAutoIndex - boolean
isNullable - boolean
isPrimaryKey - boolean
isUniqueKey - boolean
isIndex - boolean
length - int
autoindexValue - int
Method Detail

getAutoindexValue

public int getAutoindexValue()
Returns:
the autoindexValue

getCharsetName

public java.lang.String getCharsetName()
Returns:
the charsetName

getClassName

public java.lang.String getClassName()
Returns:
the ClassName

getCollation

public java.lang.String getCollation()
Returns:
the collation

getColumnAlias

public java.lang.String getColumnAlias()
Returns:
the columnAlias

getColumnName

public java.lang.String getColumnName()
Returns:
the columnName

getDatabase

public java.lang.String getDatabase()
Returns:
the database

getEngine

public java.lang.String getEngine()
Returns:
the engine

getFieldName

public java.lang.String getFieldName()
Returns:
the FieldName

getJdbcSqlType

public int getJdbcSqlType()
Returns:
the JdbcSqlType

getJdbcSqlTypeName

public java.lang.String getJdbcSqlTypeName()
Returns:
the JdbcSqlTypeName

getMode

public java.lang.String getMode()
Returns:
the Mode

getGenericSqlType

public int getGenericSqlType()
Returns:
the dataType

getGenericSqlTypeName

public java.lang.String getGenericSqlTypeName()
Returns:
the mySqlTypeName

getPrecision

public int getPrecision()
Returns:
the Precision

getPrecisionAdjustFactor

public int getPrecisionAdjustFactor()
Returns:
the myPrecisionAdjustFactor

getScale

public int getScale()
Returns:
the Scale

getSchema

public java.lang.String getSchema()
Returns:
the schema

getTable

public java.lang.String getTable()
Returns:
the myTable

getValueDefault

public java.lang.String getValueDefault()
Returns:
the valueDefault

isAutoIndex

public boolean isAutoIndex()
Returns:
the isAutoIndex

isIndex

public boolean isIndex()
Returns:
the isIndex

isNullable

public boolean isNullable()
Returns:
the IsNullable

isSigned

public boolean isSigned()
Returns:
the IsSigned

isPrimaryKey

public boolean isPrimaryKey()
Returns:
the isPrimaryKey

isUniqueKey

public boolean isUniqueKey()
Returns:
the isUniqueKey

isUnsigned

public boolean isUnsigned()

toString

public java.lang.String toString()
This is for debugging to make it easy to see whats in this SQLField.

Overrides:
toString in class java.lang.Object
Returns:
This SQLResultsField as a human readable String.