org.milyn.edi.unedifact.d13b.common.EVEEvent Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d13b.common;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d13b.common.field.C004EventCategory;
import org.milyn.edi.unedifact.d13b.common.field.C030EventType;
import org.milyn.edi.unedifact.d13b.common.field.C063EventIdentification;
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 EVEEvent implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private String e9635EventDetailsCodeQualifier;
private C004EventCategory c004EventCategory;
private C030EventType c030EventType;
private C063EventIdentification c063EventIdentification;
private String e1229ActionCode;
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = new StringWriter();
List nodeTokens = new ArrayList();
if(e9635EventDetailsCodeQualifier != null) {
nodeWriter.write(delimiters.escape(e9635EventDetailsCodeQualifier.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c004EventCategory != null) {
c004EventCategory.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c030EventType != null) {
c030EventType.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c063EventIdentification != null) {
c063EventIdentification.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e1229ActionCode != null) {
nodeWriter.write(delimiters.escape(e1229ActionCode.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 getE9635EventDetailsCodeQualifier() {
return e9635EventDetailsCodeQualifier;
}
public EVEEvent setE9635EventDetailsCodeQualifier(String e9635EventDetailsCodeQualifier) {
this.e9635EventDetailsCodeQualifier = e9635EventDetailsCodeQualifier; return this;
}
public C004EventCategory getC004EventCategory() {
return c004EventCategory;
}
public EVEEvent setC004EventCategory(C004EventCategory c004EventCategory) {
this.c004EventCategory = c004EventCategory; return this;
}
public C030EventType getC030EventType() {
return c030EventType;
}
public EVEEvent setC030EventType(C030EventType c030EventType) {
this.c030EventType = c030EventType; return this;
}
public C063EventIdentification getC063EventIdentification() {
return c063EventIdentification;
}
public EVEEvent setC063EventIdentification(C063EventIdentification c063EventIdentification) {
this.c063EventIdentification = c063EventIdentification; return this;
}
public String getE1229ActionCode() {
return e1229ActionCode;
}
public EVEEvent setE1229ActionCode(String e1229ActionCode) {
this.e1229ActionCode = e1229ActionCode; return this;
}
}