class MoneyUtils {

    public static BigDecimal getNetAmount(final BigDecimal money, final BigDecimal taxRate, final boolean taxIncluded) {
        if (money == null) {
            return Total.ZERO;
        }
        if (taxIncluded) {
            return money.subtract(getTaxAmount(money, taxRate, taxIncluded));
        }
        // taxes excluded so this is net
        return money;
    }

    private  MoneyUtils();

}