org.milyn.edi.unedifact.d05a.CREMUL.SegmentGroup16 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d05a.CREMUL;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d05a.common.ProcessingInformation;
import org.milyn.edi.unedifact.d05a.common.MonetaryAmount;
import java.util.List;
import org.milyn.edi.unedifact.d05a.common.PlaceLocationIdentification;
import org.milyn.edi.unedifact.d05a.common.NameAndAddress;
import org.milyn.edi.unedifact.d05a.common.RequirementsAndConditions;
import org.milyn.edi.unedifact.d05a.common.FreeText;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup16 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private ProcessingInformation processingInformation;
private MonetaryAmount monetaryAmount;
private List placeLocationIdentification;
private NameAndAddress nameAndAddress;
private RequirementsAndConditions requirementsAndConditions;
private List freeText;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(processingInformation != null) {
nodeWriter.write("GEI");
nodeWriter.write(delimiters.getField());
processingInformation.write(nodeWriter, delimiters);
}
if(monetaryAmount != null) {
nodeWriter.write("MOA");
nodeWriter.write(delimiters.getField());
monetaryAmount.write(nodeWriter, delimiters);
}
if(placeLocationIdentification != null && !placeLocationIdentification.isEmpty()) {
for(PlaceLocationIdentification placeLocationIdentificationInst : placeLocationIdentification) {
nodeWriter.write("LOC");
nodeWriter.write(delimiters.getField());
placeLocationIdentificationInst.write(nodeWriter, delimiters);
}
}
if(nameAndAddress != null) {
nodeWriter.write("NAD");
nodeWriter.write(delimiters.getField());
nameAndAddress.write(nodeWriter, delimiters);
}
if(requirementsAndConditions != null) {
nodeWriter.write("RCS");
nodeWriter.write(delimiters.getField());
requirementsAndConditions.write(nodeWriter, delimiters);
}
if(freeText != null && !freeText.isEmpty()) {
for(FreeText freeTextInst : freeText) {
nodeWriter.write("FTX");
nodeWriter.write(delimiters.getField());
freeTextInst.write(nodeWriter, delimiters);
}
}
}
public ProcessingInformation getProcessingInformation() {
return processingInformation;
}
public SegmentGroup16 setProcessingInformation(ProcessingInformation processingInformation) {
this.processingInformation = processingInformation; return this;
}
public MonetaryAmount getMonetaryAmount() {
return monetaryAmount;
}
public SegmentGroup16 setMonetaryAmount(MonetaryAmount monetaryAmount) {
this.monetaryAmount = monetaryAmount; return this;
}
public List getPlaceLocationIdentification() {
return placeLocationIdentification;
}
public SegmentGroup16 setPlaceLocationIdentification(List placeLocationIdentification) {
this.placeLocationIdentification = placeLocationIdentification; return this;
}
public NameAndAddress getNameAndAddress() {
return nameAndAddress;
}
public SegmentGroup16 setNameAndAddress(NameAndAddress nameAndAddress) {
this.nameAndAddress = nameAndAddress; return this;
}
public RequirementsAndConditions getRequirementsAndConditions() {
return requirementsAndConditions;
}
public SegmentGroup16 setRequirementsAndConditions(RequirementsAndConditions requirementsAndConditions) {
this.requirementsAndConditions = requirementsAndConditions; return this;
}
public List getFreeText() {
return freeText;
}
public SegmentGroup16 setFreeText(List freeText) {
this.freeText = freeText; return this;
}
}