org.milyn.edi.unedifact.d02a.HANMOV.SegmentGroup16 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d02a.HANMOV;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d02a.common.DateTimePeriod;
import java.util.List;
import org.milyn.edi.unedifact.d02a.common.Quantity;
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 DateTimePeriod dateTimePeriod;
private List quantity;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(dateTimePeriod != null) {
nodeWriter.write("DTM");
nodeWriter.write(delimiters.getField());
dateTimePeriod.write(nodeWriter, delimiters);
}
if(quantity != null && !quantity.isEmpty()) {
for(Quantity quantityInst : quantity) {
nodeWriter.write("QTY");
nodeWriter.write(delimiters.getField());
quantityInst.write(nodeWriter, delimiters);
}
}
}
public DateTimePeriod getDateTimePeriod() {
return dateTimePeriod;
}
public SegmentGroup16 setDateTimePeriod(DateTimePeriod dateTimePeriod) {
this.dateTimePeriod = dateTimePeriod; return this;
}
public List getQuantity() {
return quantity;
}
public SegmentGroup16 setQuantity(List quantity) {
this.quantity = quantity; return this;
}
}