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

org.milyn.edi.unedifact.d98a.IFTIAG.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.d98a.IFTIAG;

import java.io.Serializable;    
import org.milyn.smooks.edi.EDIWritable;    
import org.milyn.edi.unedifact.d98a.common.GoodsItemDetails;    
import java.util.List;    
import org.milyn.edi.unedifact.d98a.common.FreeText;    
import org.milyn.edi.unedifact.d98a.common.PackageIdentification;    
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 GoodsItemDetails goodsItemDetails;
    private List freeText;
    private PackageIdentification packageIdentification;
    private SegmentGroup9 segmentGroup9;

    public void write(Writer writer, Delimiters delimiters) throws IOException {
        
        Writer nodeWriter = writer;

        if(goodsItemDetails != null) {
            nodeWriter.write("GID");
            nodeWriter.write(delimiters.getField());
            goodsItemDetails.write(nodeWriter, delimiters);
        }
        if(freeText != null && !freeText.isEmpty()) {
            for(FreeText freeTextInst : freeText) {
                nodeWriter.write("FTX");
                nodeWriter.write(delimiters.getField());
                freeTextInst.write(nodeWriter, delimiters);
            }
        }
        if(packageIdentification != null) {
            nodeWriter.write("PCI");
            nodeWriter.write(delimiters.getField());
            packageIdentification.write(nodeWriter, delimiters);
        }
        if(segmentGroup9 != null) {
            segmentGroup9.write(nodeWriter, delimiters);
        }
    }

    public GoodsItemDetails getGoodsItemDetails() {
        return goodsItemDetails;
    }

    public SegmentGroup8 setGoodsItemDetails(GoodsItemDetails goodsItemDetails) {
        this.goodsItemDetails = goodsItemDetails;  return this;
    }

    public List getFreeText() {
        return freeText;
    }

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

    public PackageIdentification getPackageIdentification() {
        return packageIdentification;
    }

    public SegmentGroup8 setPackageIdentification(PackageIdentification packageIdentification) {
        this.packageIdentification = packageIdentification;  return this;
    }

    public SegmentGroup9 getSegmentGroup9() {
        return segmentGroup9;
    }

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy