All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.milyn.edi.unedifact.d05a.INSREQ.SegmentGroup8 Maven / Gradle / Ivy

There is a newer version: 1.7.1.0
Show newest version
/**
 * This class was generated by Smooks EJC (http://www.smooks.org).
 */
package org.milyn.edi.unedifact.d05a.INSREQ;

import java.io.Serializable;    
import org.milyn.smooks.edi.EDIWritable;    
import org.milyn.edi.unedifact.d05a.common.NameAndAddress;    
import java.util.List;    
import org.milyn.edi.unedifact.d05a.common.ProcessingInformation;    
import org.milyn.edi.unedifact.d05a.common.PlaceLocationIdentification;    
import org.milyn.edi.unedifact.d05a.common.Quantity;    
import org.milyn.edi.unedifact.d05a.common.QuantityVariances;    
import org.milyn.edi.unedifact.d05a.common.Reference;    
import org.milyn.edi.unedifact.d05a.common.FreeText;    
import java.io.Writer;    
import org.milyn.edisax.model.internal.Delimiters;    
import java.io.IOException;    

public class SegmentGroup8 implements Serializable, EDIWritable {

    private static final long serialVersionUID = 1L;

    private NameAndAddress nameAndAddress;
    private List processingInformation;
    private List placeLocationIdentification;
    private List quantity;
    private List quantityVariances;
    private List reference;
    private List freeText;
    private List segmentGroup9;

    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(processingInformation != null && !processingInformation.isEmpty()) {
            for(ProcessingInformation processingInformationInst : processingInformation) {
                nodeWriter.write("GEI");
                nodeWriter.write(delimiters.getField());
                processingInformationInst.write(nodeWriter, delimiters);
            }
        }
        if(placeLocationIdentification != null && !placeLocationIdentification.isEmpty()) {
            for(PlaceLocationIdentification placeLocationIdentificationInst : placeLocationIdentification) {
                nodeWriter.write("LOC");
                nodeWriter.write(delimiters.getField());
                placeLocationIdentificationInst.write(nodeWriter, delimiters);
            }
        }
        if(quantity != null && !quantity.isEmpty()) {
            for(Quantity quantityInst : quantity) {
                nodeWriter.write("QTY");
                nodeWriter.write(delimiters.getField());
                quantityInst.write(nodeWriter, delimiters);
            }
        }
        if(quantityVariances != null && !quantityVariances.isEmpty()) {
            for(QuantityVariances quantityVariancesInst : quantityVariances) {
                nodeWriter.write("QVR");
                nodeWriter.write(delimiters.getField());
                quantityVariancesInst.write(nodeWriter, delimiters);
            }
        }
        if(reference != null && !reference.isEmpty()) {
            for(Reference referenceInst : reference) {
                nodeWriter.write("RFF");
                nodeWriter.write(delimiters.getField());
                referenceInst.write(nodeWriter, delimiters);
            }
        }
        if(freeText != null && !freeText.isEmpty()) {
            for(FreeText freeTextInst : freeText) {
                nodeWriter.write("FTX");
                nodeWriter.write(delimiters.getField());
                freeTextInst.write(nodeWriter, delimiters);
            }
        }
        if(segmentGroup9 != null && !segmentGroup9.isEmpty()) {
            for(SegmentGroup9 segmentGroup9Inst : segmentGroup9) {
                segmentGroup9Inst.write(nodeWriter, delimiters);
            }
        }
    }

    public NameAndAddress getNameAndAddress() {
        return nameAndAddress;
    }

    public SegmentGroup8 setNameAndAddress(NameAndAddress nameAndAddress) {
        this.nameAndAddress = nameAndAddress;  return this;
    }

    public List getProcessingInformation() {
        return processingInformation;
    }

    public SegmentGroup8 setProcessingInformation(List processingInformation) {
        this.processingInformation = processingInformation;  return this;
    }

    public List getPlaceLocationIdentification() {
        return placeLocationIdentification;
    }

    public SegmentGroup8 setPlaceLocationIdentification(List placeLocationIdentification) {
        this.placeLocationIdentification = placeLocationIdentification;  return this;
    }

    public List getQuantity() {
        return quantity;
    }

    public SegmentGroup8 setQuantity(List quantity) {
        this.quantity = quantity;  return this;
    }

    public List getQuantityVariances() {
        return quantityVariances;
    }

    public SegmentGroup8 setQuantityVariances(List quantityVariances) {
        this.quantityVariances = quantityVariances;  return this;
    }

    public List getReference() {
        return reference;
    }

    public SegmentGroup8 setReference(List reference) {
        this.reference = reference;  return this;
    }

    public List getFreeText() {
        return freeText;
    }

    public SegmentGroup8 setFreeText(List freeText) {
        this.freeText = freeText;  return this;
    }

    public List getSegmentGroup9() {
        return segmentGroup9;
    }

    public SegmentGroup8 setSegmentGroup9(List segmentGroup9) {
        this.segmentGroup9 = segmentGroup9;  return this;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy