public class FloatingPointFormat extends DecimalFormat implements RevisionHandler
NumberFormat.Field| Modifier and Type | Field and Description |
|---|---|
protected int |
decimal |
protected DecimalFormat |
nf |
protected boolean |
trailing |
protected int |
width |
FRACTION_FIELD, INTEGER_FIELD| Constructor and Description |
|---|
FloatingPointFormat()
Default constructor
|
FloatingPointFormat(int digits) |
FloatingPointFormat(int w,
int d) |
FloatingPointFormat(int w,
int d,
boolean trailingZeros) |
| Modifier and Type | Method and Description |
|---|---|
StringBuffer |
format(double number,
StringBuffer toAppendTo,
FieldPosition pos) |
String |
getRevision()
Returns the revision string.
|
static String |
pattern(int w,
int d) |
int |
width() |
applyLocalizedPattern, applyPattern, clone, equals, format, format, formatToCharacterIterator, getCurrency, getDecimalFormatSymbols, getGroupingSize, getMaximumFractionDigits, getMaximumIntegerDigits, getMinimumFractionDigits, getMinimumIntegerDigits, getMultiplier, getNegativePrefix, getNegativeSuffix, getPositivePrefix, getPositiveSuffix, getRoundingMode, hashCode, isDecimalSeparatorAlwaysShown, isParseBigDecimal, parse, setCurrency, setDecimalFormatSymbols, setDecimalSeparatorAlwaysShown, setGroupingSize, setGroupingUsed, setMaximumFractionDigits, setMaximumIntegerDigits, setMinimumFractionDigits, setMinimumIntegerDigits, setMultiplier, setNegativePrefix, setNegativeSuffix, setParseBigDecimal, setPositivePrefix, setPositiveSuffix, setRoundingMode, toLocalizedPattern, toPatternformat, format, getAvailableLocales, getCurrencyInstance, getCurrencyInstance, getInstance, getInstance, getIntegerInstance, getIntegerInstance, getNumberInstance, getNumberInstance, getPercentInstance, getPercentInstance, isGroupingUsed, isParseIntegerOnly, parse, parseObject, setParseIntegerOnlyformat, parseObjectprotected DecimalFormat nf
protected int width
protected int decimal
protected boolean trailing
public FloatingPointFormat()
public FloatingPointFormat(int digits)
public FloatingPointFormat(int w,
int d)
public FloatingPointFormat(int w,
int d,
boolean trailingZeros)
public StringBuffer format(double number, StringBuffer toAppendTo, FieldPosition pos)
format in class DecimalFormatpublic static String pattern(int w, int d)
public int width()
public String getRevision()
getRevision in interface RevisionHandlerCopyright © 2015 University of Waikato, Hamilton, NZ. All rights reserved.