org.milyn.edi.unedifact.d06b.PRPAID.SegmentGroup5 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d06b.PRPAID;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d06b.common.InsuranceCoverDescription;
import java.util.List;
import org.milyn.edi.unedifact.d06b.common.MonetaryAmount;
import org.milyn.edi.unedifact.d06b.common.Reference;
import org.milyn.edi.unedifact.d06b.common.PercentageDetails;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup5 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private InsuranceCoverDescription insuranceCoverDescription;
private List monetaryAmount;
private List reference;
private PercentageDetails percentageDetails;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(insuranceCoverDescription != null) {
nodeWriter.write("ICD");
nodeWriter.write(delimiters.getField());
insuranceCoverDescription.write(nodeWriter, delimiters);
}
if(monetaryAmount != null && !monetaryAmount.isEmpty()) {
for(MonetaryAmount monetaryAmountInst : monetaryAmount) {
nodeWriter.write("MOA");
nodeWriter.write(delimiters.getField());
monetaryAmountInst.write(nodeWriter, delimiters);
}
}
if(reference != null && !reference.isEmpty()) {
for(Reference referenceInst : reference) {
nodeWriter.write("RFF");
nodeWriter.write(delimiters.getField());
referenceInst.write(nodeWriter, delimiters);
}
}
if(percentageDetails != null) {
nodeWriter.write("PCD");
nodeWriter.write(delimiters.getField());
percentageDetails.write(nodeWriter, delimiters);
}
}
public InsuranceCoverDescription getInsuranceCoverDescription() {
return insuranceCoverDescription;
}
public SegmentGroup5 setInsuranceCoverDescription(InsuranceCoverDescription insuranceCoverDescription) {
this.insuranceCoverDescription = insuranceCoverDescription; return this;
}
public List getMonetaryAmount() {
return monetaryAmount;
}
public SegmentGroup5 setMonetaryAmount(List monetaryAmount) {
this.monetaryAmount = monetaryAmount; return this;
}
public List getReference() {
return reference;
}
public SegmentGroup5 setReference(List reference) {
this.reference = reference; return this;
}
public PercentageDetails getPercentageDetails() {
return percentageDetails;
}
public SegmentGroup5 setPercentageDetails(PercentageDetails percentageDetails) {
this.percentageDetails = percentageDetails; return this;
}
}