/libcore/luni/src/main/java/java/math/ |
H A D | Conversion.java | 132 * being scaled by {@code scale}. 137 static String toDecimalScaledString(BigInteger val, int scale) { argument 147 switch (scale) { 164 if (scale < 0) { 169 result1.append(-scale); 239 int exponent = resLengthInChars - currentChar - scale - 1; 240 if (scale == 0) { 247 if ((scale > 0) && (exponent >= -6)) { 297 static String toDecimalScaledString(long value, int scale) { argument 306 switch (scale) { [all...] |
H A D | BigDecimal.java | 30 * <p>A value is represented by an arbitrary-precision "unscaled value" and a signed 32-bit "scale", 31 * combined thus: {@code unscaled * 10<sup>-scale</sup>}. See {@link #unscaledValue} and {@link #scale}. 222 * The 32-bit integer scale in the internal representation of {@code BigDecimal}. 224 private int scale; field in class:BigDecimal 237 private BigDecimal(long smallValue, int scale){ argument 239 this.scale = scale; 243 private BigDecimal(int smallValue, int scale){ argument 245 this.scale 574 BigDecimal(BigInteger unscaledVal, int scale) argument 597 BigDecimal(BigInteger unscaledVal, int scale, MathContext mc) argument 669 valueOf(long unscaledVal, int scale) argument 997 divide(BigDecimal divisor, int scale, int roundingMode) argument 1024 divide(BigDecimal divisor, int scale, RoundingMode roundingMode) argument 1083 divideBigIntegers(BigInteger scaledDividend, BigInteger scaledDivisor, int scale, RoundingMode roundingMode) argument 1119 dividePrimitiveLongs(long scaledDividend, long scaledDivisor, int scale, RoundingMode roundingMode) argument 1779 public int scale() { method in class:BigDecimal [all...] |
/libcore/luni/src/test/java/libcore/java/math/ |
H A D | BigDecimalTest.java | 84 assertEquals(21, a.scale()); 85 assertEquals(21, b.scale()); 127 private static void checkDivide(String expected, long n, long d, int scale, RoundingMode rm) { argument 128 assertEquals(String.format(Locale.US, "%d/%d [%d, %s]", n, d, scale, rm.name()), 130 new BigDecimal(n).divide(new BigDecimal(d), scale, rm)); 134 // checkDivide(expected, dividend, divisor, scale, roundingMode) 161 // checkDivide(expected, dividend, divisor, scale, roundingMode) 273 minLong.divide(new BigDecimal("-1"), /* scale = */ 0, RoundingMode.UNNECESSARY)); 278 .divide(new BigDecimal("-0.1"), /* scale = */ 0, RoundingMode.UNNECESSARY)); 283 .divide(new BigDecimal("-1E+1"), /* scale [all...] |
/libcore/ojluni/src/main/java/javax/sql/ |
H A D | RowSetMetaData.java | 190 * @param scale the number of digits to right of decimal point 193 void setScale(int columnIndex, int scale) throws SQLException; argument
|
H A D | RowSet.java | 1225 * to be sent to the database. The scale argument may further qualify this 1264 * sent to the database. The scale argument may further qualify this type. 1265 * @param scale for java.sql.Types.DECIMAL or java.sql.Types.NUMERIC types, 1281 void setObject(String parameterName, Object x, int targetSqlType, int scale) argument 1288 * This method is like <code>setObject</code> above, but the scale used is the scale 1289 * of the second parameter. Scalar values have a scale of zero. Literal 1290 * values have the scale present in the literal. 1307 * above, except that it assumes a scale of zero.
|
/libcore/ojluni/src/main/java/java/nio/file/attribute/ |
H A D | FileTime.java | 208 private static long scale(long d, long m, long over) { method in class:FileTime 236 secs = scale(value, SECONDS_PER_DAY, 240 secs = scale(value, SECONDS_PER_HOUR, 244 secs = scale(value, SECONDS_PER_MINUTE,
|
/libcore/ojluni/src/main/java/java/sql/ |
H A D | CallableStatement.java | 88 * <code>registerOutParameter</code> that accepts a scale value 123 * @param scale the desired number of digits to the right of the 137 void registerOutParameter(int parameterIndex, int sqlType, int scale) argument 283 * <code>java.math.BigDecimal</code> object with <i>scale</i> digits to 287 * @param scale the number of digits to the right of the decimal point 300 BigDecimal getBigDecimal(int parameterIndex, int scale) argument 643 * <code>registerOutParameter</code> that accepts a scale value 678 * @param scale the desired number of digits to the right of the 694 void registerOutParameter(String parameterName, int sqlType, int scale) argument 1106 * sent to the database. The scale argumen 1124 setObject(String parameterName, Object x, int targetSqlType, int scale) argument [all...] |
H A D | ResultSet.java | 352 * @param scale the number of digits to the right of the decimal point 364 BigDecimal getBigDecimal(int columnIndex, int scale) throws SQLException; argument 640 * @param scale the number of digits to the right of the decimal point 652 BigDecimal getBigDecimal(String columnLabel, int scale) throws SQLException; argument
|
/libcore/ojluni/src/main/java/java/util/ |
H A D | Formatter.java | 3649 int scale = value.scale(); 3663 = new BigDecimal(value.unscaledValue(), scale, mc); 3666 = new BigDecimalLayout(v.unscaledValue(), v.scale(), 3672 // contain a decimal point if the scale is zero (the internal 3703 int scale = value.scale(); 3705 if (scale > prec) { 3706 // more "scale" digits than the requested "precision" 3708 if (compPrec <= scale) { 3783 private int scale; field in class:Formatter.FormatSpecifier.BigDecimalLayout 3785 BigDecimalLayout(BigInteger intVal, int scale, BigDecimalLayoutForm form) argument 3793 public int scale() { method in class:Formatter.FormatSpecifier.BigDecimalLayout 3825 layout(BigInteger intVal, int scale, BigDecimalLayoutForm form) argument [all...] |