com.northgateis.reality.realsql
Class RealTypes

java.lang.Object
 |
 +--com.northgateis.reality.realsql.RealTypes

public class RealTypes
extends java.lang.Object

This class provides information about SQL and RealSQL data types.

See Also:
ResultSet

Field Summary
static int BIGINT
           
static int BINARY
           
static int BIT
           
static int CHAR
           
static int DATE
           
static int DECIMAL
           
static int DOUBLE
           
static int FLOAT
           
static int INTEGER
           
static int LONGVARBINARY
           
static int LONGVARCHAR
           
static int NUMERIC
           
static int REAL
           
static int SMALLINT
           
static int TIME
           
static int TIMESTAMP
           
static int TINYINT
           
static int VARBINARY
           
static int VARCHAR
           
 
Constructor Summary
RealTypes()
           
 
Method Summary
static intgetRealSQLTypeForSQL(int sql)
          Provides the RealSQL type in the form of an int from this class for the specified SQL type from java.sql.Types.
static java.lang.StringgetRealSQLTypeNameForRealSQL(int realType)
          Provides a String representation of the specified RealSQL type.
static java.lang.StringgetRealSQLTypeNameForSQL(int sql)
          Provides the RealSQL type name for the specified SQL type constant from java.sql.Types.
static intgetSQLTypeForRealSQL(int realType)
          Provides the SQL type that corresponds to the specified RealSQL type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BIT

public static final int BIT

TINYINT

public static final int TINYINT

BIGINT

public static final int BIGINT

LONGVARBINARY

public static final int LONGVARBINARY

VARBINARY

public static final int VARBINARY

BINARY

public static final int BINARY

LONGVARCHAR

public static final int LONGVARCHAR

CHAR

public static final int CHAR

NUMERIC

public static final int NUMERIC

DECIMAL

public static final int DECIMAL

INTEGER

public static final int INTEGER

SMALLINT

public static final int SMALLINT

FLOAT

public static final int FLOAT

REAL

public static final int REAL

DOUBLE

public static final int DOUBLE

DATE

public static final int DATE

TIME

public static final int TIME

TIMESTAMP

public static final int TIMESTAMP

VARCHAR

public static final int VARCHAR
Constructor Detail

RealTypes

public RealTypes()
Method Detail

getRealSQLTypeForSQL

public static int getRealSQLTypeForSQL(int sql)
Provides the RealSQL type in the form of an int from this class for the specified SQL type from java.sql.Types. The conversion used here is the same conversion the driver uses.

Parameters:
sql - the SQL type from java.sql.Types
Returns:
an int value representing the RealSQL type
See Also:
Types


getRealSQLTypeNameForRealSQL

public static java.lang.String getRealSQLTypeNameForRealSQL(int realType)
Provides a String representation of the specified RealSQL type. The representation is using the RealSQL type system.

Parameters:
msql - the RealSQL type whose name is desired
Returns:
the RealSQL name for the specified type


getRealSQLTypeNameForSQL

public static java.lang.String getRealSQLTypeNameForSQL(int sql)
Provides the RealSQL type name for the specified SQL type constant from java.sql.Types.

Parameters:
sql - the SQL type value
Returns:
the RealSQL type name
See Also:
Types


getSQLTypeForRealSQL

public static int getSQLTypeForRealSQL(int realType)
Provides the SQL type that corresponds to the specified RealSQL type.

Parameters:
msql - the desired RealSQL type
Returns:
the SQL type from java.sql.Types