public class NumberFormatUtil
extends java.lang.Object
Constructor and Description |
---|
NumberFormatUtil() |
Modifier and Type | Method and Description |
---|---|
static java.text.DecimalFormat |
getDecimalFormat()
handles the localization problem (bug 0000294) by always returning a DecimalFormat
for Locale.US.
|
static java.text.DecimalFormat |
getDecimalFormat(java.lang.String spec)
handles the localization problem (bug 0000294) by always returning a DecimalFormat
for Locale.US.
|
public static java.text.DecimalFormat getDecimalFormat()
java.lang.ClassCastException
- if for some reason, NumberFormat.getInstance doesn't return DecimalFormat.public static java.text.DecimalFormat getDecimalFormat(java.lang.String spec)
spec
- e.g. 1E0java.lang.ClassCastException
- if for some reason, NumberFormat.getInstance doesn't return DecimalFormat.