org.milyn.edi.unedifact.d03b.SLSRPT.SegmentGroup10 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d03b.SLSRPT;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d03b.common.Quantity;
import org.milyn.edi.unedifact.d03b.common.MarketSalesChannelInformation;
import org.milyn.edi.unedifact.d03b.common.NameAndAddress;
import java.util.List;
import org.milyn.edi.unedifact.d03b.common.PriceDetails;
import org.milyn.edi.unedifact.d03b.common.DateTimePeriod;
import org.milyn.edi.unedifact.d03b.common.Reference;
import org.milyn.edi.unedifact.d03b.common.Status;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup10 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private Quantity quantity;
private MarketSalesChannelInformation marketSalesChannelInformation;
private NameAndAddress nameAndAddress;
private List priceDetails;
private List dateTimePeriod;
private List reference;
private List status;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(quantity != null) {
nodeWriter.write("QTY");
nodeWriter.write(delimiters.getField());
quantity.write(nodeWriter, delimiters);
}
if(marketSalesChannelInformation != null) {
nodeWriter.write("MKS");
nodeWriter.write(delimiters.getField());
marketSalesChannelInformation.write(nodeWriter, delimiters);
}
if(nameAndAddress != null) {
nodeWriter.write("NAD");
nodeWriter.write(delimiters.getField());
nameAndAddress.write(nodeWriter, delimiters);
}
if(priceDetails != null && !priceDetails.isEmpty()) {
for(PriceDetails priceDetailsInst : priceDetails) {
nodeWriter.write("PRI");
nodeWriter.write(delimiters.getField());
priceDetailsInst.write(nodeWriter, delimiters);
}
}
if(dateTimePeriod != null && !dateTimePeriod.isEmpty()) {
for(DateTimePeriod dateTimePeriodInst : dateTimePeriod) {
nodeWriter.write("DTM");
nodeWriter.write(delimiters.getField());
dateTimePeriodInst.write(nodeWriter, delimiters);
}
}
if(reference != null && !reference.isEmpty()) {
for(Reference referenceInst : reference) {
nodeWriter.write("RFF");
nodeWriter.write(delimiters.getField());
referenceInst.write(nodeWriter, delimiters);
}
}
if(status != null && !status.isEmpty()) {
for(Status statusInst : status) {
nodeWriter.write("STS");
nodeWriter.write(delimiters.getField());
statusInst.write(nodeWriter, delimiters);
}
}
}
public Quantity getQuantity() {
return quantity;
}
public SegmentGroup10 setQuantity(Quantity quantity) {
this.quantity = quantity; return this;
}
public MarketSalesChannelInformation getMarketSalesChannelInformation() {
return marketSalesChannelInformation;
}
public SegmentGroup10 setMarketSalesChannelInformation(MarketSalesChannelInformation marketSalesChannelInformation) {
this.marketSalesChannelInformation = marketSalesChannelInformation; return this;
}
public NameAndAddress getNameAndAddress() {
return nameAndAddress;
}
public SegmentGroup10 setNameAndAddress(NameAndAddress nameAndAddress) {
this.nameAndAddress = nameAndAddress; return this;
}
public List getPriceDetails() {
return priceDetails;
}
public SegmentGroup10 setPriceDetails(List priceDetails) {
this.priceDetails = priceDetails; return this;
}
public List getDateTimePeriod() {
return dateTimePeriod;
}
public SegmentGroup10 setDateTimePeriod(List dateTimePeriod) {
this.dateTimePeriod = dateTimePeriod; return this;
}
public List getReference() {
return reference;
}
public SegmentGroup10 setReference(List reference) {
this.reference = reference; return this;
}
public List getStatus() {
return status;
}
public SegmentGroup10 setStatus(List status) {
this.status = status; return this;
}
}