public abstract class RoundingStrategy extends Object
Modifier and Type | Field and Description |
---|---|
protected MathContext[] |
_theContextCache |
protected static int |
CACHE_SIZE |
static RoundingStrategy |
CEILING |
static RoundingStrategy |
DOWN |
static RoundingStrategy |
FLOOR |
static RoundingStrategy |
HALF_DOWN |
static RoundingStrategy |
HALF_EVEN |
static RoundingStrategy |
HALF_UP |
static RoundingStrategy |
UNNECESSARY |
static RoundingStrategy |
UP |
Modifier | Constructor and Description |
---|---|
protected |
RoundingStrategy() |
Modifier and Type | Method and Description |
---|---|
boolean |
booleanValue(double aNumber) |
boolean |
booleanValue(float aNumber) |
byte |
byteValue(double aNumber) |
byte |
byteValue(float aNumber) |
char |
charValue(double aNumber) |
char |
charValue(float aNumber) |
abstract double |
doubleValue(double aNumber) |
float |
floatValue(float aNumber) |
abstract int |
getBigDecimalRoundingMode() |
static RoundingStrategy |
getInstance(int aBigDecimalRoundingMode) |
static RoundingStrategy |
getInstance(RoundingMode aMode) |
MathContext |
getMathContext(int precision) |
abstract RoundingMode |
getRoundingMode() |
abstract int |
intValue(double aNumber) |
abstract int |
intValue(float aNumber) |
abstract long |
longValue(double aNumber) |
abstract long |
longValue(float aNumber) |
short |
shortValue(double aNumber) |
short |
shortValue(float aNumber) |
BigDecimal |
toUnlimitedDecimal(BigDecimal aNumber) |
static BigDecimal |
toUnlimitedDecimal(double aValue) |
static BigDecimal |
toUnlimitedDecimal(float aValue) |
static BigDecimal |
toUnlimitedDecimal(String aValue) |
BigInteger |
toUnlimitedInteger(double aNumber) |
BigInteger |
toUnlimitedInteger(float aNumber) |
protected static final int CACHE_SIZE
public static final RoundingStrategy CEILING
Math.ceil(double)
,
RoundingMode.CEILING
public static final RoundingStrategy DOWN
RoundingMode.DOWN
public static final RoundingStrategy FLOOR
Math.floor(double)
,
RoundingMode.FLOOR
public static final RoundingStrategy HALF_DOWN
RoundingMode.HALF_DOWN
public static final RoundingStrategy HALF_EVEN
Math.rint(double)
,
RoundingMode.HALF_EVEN
public static final RoundingStrategy HALF_UP
RoundingMode.HALF_UP
public static final RoundingStrategy UNNECESSARY
RoundingMode.UNNECESSARY
public static final RoundingStrategy UP
RoundingMode.UP
protected final MathContext[] _theContextCache
protected RoundingStrategy()
public abstract int getBigDecimalRoundingMode()
public MathContext getMathContext(int precision)
public abstract RoundingMode getRoundingMode()
public final boolean booleanValue(double aNumber)
public final boolean booleanValue(float aNumber)
public final byte byteValue(double aNumber)
public final byte byteValue(float aNumber)
public final char charValue(double aNumber)
public final char charValue(float aNumber)
public abstract double doubleValue(double aNumber)
public final float floatValue(float aNumber)
public abstract int intValue(double aNumber)
public abstract int intValue(float aNumber)
public abstract long longValue(double aNumber)
public abstract long longValue(float aNumber)
public final short shortValue(double aNumber)
public final short shortValue(float aNumber)
public final BigDecimal toUnlimitedDecimal(BigDecimal aNumber)
public final BigInteger toUnlimitedInteger(double aNumber)
public final BigInteger toUnlimitedInteger(float aNumber)
public static final RoundingStrategy getInstance(int aBigDecimalRoundingMode)
public static final RoundingStrategy getInstance(RoundingMode aMode)
public static final BigDecimal toUnlimitedDecimal(double aValue)
public static final BigDecimal toUnlimitedDecimal(float aValue)
public static final BigDecimal toUnlimitedDecimal(String aValue)
Copyright © 2006-2012 Ware-Squared Software Development. All Rights Reserved.