org.milyn.edi.unedifact.d06b.PRICAT.SegmentGroup59 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d06b.PRICAT;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d06b.common.NameAndAddress;
import java.util.List;
import org.milyn.edi.unedifact.d06b.common.AdditionalProductId;
import org.milyn.edi.unedifact.d06b.common.Quantity;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup59 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private NameAndAddress nameAndAddress;
private List additionalProductId;
private List quantity;
private List segmentGroup60;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(nameAndAddress != null) {
nodeWriter.write("NAD");
nodeWriter.write(delimiters.getField());
nameAndAddress.write(nodeWriter, delimiters);
}
if(additionalProductId != null && !additionalProductId.isEmpty()) {
for(AdditionalProductId additionalProductIdInst : additionalProductId) {
nodeWriter.write("PIA");
nodeWriter.write(delimiters.getField());
additionalProductIdInst.write(nodeWriter, delimiters);
}
}
if(quantity != null && !quantity.isEmpty()) {
for(Quantity quantityInst : quantity) {
nodeWriter.write("QTY");
nodeWriter.write(delimiters.getField());
quantityInst.write(nodeWriter, delimiters);
}
}
if(segmentGroup60 != null && !segmentGroup60.isEmpty()) {
for(SegmentGroup60 segmentGroup60Inst : segmentGroup60) {
segmentGroup60Inst.write(nodeWriter, delimiters);
}
}
}
public NameAndAddress getNameAndAddress() {
return nameAndAddress;
}
public SegmentGroup59 setNameAndAddress(NameAndAddress nameAndAddress) {
this.nameAndAddress = nameAndAddress; return this;
}
public List getAdditionalProductId() {
return additionalProductId;
}
public SegmentGroup59 setAdditionalProductId(List additionalProductId) {
this.additionalProductId = additionalProductId; return this;
}
public List getQuantity() {
return quantity;
}
public SegmentGroup59 setQuantity(List quantity) {
this.quantity = quantity; return this;
}
public List getSegmentGroup60() {
return segmentGroup60;
}
public SegmentGroup59 setSegmentGroup60(List segmentGroup60) {
this.segmentGroup60 = segmentGroup60; return this;
}
}