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

org.milyn.edi.unedifact.d06b.CUSCAR.SegmentGroup15 Maven / Gradle / Ivy

/**
 * This class was generated by Smooks EJC (http://www.smooks.org).
 */
package org.milyn.edi.unedifact.d06b.CUSCAR;

import java.io.Serializable;    
import org.milyn.smooks.edi.EDIWritable;    
import org.milyn.edi.unedifact.d06b.common.ProcessingInformation;    
import java.util.List;    
import org.milyn.edi.unedifact.d06b.common.DateTimePeriod;    
import org.milyn.edi.unedifact.d06b.common.DocumentMessageDetails;    
import org.milyn.edi.unedifact.d06b.common.Package;    
import org.milyn.edi.unedifact.d06b.common.Measurements;    
import java.io.Writer;    
import org.milyn.edisax.model.internal.Delimiters;    
import java.io.IOException;    

public class SegmentGroup15 implements Serializable, EDIWritable {

    private static final long serialVersionUID = 1L;

    private ProcessingInformation processingInformation;
    private List dateTimePeriod;
    private List documentMessageDetails;
    private List _package;
    private List measurements;

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

        if(processingInformation != null) {
            nodeWriter.write("GEI");
            nodeWriter.write(delimiters.getField());
            processingInformation.write(nodeWriter, delimiters);
        }
        if(dateTimePeriod != null && !dateTimePeriod.isEmpty()) {
            for(DateTimePeriod dateTimePeriodInst : dateTimePeriod) {
                nodeWriter.write("DTM");
                nodeWriter.write(delimiters.getField());
                dateTimePeriodInst.write(nodeWriter, delimiters);
            }
        }
        if(documentMessageDetails != null && !documentMessageDetails.isEmpty()) {
            for(DocumentMessageDetails documentMessageDetailsInst : documentMessageDetails) {
                nodeWriter.write("DOC");
                nodeWriter.write(delimiters.getField());
                documentMessageDetailsInst.write(nodeWriter, delimiters);
            }
        }
        if(_package != null && !_package.isEmpty()) {
            for(Package _packageInst : _package) {
                nodeWriter.write("PAC");
                nodeWriter.write(delimiters.getField());
                _packageInst.write(nodeWriter, delimiters);
            }
        }
        if(measurements != null && !measurements.isEmpty()) {
            for(Measurements measurementsInst : measurements) {
                nodeWriter.write("MEA");
                nodeWriter.write(delimiters.getField());
                measurementsInst.write(nodeWriter, delimiters);
            }
        }
    }

    public ProcessingInformation getProcessingInformation() {
        return processingInformation;
    }

    public SegmentGroup15 setProcessingInformation(ProcessingInformation processingInformation) {
        this.processingInformation = processingInformation;  return this;
    }

    public List getDateTimePeriod() {
        return dateTimePeriod;
    }

    public SegmentGroup15 setDateTimePeriod(List dateTimePeriod) {
        this.dateTimePeriod = dateTimePeriod;  return this;
    }

    public List getDocumentMessageDetails() {
        return documentMessageDetails;
    }

    public SegmentGroup15 setDocumentMessageDetails(List documentMessageDetails) {
        this.documentMessageDetails = documentMessageDetails;  return this;
    }

    public List get_package() {
        return _package;
    }

    public SegmentGroup15 set_package(List _package) {
        this._package = _package;  return this;
    }

    public List getMeasurements() {
        return measurements;
    }

    public SegmentGroup15 setMeasurements(List measurements) {
        this.measurements = measurements;  return this;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy