/libcore/luni/src/test/java/libcore/java/math/ |
D | MathContextTest.java | 19 import java.math.MathContext; 26 MathContext mc = new MathContext("precision=1 roundingMode=" + rm); in testConstructor() 33 MathContext mc = new MathContext("precision=" + p + " roundingMode=" + RoundingMode.UP); in testConstructor() 39 new MathContext("precision=1 roundingMode=UP"); in testConstructor() 41 new MathContext("Precision=1 roundingMode=UP"); in testConstructor() 46 new MathContext("precision=1 RoundingMode=UP"); in testConstructor() 53 new MathContext("precision=1 roundingMode=up"); in testConstructor() 60 new MathContext("precision=1roundingMode=UP"); in testConstructor() 65 new MathContext("precision=1 roundingMode=UP"); in testConstructor() 70 new MathContext("precision=1\troundingMode=UP"); in testConstructor() [all …]
|
D | OldBigDecimalConstructorsTest.java | 25 import java.math.MathContext; 39 MathContext mc = new MathContext(precision, rm); in testConstrBigIntegerMathContext() 52 mc = new MathContext(31, RoundingMode.UP); in testConstrBigIntegerMathContext() 58 mc = new MathContext(28, RoundingMode.DOWN); in testConstrBigIntegerMathContext() 64 mc = new MathContext(33, RoundingMode.CEILING); in testConstrBigIntegerMathContext() 70 mc = new MathContext(34, RoundingMode.FLOOR); in testConstrBigIntegerMathContext() 76 mc = new MathContext(34, RoundingMode.HALF_EVEN); in testConstrBigIntegerMathContext() 84 mc = new MathContext(34, RoundingMode.HALF_UP); in testConstrBigIntegerMathContext() 90 mc = new MathContext(34, RoundingMode.HALF_DOWN); in testConstrBigIntegerMathContext() 96 mc = new MathContext(34, RoundingMode.UNNECESSARY); in testConstrBigIntegerMathContext() [all …]
|
D | OldBigDecimalCompareTest.java | 26 import java.math.MathContext; 35 MathContext mc = new MathContext(34, RoundingMode.UP); in testAbsMathContextNeg() 38 mc = new MathContext(34, RoundingMode.DOWN); in testAbsMathContextNeg() 41 mc = new MathContext(34, RoundingMode.FLOOR); in testAbsMathContextNeg() 44 mc = new MathContext(34, RoundingMode.CEILING); in testAbsMathContextNeg() 47 mc = new MathContext(34, RoundingMode.UNNECESSARY); in testAbsMathContextNeg() 57 MathContext mc = new MathContext(37, RoundingMode.FLOOR); in testNegateMathContextPositive()
|
D | OldBigDecimalArithmeticTest.java | 22 import java.math.MathContext; 29 MathContext mc; in testAddMathContextNonTrivial() 32 mc = new MathContext(17, RoundingMode.FLOOR); in testAddMathContextNonTrivial() 44 mc = new MathContext(33, RoundingMode.UNNECESSARY); in testAddMathContextNonTrivial() 54 MathContext mc; in testSubtractMathContextNonTrivial() 57 mc = new MathContext(17, RoundingMode.FLOOR); in testSubtractMathContextNonTrivial() 67 mc = new MathContext(33, RoundingMode.UNNECESSARY); in testSubtractMathContextNonTrivial() 77 MathContext mc; in testMultiplyMathContextNonTrivial() 80 mc = new MathContext(17, RoundingMode.FLOOR); in testMultiplyMathContextNonTrivial() 118 MathContext mc = new MathContext(5, RoundingMode.HALF_UP); in testPowMathContext() [all …]
|
D | OldBigDecimalConvertTest.java | 25 import java.math.MathContext; 146 MathContext mc = new MathContext(iPresition, RoundingMode.UP); in test_ByteValueExactNeg() 158 MathContext mc = new MathContext(iPresition, RoundingMode.HALF_DOWN); in test_ByteValueExactCharZero() 168 MathContext mc = new MathContext(iPresition, RoundingMode.HALF_UP); in test_ByteValueExactStringZero() 258 MathContext mc = new MathContext(iPresition, RoundingMode.UP); in test_ByteValueNeg() 270 MathContext mc = new MathContext(iPresition, RoundingMode.HALF_UP); in test_ByteValueCharZero() 280 MathContext mc = new MathContext(iPresition, RoundingMode.HALF_UP); in test_ByteValueStringZero()
|
D | BigDecimalTest.java | 20 import java.math.MathContext; 64 BigDecimal rounded = bigDecimal.round(new MathContext(2, RoundingMode.FLOOR)); in testRound() 96 assertEquals("1.20", a.abs(new MathContext(3,RoundingMode.HALF_UP)).toPlainString()); in test54580()
|
/libcore/luni/src/main/java/java/math/ |
D | MathContext.java | 29 public final class MathContext implements Serializable { class 37 public static final MathContext DECIMAL128 = new MathContext(34, RoundingMode.HALF_EVEN); 44 public static final MathContext DECIMAL32 = new MathContext(7, RoundingMode.HALF_EVEN); 51 public static final MathContext DECIMAL64 = new MathContext(16, RoundingMode.HALF_EVEN); 57 public static final MathContext UNLIMITED = new MathContext(0, RoundingMode.HALF_UP); 82 public MathContext(int precision) { in MathContext() method in MathContext 101 public MathContext(int precision, RoundingMode roundingMode) { in MathContext() method in MathContext 118 public MathContext(String s) { in MathContext() method in MathContext 200 return ((x instanceof MathContext) in equals() 201 && (((MathContext) x).getPrecision() == precision) && (((MathContext) x) in equals()
|
D | BigDecimal.java | 373 public BigDecimal(char[] in, int offset, int len, MathContext mc) { in BigDecimal() 411 public BigDecimal(char[] in, MathContext mc) { in BigDecimal() 443 public BigDecimal(String val, MathContext mc) { in BigDecimal() 537 public BigDecimal(double val, MathContext mc) { in BigDecimal() 561 public BigDecimal(BigInteger val, MathContext mc) { in BigDecimal() 597 public BigDecimal(BigInteger unscaledVal, int scale, MathContext mc) { in BigDecimal() 627 public BigDecimal(int val, MathContext mc) { in BigDecimal() 657 public BigDecimal(long val, MathContext mc) { in BigDecimal() 785 public BigDecimal add(BigDecimal augend, MathContext mc) { in add() 889 public BigDecimal subtract(BigDecimal subtrahend, MathContext mc) { in subtract() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/math/ |
D | MathContextTest.java | 21 import java.math.MathContext; 32 MathContext mcIntRm6hd = new MathContext(6, RoundingMode.HALF_DOWN); in test_MathContextConstruction() 33 MathContext mcStr6hd = new MathContext("precision=6 roundingMode=HALF_DOWN"); in test_MathContextConstruction() 34 MathContext mcInt6 = new MathContext(6); in test_MathContextConstruction() 35 MathContext mcInt134 = new MathContext(134); in test_MathContextConstruction()
|
D | BigDecimalConstructorsTest.java | 25 import java.math.MathContext; 103 MathContext mc = new MathContext(precision, rm); in testConstrBigIntegerMathContext() 120 MathContext mc = new MathContext(precision, rm); in testConstrBigIntegerScaleMathContext() 177 MathContext mc = new MathContext(precision, rm); in testConstrCharIntIntMathContext() 186 new BigDecimal(new char[] {}, 0, 0, MathContext.DECIMAL32); in testConstrCharIntIntMathContext() 201 MathContext mc = new MathContext(precision, rm); in testConstrCharIntIntMathContextException1() 218 MathContext mc = new MathContext(precision, rm); in testConstrCharIntIntMathContextException2() 232 new BigDecimal(new char[] {}, MathContext.DECIMAL32); in testConstrCharMathContext() 293 MathContext mc = new MathContext(precision, rm); in testConstrDoubleMathContext() 356 MathContext mc = new MathContext(precision, rm); in testConstrIntMathContext() [all …]
|
D | BigDecimalArithmeticTest.java | 22 import java.math.MathContext; 61 MathContext mc = new MathContext(5, RoundingMode.UP); in testAddMathContextEqualScalePosPos() 96 MathContext mc = new MathContext(5, RoundingMode.FLOOR); in testAddMathContextEqualScaleNegNeg() 131 MathContext mc = new MathContext(15, RoundingMode.CEILING); in testAddMathContextDiffScalePosNeg() 200 MathContext mc = new MathContext(15, RoundingMode.CEILING); in testSubtractMathContextEqualScalePosPos() 253 MathContext mc = new MathContext(17, RoundingMode.DOWN); in testSubtractMathContextDiffScalePosNeg() 289 MathContext mc = new MathContext(70, RoundingMode.HALF_DOWN); in testSubtractMathContextDiffScaleNegPos() 324 MathContext mc = new MathContext(40, RoundingMode.HALF_DOWN); in testMultiplyMathContextScalePosPos() 376 MathContext mc = new MathContext(53, RoundingMode.HALF_UP); in testMultiplyMathContextDiffScalePosNeg() 411 MathContext mc = new MathContext(47, RoundingMode.HALF_UP); in testMultiplyMathContextDiffScaleNegPos() [all …]
|
D | BigDecimalCompareTest.java | 25 import java.math.MathContext; 64 MathContext mc = new MathContext(precision, rm); in testAbsMathContextNeg() 80 MathContext mc = new MathContext(precision, rm); in testAbsMathContextPos() 375 MathContext mc = new MathContext(precision, rm); in testPlusMathContextPositive() 405 MathContext mc = new MathContext(precision, rm); in testPlusMathContextNegative() 435 MathContext mc = new MathContext(precision, rm); in testNegateMathContextPositive() 465 MathContext mc = new MathContext(precision, rm); in testNegateMathContextNegative()
|
D | BigDecimalTest.java | 26 import java.math.MathContext; 927 MathContext mcIntRm = new MathContext(precision, rm); in testMathContextConstruction() 928 MathContext mcStr = new MathContext("precision=6 roundingMode=HALF_DOWN"); in testMathContextConstruction() 929 MathContext mcInt = new MathContext(precision); in testMathContextConstruction()
|
/libcore/ojluni/src/main/java/java/text/ |
D | DecimalFormat.java | 57 import android.icu.math.MathContext; 1363 return MathContext.ROUND_UP; in convertRoundingMode() 1365 return MathContext.ROUND_DOWN; in convertRoundingMode() 1367 return MathContext.ROUND_CEILING; in convertRoundingMode() 1369 return MathContext.ROUND_FLOOR; in convertRoundingMode() 1371 return MathContext.ROUND_HALF_UP; in convertRoundingMode() 1373 return MathContext.ROUND_HALF_DOWN; in convertRoundingMode() 1375 return MathContext.ROUND_HALF_EVEN; in convertRoundingMode() 1377 return MathContext.ROUND_UNNECESSARY; in convertRoundingMode()
|
/libcore/ojluni/src/main/java/java/util/ |
D | Formatter.java | 42 import java.math.MathContext; 3629 MathContext mc = new MathContext(compPrec); 3683 new MathContext(compPrec));
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/ |
D | FormatterTest.java | 32 import java.math.MathContext; 4201 MathContext mc = new MathContext(30); in test_ScientificNotation()
|
/libcore/ |
D | non_openjdk_java_files.mk | 73 luni/src/main/java/java/math/MathContext.java \
|