Code example for BigDecimal

Methods: divide, equals

0
		return scoreFormatter.formatScore(score, format);
	} 
 
	public static String formatMoney(final Money money, final Configuration configuration) {
		final BigDecimal cents = money.getAmount();
		final BigDecimal units = cents.divide(CENTS_FOR_UNIT);
 
		String currencyName = Money.getApplicationCurrencyNamePlural();
		if (units.equals(BigDecimal.ONE)) {
			currencyName = Money.getApplicationCurrencyNameSingular();
		} 
 
		return String.format(configuration.getMoneyFormat(), units, currencyName);
	} 
 
	public static String formatRanking(final Context context, final Ranking ranking, final Configuration configuration) {
		if (ranking == null) {
			return ""; 
		} 
		final int total = ranking.getTotal();
		if (total == 0) {