/libcore/ojluni/src/main/java/java/util/ |
H A D | Formattable.java | 57 * public void formatTo(Formatter fmt, int f, int width, int precision) { 65 * boolean usesymbol = alternate || (precision != -1 && precision < 10); 68 * // apply precision 69 * if (precision == -1 || out.length() < precision) { 73 * sb.append(out.substring(0, precision - 1)).append('*'); 149 * @param precision 151 * The precision is applied before the width, thus the output will 152 * be truncated to <tt>precision</t 163 formatTo(Formatter formatter, int flags, int width, int precision) argument [all...] |
H A D | Formatter.java | 97 * // locale-specific formatting of numbers. The precision and width can be 183 * %[argument_index$][flags][width][.precision]conversion 196 * <p> The optional <i>precision</i> is a non-negative decimal integer usually 342 * decimal format, depending on the precision and the value after rounding. 626 * <p> For general argument types, the precision is the maximum number of 630 * {@code 'E'}, and {@code 'f'} the precision is the number of digits after the 632 * precision is the total number of digits in the resulting magnitude after 636 * and line separator conversions, the precision is not applicable; if a 637 * precision is provided, an exception will be thrown. 671 * <p> If the format specifier contains a width or precision wit 2577 private String precision; field in class:Formatter.FormatSpecifierParser 2705 private int precision; field in class:Formatter.FormatSpecifier 2757 private int precision(String s) { method in class:Formatter.FormatSpecifier 2773 int precision() { method in class:Formatter.FormatSpecifier 3348 print(StringBuilder sb, double value, Locale l, Flags f, char c, int precision, boolean neg) argument 3642 print(StringBuilder sb, BigDecimal value, Locale l, Flags f, char c, int precision, boolean neg) argument [all...] |
/libcore/ojluni/src/main/java/java/time/temporal/ |
H A D | TemporalQueries.java | 111 * <li> a precision, 213 * This queries a {@code TemporalAccessor} for the time precision. 215 * date or time then this must return the smallest precision actually supported. 217 * are defined to always return ignoring the precision, thus this is the only 220 * it would return a precision of {@code MILLIS}. 241 * @return a query that can obtain the precision of a temporal, not null 243 public static TemporalQuery<TemporalUnit> precision() { method in class:TemporalQueries
|
/libcore/luni/src/main/java/java/math/ |
H A D | MathContext.java | 27 * precision for the numerical operations provided by class {@link BigDecimal}. 34 * decimal precision format: 34 digit precision and 41 * precision format: 7 digit precision and {@link RoundingMode#HALF_EVEN} 48 * precision format: 16 digit precision and {@link RoundingMode#HALF_EVEN} 54 * A {@code MathContext} for unlimited precision with 61 * this precision. 63 private final int precision; field in class:MathContext 82 MathContext(int precision) argument 101 MathContext(int precision, RoundingMode roundingMode) argument [all...] |
H A D | BigDecimal.java | 28 * An immutable arbitrary-precision signed decimal. 30 * <p>A value is represented by an arbitrary-precision "unscaled value" and a signed 32-bit "scale", 212 * The arbitrary precision integer (unscaled value) in the internal 228 * precision is calculated the first time, and used in the following calls 229 * of method <code>precision()</code>. Note that some call to the private 232 * @see #precision() 235 private transient int precision = 0; field in class:BigDecimal 363 * rounding mode and precision for the result of this operation. 369 * if {@code mc.precision > 0} and {@code mc.roundingMode == 371 * within the given precision withou 1791 public int precision() { method in class:BigDecimal [all...] |
/libcore/ojluni/src/main/java/javax/sql/ |
H A D | RowSetMetaData.java | 180 * @param precision the total number of decimal digits 183 void setPrecision(int columnIndex, int precision) throws SQLException; argument
|
/libcore/ojluni/src/main/java/sun/misc/ |
H A D | FormattedFloatingDecimal.java | 35 public static FormattedFloatingDecimal valueOf(double d, int precision, Form form){ argument 38 return new FormattedFloatingDecimal(precision,form, fdConverter); 57 private FormattedFloatingDecimal(int precision, Form form, FloatingDecimal.BinaryToASCIIConverter fdConverter) { argument 72 fillCompatible(precision, digits, nDigits, exp, isNegative); 75 exp = applyPrecision(decExp, digits, nDigits, decExp + precision); 76 fillDecimal(precision, digits, nDigits, exp, isNegative); 80 exp = applyPrecision(decExp, digits, nDigits, precision + 1); 81 fillScientific(precision, digits, nDigits, exp, isNegative); 85 exp = applyPrecision(decExp, digits, nDigits, precision); 86 // adjust precision t 163 fillCompatible(int precision, char[] digits, int nDigits, int exp, boolean isNegative) argument 262 fillDecimal(int precision, char[] digits, int nDigits, int exp, boolean isNegative) argument 314 fillScientific(int precision, char[] digits, int nDigits, int exp, boolean isNegative) argument [all...] |
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/ |
H A D | FormatterTest.java | 80 int precision) throws IllegalFormatException { 83 + width + " PRECISION: " + precision); 86 + width + " precision: " + precision); 852 * java.util.Formatter#format(String, Object...) for precision 1120 // If i is '.', s can also be interpreted as an illegal precision. 1228 { new MockFormattable(), "%2.3s", "customized format function width: 2 precision: 3", }, 1229 { new MockFormattable(), "%-6.4s", "customized format function width: 6 precision: 4", }, 1230 { new MockFormattable(), "%.5s", "customized format function width: -1 precision: 5", }, 1335 "customized format function width: -1 precision 79 formatTo(Formatter formatter, int flags, int width, int precision) argument [all...] |