public class SimpleNumberCoercerFactory extends Object
Modifier and Type | Class and Description |
---|---|
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerBigDecDouble |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerBigDecLong |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerBigInt |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerByte |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerDouble |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerFloat |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerInt |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerLong |
static class |
SimpleNumberCoercerFactory.SimpleNumberCoercerShort |
Constructor and Description |
---|
SimpleNumberCoercerFactory() |
Modifier and Type | Method and Description |
---|---|
static SimpleNumberCoercer |
getCoercer(Class fromType,
Class resultBoxedType)
Returns a coercer/widener/narrower to a result number type from a given type.
|
static SimpleNumberBigDecimalCoercer |
getCoercerBigDecimal(Class fromType)
Returns a coercer/widener to BigDecimal for a given type.
|
static SimpleNumberBigIntegerCoercer |
getCoercerBigInteger(Class fromType)
Returns a coercer/widener to BigInteger for a given type.
|
public static SimpleNumberBigDecimalCoercer getCoercerBigDecimal(Class fromType)
fromType
- to widenpublic static SimpleNumberBigIntegerCoercer getCoercerBigInteger(Class fromType)
fromType
- to widenpublic static SimpleNumberCoercer getCoercer(Class fromType, Class resultBoxedType)
fromType
- to widen/narrow, can be null to indicate that no shortcut-coercer is usedresultBoxedType
- type to widen/narrow to