org.milyn.edi.unedifact.d05a.INSPRE.SegmentGroup4 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d05a.INSPRE;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d05a.common.InsuranceCoverDescription;
import org.milyn.edi.unedifact.d05a.common.FreeText;
import java.util.List;
import org.milyn.edi.unedifact.d05a.common.Reference;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup4 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private InsuranceCoverDescription insuranceCoverDescription;
private FreeText freeText;
private List reference;
private List segmentGroup5;
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(freeText != null) {
nodeWriter.write("FTX");
nodeWriter.write(delimiters.getField());
freeText.write(nodeWriter, delimiters);
}
if(reference != null && !reference.isEmpty()) {
for(Reference referenceInst : reference) {
nodeWriter.write("RFF");
nodeWriter.write(delimiters.getField());
referenceInst.write(nodeWriter, delimiters);
}
}
if(segmentGroup5 != null && !segmentGroup5.isEmpty()) {
for(SegmentGroup5 segmentGroup5Inst : segmentGroup5) {
segmentGroup5Inst.write(nodeWriter, delimiters);
}
}
}
public InsuranceCoverDescription getInsuranceCoverDescription() {
return insuranceCoverDescription;
}
public SegmentGroup4 setInsuranceCoverDescription(InsuranceCoverDescription insuranceCoverDescription) {
this.insuranceCoverDescription = insuranceCoverDescription; return this;
}
public FreeText getFreeText() {
return freeText;
}
public SegmentGroup4 setFreeText(FreeText freeText) {
this.freeText = freeText; return this;
}
public List getReference() {
return reference;
}
public SegmentGroup4 setReference(List reference) {
this.reference = reference; return this;
}
public List getSegmentGroup5() {
return segmentGroup5;
}
public SegmentGroup4 setSegmentGroup5(List segmentGroup5) {
this.segmentGroup5 = segmentGroup5; return this;
}
}