org.hibernate.type
Class BigDecimalType
java.lang.Object
org.hibernate.type.AbstractType
org.hibernate.type.NullableType
org.hibernate.type.ImmutableType
org.hibernate.type.BigDecimalType
- All Implemented Interfaces:
- Serializable, Type
- public class BigDecimalType
- extends ImmutableType
big_decimal: A type that maps an SQL NUMERIC to a
java.math.BigDecimal
- Author:
- Gavin King
- See Also:
BigDecimal
,
Serialized Form
Methods inherited from class org.hibernate.type.NullableType |
fromXMLNode, fromXMLString, getColumnSpan, isEqual, nullSafeGet, nullSafeGet, nullSafeGet, nullSafeGet, nullSafeSet, nullSafeSet, nullSafeSet, setToXMLNode, sqlTypes, toLoggableString, toXMLString |
Methods inherited from class org.hibernate.type.AbstractType |
assemble, compare, disassemble, getHashCode, getSemiResolvedType, hydrate, isAnyType, isAssociationType, isCollectionType, isComponentType, isDirty, isEntityType, isEqual, isModified, isSame, isXMLElement, replaceNode, resolve, semiResolve |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BigDecimalType
public BigDecimalType()
get
public Object get(ResultSet rs,
String name)
throws HibernateException,
SQLException
- Specified by:
get
in class NullableType
- Throws:
HibernateException
SQLException
set
public void set(PreparedStatement st,
Object value,
int index)
throws HibernateException,
SQLException
- Specified by:
set
in class NullableType
- Throws:
HibernateException
SQLException
sqlType
public int sqlType()
- Specified by:
sqlType
in class NullableType
toString
public String toString(Object value)
throws HibernateException
- Specified by:
toString
in class NullableType
- Throws:
HibernateException
getReturnedClass
public Class getReturnedClass()
- Description copied from interface:
Type
- The class returned by nullSafeGet() methods. This is used to
establish the class of an array of this type.
- Returns:
- Class
isEqual
public boolean isEqual(Object x,
Object y)
- Overrides:
isEqual
in class NullableType
getHashCode
public int getHashCode(Object x,
EntityMode entityMode)
- Description copied from interface:
Type
- Get a hashcode, consistent with persistence "equality"
- Specified by:
getHashCode
in interface Type
- Overrides:
getHashCode
in class AbstractType
getName
public String getName()
- Description copied from interface:
Type
- Returns the abbreviated name of the type.
- Returns:
- String the Hibernate type name
fromStringValue
public Object fromStringValue(String xml)
- Specified by:
fromStringValue
in class NullableType