org.apache.ojb.broker.metadata
Class JdbcTypesHelper.BaseType

java.lang.Object
  extended by org.apache.ojb.broker.metadata.JdbcTypesHelper.BaseType
All Implemented Interfaces:
java.io.Serializable, JdbcType
Direct Known Subclasses:
JdbcTypesHelper.T_Array, JdbcTypesHelper.T_BigInt, JdbcTypesHelper.T_Binary, JdbcTypesHelper.T_Bit, JdbcTypesHelper.T_Blob, JdbcTypesHelper.T_Boolean, JdbcTypesHelper.T_Char, JdbcTypesHelper.T_Clob, JdbcTypesHelper.T_Datalink, JdbcTypesHelper.T_Date, JdbcTypesHelper.T_Decimal, JdbcTypesHelper.T_Double, JdbcTypesHelper.T_Float, JdbcTypesHelper.T_Integer, JdbcTypesHelper.T_LongVarBinary, JdbcTypesHelper.T_LongVarChar, JdbcTypesHelper.T_Numeric, JdbcTypesHelper.T_Real, JdbcTypesHelper.T_Ref, JdbcTypesHelper.T_SmallInt, JdbcTypesHelper.T_Struct, JdbcTypesHelper.T_Time, JdbcTypesHelper.T_Timestamp, JdbcTypesHelper.T_TinyInt, JdbcTypesHelper.T_VarBinary, JdbcTypesHelper.T_Varchar
Enclosing class:
JdbcTypesHelper

public abstract static class JdbcTypesHelper.BaseType
extends java.lang.Object
implements JdbcType

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.apache.ojb.broker.metadata.JdbcType
MIN_INT
 
Method Summary
 boolean equals(java.lang.Object obj)
          Indicates whether some other object is "equal to" this one.
 FieldType getFieldType()
          Returns the associated FieldType (java field type mapped to this sql type).
 java.lang.Object getObjectFromColumn(java.sql.CallableStatement stmt, int columnId)
          Convenience method for JdbcType.getObjectFromColumn(ResultSet, CallableStatement, String, int)
 java.lang.Object getObjectFromColumn(java.sql.ResultSet rs, java.sql.CallableStatement stmt, java.lang.String columnName, int columnIndex)
          Returns an java object for this jdbc type by extract from the given CallableStatement or ResultSet.
 java.lang.Object getObjectFromColumn(java.sql.ResultSet rs, java.lang.String columnName)
          Convenience method for JdbcType.getObjectFromColumn(ResultSet, CallableStatement, String, int)
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.apache.ojb.broker.metadata.JdbcType
getType, sequenceKeyConversion
 

Method Detail

equals

public boolean equals(java.lang.Object obj)
Description copied from interface: JdbcType
Indicates whether some other object is "equal to" this one.

Specified by:
equals in interface JdbcType
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

getFieldType

public FieldType getFieldType()
Description copied from interface: JdbcType
Returns the associated FieldType (java field type mapped to this sql type).

Specified by:
getFieldType in interface JdbcType

getObjectFromColumn

public java.lang.Object getObjectFromColumn(java.sql.CallableStatement stmt,
                                            int columnId)
                                     throws java.sql.SQLException
Description copied from interface: JdbcType
Convenience method for JdbcType.getObjectFromColumn(ResultSet, CallableStatement, String, int)

Specified by:
getObjectFromColumn in interface JdbcType
Throws:
java.sql.SQLException

getObjectFromColumn

public java.lang.Object getObjectFromColumn(java.sql.ResultSet rs,
                                            java.lang.String columnName)
                                     throws java.sql.SQLException
Description copied from interface: JdbcType
Convenience method for JdbcType.getObjectFromColumn(ResultSet, CallableStatement, String, int)

Specified by:
getObjectFromColumn in interface JdbcType
Throws:
java.sql.SQLException

getObjectFromColumn

public java.lang.Object getObjectFromColumn(java.sql.ResultSet rs,
                                            java.sql.CallableStatement stmt,
                                            java.lang.String columnName,
                                            int columnIndex)
                                     throws java.sql.SQLException
Description copied from interface: JdbcType
Returns an java object for this jdbc type by extract from the given CallableStatement or ResultSet.
NOTE: For internal use only!!
Exactly one of the arguments of type CallableStatement or ResultSet have to be non-null. If the 'columnId' argument is equals JdbcType.MIN_INT, then the given 'columnName' argument is used to lookup column. Else the given 'columnId' is used as column index.

Specified by:
getObjectFromColumn in interface JdbcType
Throws:
java.sql.SQLException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


(C) 2002 - 2006 Apache Software Foundation
All rights reserved. Published under the Apache License 2.0.
http://db.apache.org/ojb
Version: 1.0.4, 2005-12-30