org.milyn.edi.unedifact.d05a.JUPREQ.SegmentGroup7 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d05a.JUPREQ;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d05a.common.DocumentMessageSummary;
import java.util.List;
import org.milyn.edi.unedifact.d05a.common.Reference;
import org.milyn.edi.unedifact.d05a.common.NameAndAddress;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup7 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private DocumentMessageSummary documentMessageSummary;
private List reference;
private List nameAndAddress;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(documentMessageSummary != null) {
nodeWriter.write("DMS");
nodeWriter.write(delimiters.getField());
documentMessageSummary.write(nodeWriter, delimiters);
}
if(reference != null && !reference.isEmpty()) {
for(Reference referenceInst : reference) {
nodeWriter.write("RFF");
nodeWriter.write(delimiters.getField());
referenceInst.write(nodeWriter, delimiters);
}
}
if(nameAndAddress != null && !nameAndAddress.isEmpty()) {
for(NameAndAddress nameAndAddressInst : nameAndAddress) {
nodeWriter.write("NAD");
nodeWriter.write(delimiters.getField());
nameAndAddressInst.write(nodeWriter, delimiters);
}
}
}
public DocumentMessageSummary getDocumentMessageSummary() {
return documentMessageSummary;
}
public SegmentGroup7 setDocumentMessageSummary(DocumentMessageSummary documentMessageSummary) {
this.documentMessageSummary = documentMessageSummary; return this;
}
public List getReference() {
return reference;
}
public SegmentGroup7 setReference(List reference) {
this.reference = reference; return this;
}
public List getNameAndAddress() {
return nameAndAddress;
}
public SegmentGroup7 setNameAndAddress(List nameAndAddress) {
this.nameAndAddress = nameAndAddress; return this;
}
}