org.milyn.edi.unedifact.d02a.WASDIS.SegmentGroup6 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d02a.WASDIS;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d02a.common.DangerousGoods;
import org.milyn.edi.unedifact.d02a.common.Measurements;
import java.util.List;
import org.milyn.edi.unedifact.d02a.common.SplitGoodsPlacement;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup6 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private DangerousGoods dangerousGoods;
private Measurements measurements;
private List splitGoodsPlacement;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(dangerousGoods != null) {
nodeWriter.write("DGS");
nodeWriter.write(delimiters.getField());
dangerousGoods.write(nodeWriter, delimiters);
}
if(measurements != null) {
nodeWriter.write("MEA");
nodeWriter.write(delimiters.getField());
measurements.write(nodeWriter, delimiters);
}
if(splitGoodsPlacement != null && !splitGoodsPlacement.isEmpty()) {
for(SplitGoodsPlacement splitGoodsPlacementInst : splitGoodsPlacement) {
nodeWriter.write("SGP");
nodeWriter.write(delimiters.getField());
splitGoodsPlacementInst.write(nodeWriter, delimiters);
}
}
}
public DangerousGoods getDangerousGoods() {
return dangerousGoods;
}
public SegmentGroup6 setDangerousGoods(DangerousGoods dangerousGoods) {
this.dangerousGoods = dangerousGoods; return this;
}
public Measurements getMeasurements() {
return measurements;
}
public SegmentGroup6 setMeasurements(Measurements measurements) {
this.measurements = measurements; return this;
}
public List getSplitGoodsPlacement() {
return splitGoodsPlacement;
}
public SegmentGroup6 setSplitGoodsPlacement(List splitGoodsPlacement) {
this.splitGoodsPlacement = splitGoodsPlacement; return this;
}
}