org.milyn.edi.unedifact.d03b.IFTMCA.SegmentGroup30 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d03b.IFTMCA;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d03b.common.ChargeRateCalculations;
import java.util.List;
import org.milyn.edi.unedifact.d03b.common.MonetaryAmount;
import org.milyn.edi.unedifact.d03b.common.PercentageDetails;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup30 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private ChargeRateCalculations chargeRateCalculations;
private List monetaryAmount;
private PercentageDetails percentageDetails;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(chargeRateCalculations != null) {
nodeWriter.write("TCC");
nodeWriter.write(delimiters.getField());
chargeRateCalculations.write(nodeWriter, delimiters);
}
if(monetaryAmount != null && !monetaryAmount.isEmpty()) {
for(MonetaryAmount monetaryAmountInst : monetaryAmount) {
nodeWriter.write("MOA");
nodeWriter.write(delimiters.getField());
monetaryAmountInst.write(nodeWriter, delimiters);
}
}
if(percentageDetails != null) {
nodeWriter.write("PCD");
nodeWriter.write(delimiters.getField());
percentageDetails.write(nodeWriter, delimiters);
}
}
public ChargeRateCalculations getChargeRateCalculations() {
return chargeRateCalculations;
}
public SegmentGroup30 setChargeRateCalculations(ChargeRateCalculations chargeRateCalculations) {
this.chargeRateCalculations = chargeRateCalculations; return this;
}
public List getMonetaryAmount() {
return monetaryAmount;
}
public SegmentGroup30 setMonetaryAmount(List monetaryAmount) {
this.monetaryAmount = monetaryAmount; return this;
}
public PercentageDetails getPercentageDetails() {
return percentageDetails;
}
public SegmentGroup30 setPercentageDetails(PercentageDetails percentageDetails) {
this.percentageDetails = percentageDetails; return this;
}
}