public class BigDecimalTypeDescriptor extends AbstractTypeDescriptor<java.math.BigDecimal>
BigDecimal handling.| Modifier and Type | Field and Description |
|---|---|
static BigDecimalTypeDescriptor |
INSTANCE |
| Constructor and Description |
|---|
BigDecimalTypeDescriptor() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
areEqual(java.math.BigDecimal one,
java.math.BigDecimal another)
Determine if two instances are equal
|
int |
extractHashCode(java.math.BigDecimal value)
Extract a proper hash code for this value.
|
java.math.BigDecimal |
fromString(java.lang.String string) |
java.lang.String |
toString(java.math.BigDecimal value) |
<X> X |
unwrap(java.math.BigDecimal value,
java.lang.Class<X> type,
WrapperOptions options)
Unwrap an instance of our handled Java type into the requested type.
|
<X> java.math.BigDecimal |
wrap(X value,
WrapperOptions options)
Wrap a value as our handled Java type.
|
extractLoggableRepresentation, getComparator, getJavaTypeClass, getMutabilityPlan, unknownUnwrap, unknownWrappublic static final BigDecimalTypeDescriptor INSTANCE
public java.lang.String toString(java.math.BigDecimal value)
public java.math.BigDecimal fromString(java.lang.String string)
public boolean areEqual(java.math.BigDecimal one,
java.math.BigDecimal another)
AbstractTypeDescriptorareEqual in interface JavaTypeDescriptor<java.math.BigDecimal>areEqual in class AbstractTypeDescriptor<java.math.BigDecimal>one - One instanceanother - The other instancepublic int extractHashCode(java.math.BigDecimal value)
AbstractTypeDescriptorextractHashCode in interface JavaTypeDescriptor<java.math.BigDecimal>extractHashCode in class AbstractTypeDescriptor<java.math.BigDecimal>value - The value for which to extract a hash code.public <X> X unwrap(java.math.BigDecimal value,
java.lang.Class<X> type,
WrapperOptions options)
JavaTypeDescriptorJavaTypeDescriptor<Integer> and we are asked to unwrap
the Integer value as a Long we would return something like
Long.valueOf( value.longValue() ).
Intended use is during PreparedStatement binding.X - The conversion type.value - The value to unwraptype - The type as which to unwrapoptions - The optionspublic <X> java.math.BigDecimal wrap(X value,
WrapperOptions options)
JavaTypeDescriptorResultSet extraction.X - The conversion type.value - The value to wrap.options - The optionsCopyright © 2013. All Rights Reserved.