|
Open Business Objects for EDI v3.6.0 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--com.americancoders.edi.CompositeDE
class for all Composite Data Elements
OBOE - Open Business Objects for EDI
Part of the OBOE Basic Extended Package
An EDI and XML Translator Written In Java
Copyright 1998-2009 - American Coders, LTD - Raleigh NC USA
All rights reserved
American Coders, Ltd
P. O. Box 97462
Raleigh, NC 27624 USA
1-919-846-2014
http://www.americancoders.com
| Field Summary | |
protected int |
cursor
cursor to current deArrayGroup |
protected java.lang.Object[] |
deArray
an array of Field objects |
protected java.util.Vector |
deArrayGroup
deArray group |
protected com.americancoders.edi.TemplateComposite |
myTemplate
String of composite's xml tag |
protected com.americancoders.edi.IContainedObject |
parent
owning object |
| Constructor Summary | |
CompositeDE(com.americancoders.edi.TemplateComposite inTemplateComposite,
com.americancoders.edi.IContainedObject inParent)
creates a compsosite using a templage |
|
| Method Summary | |
java.lang.Object |
buildDE(int pos)
defines a dataelement by the predefined templateDE array |
java.lang.Object |
buildDE(java.lang.String ID)
defines a dataelement by the predefined templateDE array |
java.lang.Object[] |
createNewGroup()
creates a new dearray set for multi-occuring composites |
int |
doIUseThisXMLElement(java.lang.String inTag,
int startAt)
routine to ask if it uses a dataelement |
java.lang.String |
get()
returns all the data associated field values separated by '*' |
com.americancoders.edi.DataElement |
getDataElement(int inPos)
returns a data element by its location |
com.americancoders.edi.DataElement |
getDataElement(java.lang.String inID)
returns a data element by its id |
int |
getDataElementLength()
returns the length of the data in the data elements |
int |
getDataElementSize()
returns the number of defined data element |
java.lang.String |
getDataElementValue(int pos)
returns the value set in the data element if the data element is not built it will return a zero-length string. |
java.lang.String |
getDataElementValue(java.lang.String ID)
returns the value set in the data element if the data element is not built it will return a zero-length string. |
int |
getDEArrayCount()
returns number of elements in deArrayGroup |
java.lang.String |
getFixedLengthFormattedText()
gets the text formatted to maximum length of fields |
java.lang.String |
getFormattedText(int formatType)
returns the formatted text |
java.lang.String |
getID()
returns the id field |
java.lang.String |
getName()
returns the name field |
int |
getOccurs()
returns the occurs value |
com.americancoders.edi.IContainedObject |
getParent()
gets parent attribute |
char |
getRequired()
returns the required indicator |
int |
getSequence()
returns the sequence |
com.americancoders.edi.TemplateComposite |
getTemplate()
returns the templateComposite object used to build this CompoisteDE |
java.lang.String |
getXMLTag()
returns the xml tag field |
int |
gotoGroup(int inPos)
moves the cursor to a dearraygroup and resets the group. |
boolean |
isDataElement(int inPos)
returns a boolean if vector position held by a data element |
boolean |
isUsed()
returns boolean indicating if composite is used |
java.lang.Object[] |
nextGroup()
moves the cursor to the next group |
boolean |
parse(com.americancoders.edi.ITokenizer TransactionTokenizedString)
parsing logic for compositeDE |
void |
parse(org.w3c.dom.Node node)
parses a XML EDI Document adds to datalement vector |
void |
parse(java.io.PushbackInputStream pis)
parses a Fixed Length EDI Document adds to datalement vector or compositeDE and adds to secondary segment vector |
boolean |
parse(java.lang.String TokenizedString,
com.americancoders.edi.ITokenizer TransactionTokenizedString)
parsing logic for compositeDE for repeating composites |
int |
resetCursor()
moves the cursor to the first deArray and sets the deArray |
com.americancoders.edi.DataElement |
setDataElementValue(int pos,
java.lang.String inValue)
sets the value set in the data element without needing to build the data element object if the data element is not built it will be built. |
com.americancoders.edi.DataElement |
setDataElementValue(java.lang.String ID,
java.lang.String inValue)
returns the value set in the data element if the data element is not built it will return a zero-length string. |
void |
setParent(com.americancoders.edi.IContainedObject inParent)
sets parent attribute |
java.lang.String |
toString()
the toString method |
int |
trim()
removes empty trailing data elements and returns the number of used dataelements |
void |
validate(com.americancoders.edi.DocumentErrors inDErr)
returns error responses of contents |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected java.lang.Object[] deArray
protected com.americancoders.edi.TemplateComposite myTemplate
protected int cursor
protected java.util.Vector deArrayGroup
protected com.americancoders.edi.IContainedObject parent
| Constructor Detail |
public CompositeDE(com.americancoders.edi.TemplateComposite inTemplateComposite,
com.americancoders.edi.IContainedObject inParent)
inTemplateComposite - TemplateComposite used to build this compositeinParent - owning Object| Method Detail |
public com.americancoders.edi.TemplateComposite getTemplate()
public java.lang.Object buildDE(int pos)
buildDE in interface IDataElementContainerpos - field to build is identified by its templates position
public java.lang.Object[] createNewGroup()
throws OBOEException
OBOEException
public int gotoGroup(int inPos)
throws OBOEException
inPos -
OBOEException
public int resetCursor()
throws OBOEException
OBOEException
public int getDEArrayCount()
throws OBOEException
OBOEException
public java.lang.Object[] nextGroup()
throws OBOEException
OBOEExceptionpublic java.lang.String getID()
getID in interface IIdentifierpublic java.lang.String getName()
public java.lang.String getXMLTag()
getXMLTag in interface IIdentifierpublic boolean isUsed()
public char getRequired()
public int getSequence()
public int getOccurs()
public int getDataElementSize()
getDataElementSize in interface IDataElementContainerpublic com.americancoders.edi.DataElement getDataElement(java.lang.String inID)
getDataElement in interface IDataElementContainerinID - String id of dataelement to return
public com.americancoders.edi.DataElement getDataElement(int inPos)
getDataElement in interface IDataElementContainerinPos - int position of data element to return
public boolean isDataElement(int inPos)
inPos - is object in the array a dataelement
public boolean parse(com.americancoders.edi.ITokenizer TransactionTokenizedString)
throws OBOEException
TransactionTokenizedString -
OBOEException - most likely the composite item can't find any of the fields coming in.
public boolean parse(java.lang.String TokenizedString,
com.americancoders.edi.ITokenizer TransactionTokenizedString)
throws OBOEException
TokenizedString - String partially tokenizedTransactionTokenizedString - ITokenizer - parent of DataTokenizer
OBOEException - most likely the composite item can't find any of the fields coming in.
public void parse(java.io.PushbackInputStream pis)
throws OBOEException,
java.io.IOException
pis - PushbackInputStream
OBOEException - as thrown
java.io.IOException
public void parse(org.w3c.dom.Node node)
throws OBOEException
node - Node
OBOEException - Node is unknown to compositepublic java.lang.String get()
public int getDataElementLength()
public java.lang.String getFormattedText(int formatType)
formatType - x12, edifact...
public void validate(com.americancoders.edi.DocumentErrors inDErr)
inDErr - DocumentErrorspublic int trim()
public int doIUseThisXMLElement(java.lang.String inTag,
int startAt)
inTag - String idstartAt - int position to start at
public void setParent(com.americancoders.edi.IContainedObject inParent)
setParent in interface IContainedObjectinParent - TemplateSegmentContainerpublic com.americancoders.edi.IContainedObject getParent()
getParent in interface IContainedObjectpublic java.lang.String getFixedLengthFormattedText()
public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.Object buildDE(java.lang.String ID)
IDataElementContainer
buildDE in interface IDataElementContainerID - field to build is identified by its templates id value
public java.lang.String getDataElementValue(java.lang.String ID)
throws OBOEException
IDataElementContainer
getDataElementValue in interface IDataElementContainerID - String ID of datalement to look for
OBOEException - ID is unknown, or position is for a composite de
public java.lang.String getDataElementValue(int pos)
throws OBOEException
IDataElementContainer
getDataElementValue in interface IDataElementContainerpos - int position within the segement
OBOEException - ID is unknown
public com.americancoders.edi.DataElement setDataElementValue(java.lang.String ID,
java.lang.String inValue)
throws OBOEException
IDataElementContainer
setDataElementValue in interface IDataElementContainerID - String ID of datalement to look for
OBOEException - ID is unknown, or position is for a composite de
public com.americancoders.edi.DataElement setDataElementValue(int pos,
java.lang.String inValue)
throws OBOEException
IDataElementContainer
setDataElementValue in interface IDataElementContainerpos - int position within the segement
OBOEException - ID is unknown
|
Open Business Objects for EDI v3.6.0 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||