event.getDescriptionForEntryType(getEntryTypeForPayment(calculateTotalAmountToPay( event, when))));
event.getDescriptionForEntryType(getEntryType()));
    private void checkIfCanAddAmount(BigDecimal amountToAdd, Event event, DateTime when) {	final BigDecimal amountToPay = calculateTotalAmountToPay(event, when);	if (getTotalAmount().compareTo(amountToPay) != 0 && amountToAdd.compareTo(amountToPay) != 0) {	    throw new DomainExceptionWithLabelFormatter(		    "error.accounting.postingRules.gratuity.DFAGratuityPR.amount.being.payed.must.be.equal.to.amout.in.debt",		    event.getDescriptionForEntryType(getEntryTypeForPayment(calculateTotalAmountToPay(			    event, when))));	}	if (amountToPay.compareTo(amountToAdd) != 0		&& amountToAdd.compareTo(getPartialPaymentAmount()) != 0) {	    final LabelFormatter percentageLabelFormatter = new LabelFormatter();	    percentageLabelFormatter.appendLabel(getPartialAcceptedPercentage().multiply(		    BigDecimal.valueOf(100)).toString());	    throw new DomainExceptionWithLabelFormatter(		    "error.accounting.postingRules.gratuity.DFAGratuityPR.invalid.partial.payment.value",		    event.getDescriptionForEntryType(getEntryTypeForPayment(calculateTotalAmountToPay(			    event, when))), percentageLabelFormatter);	}    }