org.milyn.edi.unedifact.d97a.common.LINLineItem Maven / Gradle / Ivy
The newest version!
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d97a.common;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d97a.common.field.C212ItemNumberIdentification;
import org.milyn.edi.unedifact.d97a.common.field.C829SubLineInformation;
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 LINLineItem implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private String e1082LineItemNumber;
private String e1229ActionRequestNotificationCoded;
private C212ItemNumberIdentification c212ItemNumberIdentification;
private C829SubLineInformation c829SubLineInformation;
private BigDecimal e1222ConfigurationLevel;
private DABigDecimalDecoder e1222ConfigurationLevelEncoder;
private String e7083ConfigurationCoded;
public LINLineItem() {
e1222ConfigurationLevelEncoder = new DABigDecimalDecoder();
}
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = new StringWriter();
List nodeTokens = new ArrayList();
if(e1082LineItemNumber != null) {
nodeWriter.write(delimiters.escape(e1082LineItemNumber.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e1229ActionRequestNotificationCoded != null) {
nodeWriter.write(delimiters.escape(e1229ActionRequestNotificationCoded.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c212ItemNumberIdentification != null) {
c212ItemNumberIdentification.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c829SubLineInformation != null) {
c829SubLineInformation.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e1222ConfigurationLevel != null) {
nodeWriter.write(delimiters.escape(e1222ConfigurationLevelEncoder.encode(e1222ConfigurationLevel, delimiters)));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e7083ConfigurationCoded != null) {
nodeWriter.write(delimiters.escape(e7083ConfigurationCoded.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 getE1082LineItemNumber() {
return e1082LineItemNumber;
}
public LINLineItem setE1082LineItemNumber(String e1082LineItemNumber) {
this.e1082LineItemNumber = e1082LineItemNumber; return this;
}
public String getE1229ActionRequestNotificationCoded() {
return e1229ActionRequestNotificationCoded;
}
public LINLineItem setE1229ActionRequestNotificationCoded(String e1229ActionRequestNotificationCoded) {
this.e1229ActionRequestNotificationCoded = e1229ActionRequestNotificationCoded; return this;
}
public C212ItemNumberIdentification getC212ItemNumberIdentification() {
return c212ItemNumberIdentification;
}
public LINLineItem setC212ItemNumberIdentification(C212ItemNumberIdentification c212ItemNumberIdentification) {
this.c212ItemNumberIdentification = c212ItemNumberIdentification; return this;
}
public C829SubLineInformation getC829SubLineInformation() {
return c829SubLineInformation;
}
public LINLineItem setC829SubLineInformation(C829SubLineInformation c829SubLineInformation) {
this.c829SubLineInformation = c829SubLineInformation; return this;
}
public BigDecimal getE1222ConfigurationLevel() {
return e1222ConfigurationLevel;
}
public LINLineItem setE1222ConfigurationLevel(BigDecimal e1222ConfigurationLevel) {
this.e1222ConfigurationLevel = e1222ConfigurationLevel; return this;
}
public String getE7083ConfigurationCoded() {
return e7083ConfigurationCoded;
}
public LINLineItem setE7083ConfigurationCoded(String e7083ConfigurationCoded) {
this.e7083ConfigurationCoded = e7083ConfigurationCoded; return this;
}
}