package net.sourceforge.fenixedu.dataTransferObject.accounting.penaltyExemption; import java.io.Serializable; import java.util.ArrayList; import java.util.List; import net.sourceforge.fenixedu.domain.DomainReference; import net.sourceforge.fenixedu.domain.accounting.Installment; import net.sourceforge.fenixedu.domain.accounting.events.gratuity.GratuityEventWithPaymentPlan; public class CreateInstallmentPenaltyExemptionBean extends CreatePenaltyExemptionBean implements Serializable { private List> installments; public CreateInstallmentPenaltyExemptionBean(GratuityEventWithPaymentPlan gratuityEventWithPaymentPlan) { super(gratuityEventWithPaymentPlan); setGratuityEventWithPaymentPlan(gratuityEventWithPaymentPlan); setInstallments(new ArrayList()); } public GratuityEventWithPaymentPlan getGratuityEventWithPaymentPlan() { return (GratuityEventWithPaymentPlan) getEvent(); } private void setGratuityEventWithPaymentPlan(GratuityEventWithPaymentPlan gratuityEventWithPaymentPlan) { setEvent(gratuityEventWithPaymentPlan); } public List getInstallments() { final List result = new ArrayList(); for (final DomainReference installment : installments) { result.add(installment.getObject()); } return result; } public void setInstallments(List installments) { final List> result = new ArrayList>(); for (final Installment installment : installments) { result.add(new DomainReference(installment)); } this.installments = result; } }