org.milyn.edi.unedifact.d99b.MEDPRE.SegmentGroup11 Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d99b.MEDPRE;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d99b.common.TermsOfDeliveryOrTransport;
import org.milyn.edi.unedifact.d99b.common.DetailsOfTransport;
import java.util.List;
import org.milyn.edi.unedifact.d99b.common.FreeText;
import org.milyn.edi.unedifact.d99b.common.DateTimePeriod;
import org.milyn.edi.unedifact.d99b.common.Address;
import org.milyn.edi.unedifact.d99b.common.CommunicationContact;
import org.milyn.edi.unedifact.d99b.common.PartyIdentification;
import org.milyn.edi.unedifact.d99b.common.Priority;
import org.milyn.edi.unedifact.d99b.common.Package;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
public class SegmentGroup11 implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private TermsOfDeliveryOrTransport termsOfDeliveryOrTransport;
private DetailsOfTransport detailsOfTransport;
private List freeText;
private List dateTimePeriod;
private Address address;
private List communicationContact;
private List partyIdentification;
private Priority priority;
private Package _package;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = writer;
if(termsOfDeliveryOrTransport != null) {
nodeWriter.write("TOD");
nodeWriter.write(delimiters.getField());
termsOfDeliveryOrTransport.write(nodeWriter, delimiters);
}
if(detailsOfTransport != null) {
nodeWriter.write("TDT");
nodeWriter.write(delimiters.getField());
detailsOfTransport.write(nodeWriter, delimiters);
}
if(freeText != null && !freeText.isEmpty()) {
for(FreeText freeTextInst : freeText) {
nodeWriter.write("FTX");
nodeWriter.write(delimiters.getField());
freeTextInst.write(nodeWriter, delimiters);
}
}
if(dateTimePeriod != null && !dateTimePeriod.isEmpty()) {
for(DateTimePeriod dateTimePeriodInst : dateTimePeriod) {
nodeWriter.write("DTM");
nodeWriter.write(delimiters.getField());
dateTimePeriodInst.write(nodeWriter, delimiters);
}
}
if(address != null) {
nodeWriter.write("ADR");
nodeWriter.write(delimiters.getField());
address.write(nodeWriter, delimiters);
}
if(communicationContact != null && !communicationContact.isEmpty()) {
for(CommunicationContact communicationContactInst : communicationContact) {
nodeWriter.write("COM");
nodeWriter.write(delimiters.getField());
communicationContactInst.write(nodeWriter, delimiters);
}
}
if(partyIdentification != null && !partyIdentification.isEmpty()) {
for(PartyIdentification partyIdentificationInst : partyIdentification) {
nodeWriter.write("PNA");
nodeWriter.write(delimiters.getField());
partyIdentificationInst.write(nodeWriter, delimiters);
}
}
if(priority != null) {
nodeWriter.write("PTY");
nodeWriter.write(delimiters.getField());
priority.write(nodeWriter, delimiters);
}
if(_package != null) {
nodeWriter.write("PAC");
nodeWriter.write(delimiters.getField());
_package.write(nodeWriter, delimiters);
}
}
public TermsOfDeliveryOrTransport getTermsOfDeliveryOrTransport() {
return termsOfDeliveryOrTransport;
}
public SegmentGroup11 setTermsOfDeliveryOrTransport(TermsOfDeliveryOrTransport termsOfDeliveryOrTransport) {
this.termsOfDeliveryOrTransport = termsOfDeliveryOrTransport; return this;
}
public DetailsOfTransport getDetailsOfTransport() {
return detailsOfTransport;
}
public SegmentGroup11 setDetailsOfTransport(DetailsOfTransport detailsOfTransport) {
this.detailsOfTransport = detailsOfTransport; return this;
}
public List getFreeText() {
return freeText;
}
public SegmentGroup11 setFreeText(List freeText) {
this.freeText = freeText; return this;
}
public List getDateTimePeriod() {
return dateTimePeriod;
}
public SegmentGroup11 setDateTimePeriod(List dateTimePeriod) {
this.dateTimePeriod = dateTimePeriod; return this;
}
public Address getAddress() {
return address;
}
public SegmentGroup11 setAddress(Address address) {
this.address = address; return this;
}
public List getCommunicationContact() {
return communicationContact;
}
public SegmentGroup11 setCommunicationContact(List communicationContact) {
this.communicationContact = communicationContact; return this;
}
public List getPartyIdentification() {
return partyIdentification;
}
public SegmentGroup11 setPartyIdentification(List partyIdentification) {
this.partyIdentification = partyIdentification; return this;
}
public Priority getPriority() {
return priority;
}
public SegmentGroup11 setPriority(Priority priority) {
this.priority = priority; return this;
}
public Package get_package() {
return _package;
}
public SegmentGroup11 set_package(Package _package) {
this._package = _package; return this;
}
}