org.milyn.edi.unedifact.d09b.common.ELUDataElementUsageDetails Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d09b.common;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import java.math.BigDecimal;
import org.milyn.javabean.decoders.DABigDecimalDecoder;
import java.io.Writer;
import org.milyn.edisax.model.internal.Delimiters;
import java.io.IOException;
import java.io.StringWriter;
import java.util.List;
import java.util.ArrayList;
import org.milyn.edisax.util.EDIUtils;
import org.milyn.edisax.model.internal.DelimiterType;
public class ELUDataElementUsageDetails implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private String e9162DataElementTagIdentifier;
private String e7299RequirementDesignatorCode;
private String e1050SequencePositionIdentifier;
private String e4513MaintenanceOperationCode;
private BigDecimal e6176OccurrencesMaximumNumber;
private DABigDecimalDecoder e6176OccurrencesMaximumNumberEncoder;
private String e9453CodeValueSourceCode;
private String e9285ValidationCriteriaCode;
private String e9175DataElementUsageTypeCode;
public ELUDataElementUsageDetails() {
e6176OccurrencesMaximumNumberEncoder = new DABigDecimalDecoder();
}
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = new StringWriter();
List nodeTokens = new ArrayList();
if(e9162DataElementTagIdentifier != null) {
nodeWriter.write(delimiters.escape(e9162DataElementTagIdentifier.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e7299RequirementDesignatorCode != null) {
nodeWriter.write(delimiters.escape(e7299RequirementDesignatorCode.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e1050SequencePositionIdentifier != null) {
nodeWriter.write(delimiters.escape(e1050SequencePositionIdentifier.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e4513MaintenanceOperationCode != null) {
nodeWriter.write(delimiters.escape(e4513MaintenanceOperationCode.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e6176OccurrencesMaximumNumber != null) {
nodeWriter.write(delimiters.escape(e6176OccurrencesMaximumNumberEncoder.encode(e6176OccurrencesMaximumNumber, delimiters)));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e9453CodeValueSourceCode != null) {
nodeWriter.write(delimiters.escape(e9453CodeValueSourceCode.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e9285ValidationCriteriaCode != null) {
nodeWriter.write(delimiters.escape(e9285ValidationCriteriaCode.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e9175DataElementUsageTypeCode != null) {
nodeWriter.write(delimiters.escape(e9175DataElementUsageTypeCode.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeTokens.add(nodeWriter.toString());
writer.write(EDIUtils.concatAndTruncate(nodeTokens, DelimiterType.FIELD, delimiters));
writer.write(delimiters.getSegmentDelimiter());
writer.flush();
}
public String getE9162DataElementTagIdentifier() {
return e9162DataElementTagIdentifier;
}
public ELUDataElementUsageDetails setE9162DataElementTagIdentifier(String e9162DataElementTagIdentifier) {
this.e9162DataElementTagIdentifier = e9162DataElementTagIdentifier; return this;
}
public String getE7299RequirementDesignatorCode() {
return e7299RequirementDesignatorCode;
}
public ELUDataElementUsageDetails setE7299RequirementDesignatorCode(String e7299RequirementDesignatorCode) {
this.e7299RequirementDesignatorCode = e7299RequirementDesignatorCode; return this;
}
public String getE1050SequencePositionIdentifier() {
return e1050SequencePositionIdentifier;
}
public ELUDataElementUsageDetails setE1050SequencePositionIdentifier(String e1050SequencePositionIdentifier) {
this.e1050SequencePositionIdentifier = e1050SequencePositionIdentifier; return this;
}
public String getE4513MaintenanceOperationCode() {
return e4513MaintenanceOperationCode;
}
public ELUDataElementUsageDetails setE4513MaintenanceOperationCode(String e4513MaintenanceOperationCode) {
this.e4513MaintenanceOperationCode = e4513MaintenanceOperationCode; return this;
}
public BigDecimal getE6176OccurrencesMaximumNumber() {
return e6176OccurrencesMaximumNumber;
}
public ELUDataElementUsageDetails setE6176OccurrencesMaximumNumber(BigDecimal e6176OccurrencesMaximumNumber) {
this.e6176OccurrencesMaximumNumber = e6176OccurrencesMaximumNumber; return this;
}
public String getE9453CodeValueSourceCode() {
return e9453CodeValueSourceCode;
}
public ELUDataElementUsageDetails setE9453CodeValueSourceCode(String e9453CodeValueSourceCode) {
this.e9453CodeValueSourceCode = e9453CodeValueSourceCode; return this;
}
public String getE9285ValidationCriteriaCode() {
return e9285ValidationCriteriaCode;
}
public ELUDataElementUsageDetails setE9285ValidationCriteriaCode(String e9285ValidationCriteriaCode) {
this.e9285ValidationCriteriaCode = e9285ValidationCriteriaCode; return this;
}
public String getE9175DataElementUsageTypeCode() {
return e9175DataElementUsageTypeCode;
}
public ELUDataElementUsageDetails setE9175DataElementUsageTypeCode(String e9175DataElementUsageTypeCode) {
this.e9175DataElementUsageTypeCode = e9175DataElementUsageTypeCode; return this;
}
}