private static Object formatBigDecimal(Object number, Locale locale) { NumberFormat nf = NumberFormat.getNumberInstance(locale); nf.setMinimumFractionDigits(2); return nf.format(number); }
private NumberFormat getFormat() { NumberFormat f = DecimalFormat.getNumberInstance(Locales.getCurrent()); f.setMinimumFractionDigits(2); f.setMaximumFractionDigits(2); return f; }