org.milyn.edi.unedifact.d02a.common.IDEIdentity Maven / Gradle / Ivy
/**
* This class was generated by Smooks EJC (http://www.smooks.org).
*/
package org.milyn.edi.unedifact.d02a.common;
import java.io.Serializable;
import org.milyn.smooks.edi.EDIWritable;
import org.milyn.edi.unedifact.d02a.common.field.C2061IdentificationNumber;
import org.milyn.edi.unedifact.d02a.common.field.C082PartyIdentificationDetails;
import java.math.BigDecimal;
import org.milyn.javabean.decoders.DABigDecimalDecoder;
import org.milyn.edi.unedifact.d02a.common.field.C778PositionIdentification;
import org.milyn.edi.unedifact.d02a.common.field.C240CharacteristicDescription;
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 IDEIdentity implements Serializable, EDIWritable {
private static final long serialVersionUID = 1L;
private String e7495ObjectTypeCodeQualifier;
private C2061IdentificationNumber c206IdentificationNumber;
private C082PartyIdentificationDetails c082PartyIdentificationDetails;
private String e4405StatusDescriptionCode;
private BigDecimal e1222ConfigurationLevelNumber;
private DABigDecimalDecoder e1222ConfigurationLevelNumberEncoder;
private C778PositionIdentification c778PositionIdentification;
private C240CharacteristicDescription c240CharacteristicDescription;
public IDEIdentity() {
e1222ConfigurationLevelNumberEncoder = new DABigDecimalDecoder();
}
public void write(Writer writer, Delimiters delimiters) throws IOException {
Writer nodeWriter = new StringWriter();
List nodeTokens = new ArrayList();
if(e7495ObjectTypeCodeQualifier != null) {
nodeWriter.write(delimiters.escape(e7495ObjectTypeCodeQualifier.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c206IdentificationNumber != null) {
c206IdentificationNumber.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c082PartyIdentificationDetails != null) {
c082PartyIdentificationDetails.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e4405StatusDescriptionCode != null) {
nodeWriter.write(delimiters.escape(e4405StatusDescriptionCode.toString()));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(e1222ConfigurationLevelNumber != null) {
nodeWriter.write(delimiters.escape(e1222ConfigurationLevelNumberEncoder.encode(e1222ConfigurationLevelNumber, delimiters)));
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c778PositionIdentification != null) {
c778PositionIdentification.write(nodeWriter, delimiters);
nodeTokens.add(nodeWriter.toString());
((StringWriter)nodeWriter).getBuffer().setLength(0);
}
nodeWriter.write(delimiters.getField());
if(c240CharacteristicDescription != null) {
c240CharacteristicDescription.write(nodeWriter, delimiters);
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 getE7495ObjectTypeCodeQualifier() {
return e7495ObjectTypeCodeQualifier;
}
public IDEIdentity setE7495ObjectTypeCodeQualifier(String e7495ObjectTypeCodeQualifier) {
this.e7495ObjectTypeCodeQualifier = e7495ObjectTypeCodeQualifier; return this;
}
public C2061IdentificationNumber getC206IdentificationNumber() {
return c206IdentificationNumber;
}
public IDEIdentity setC206IdentificationNumber(C2061IdentificationNumber c206IdentificationNumber) {
this.c206IdentificationNumber = c206IdentificationNumber; return this;
}
public C082PartyIdentificationDetails getC082PartyIdentificationDetails() {
return c082PartyIdentificationDetails;
}
public IDEIdentity setC082PartyIdentificationDetails(C082PartyIdentificationDetails c082PartyIdentificationDetails) {
this.c082PartyIdentificationDetails = c082PartyIdentificationDetails; return this;
}
public String getE4405StatusDescriptionCode() {
return e4405StatusDescriptionCode;
}
public IDEIdentity setE4405StatusDescriptionCode(String e4405StatusDescriptionCode) {
this.e4405StatusDescriptionCode = e4405StatusDescriptionCode; return this;
}
public BigDecimal getE1222ConfigurationLevelNumber() {
return e1222ConfigurationLevelNumber;
}
public IDEIdentity setE1222ConfigurationLevelNumber(BigDecimal e1222ConfigurationLevelNumber) {
this.e1222ConfigurationLevelNumber = e1222ConfigurationLevelNumber; return this;
}
public C778PositionIdentification getC778PositionIdentification() {
return c778PositionIdentification;
}
public IDEIdentity setC778PositionIdentification(C778PositionIdentification c778PositionIdentification) {
this.c778PositionIdentification = c778PositionIdentification; return this;
}
public C240CharacteristicDescription getC240CharacteristicDescription() {
return c240CharacteristicDescription;
}
public IDEIdentity setC240CharacteristicDescription(C240CharacteristicDescription c240CharacteristicDescription) {
this.c240CharacteristicDescription = c240CharacteristicDescription; return this;
}
}