org.milyn.edi.unedifact.d99b.common.DFNDefinitionFunction Maven / Gradle / Ivy
The newest version!
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d99b.common;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
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 DFNDefinitionFunction implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private String e9023DefinitionFunctionCoded;
private String e9025DefinitionExtentCoded;
private String e4519DefinitionIdentification;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = new StringWriter();
List nodeTokens = new ArrayList();
if(e9023DefinitionFunctionCoded != null) {
nodeWriter.write(delimiters.escape(e9023DefinitionFunctionCoded.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e9025DefinitionExtentCoded != null) {
nodeWriter.write(delimiters.escape(e9025DefinitionExtentCoded.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e4519DefinitionIdentification != null) {
nodeWriter.write(delimiters.escape(e4519DefinitionIdentification.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 getE9023DefinitionFunctionCoded() {
return e9023DefinitionFunctionCoded;
}
public DFNDefinitionFunction setE9023DefinitionFunctionCoded(String e9023DefinitionFunctionCoded) {
this.e9023DefinitionFunctionCoded = e9023DefinitionFunctionCoded; return this;
}
public String getE9025DefinitionExtentCoded() {
return e9025DefinitionExtentCoded;
}
public DFNDefinitionFunction setE9025DefinitionExtentCoded(String e9025DefinitionExtentCoded) {
this.e9025DefinitionExtentCoded = e9025DefinitionExtentCoded; return this;
}
public String getE4519DefinitionIdentification() {
return e4519DefinitionIdentification;
}
public DFNDefinitionFunction setE4519DefinitionIdentification(String e4519DefinitionIdentification) {
this.e4519DefinitionIdentification = e4519DefinitionIdentification; return this;
}
}