Open Business Objects for EDI
v3.6.0

com.americancoders.edi
Class TemplateSegmentContainer

java.lang.Object
  |
  +--com.americancoders.edi.TemplateSegmentContainer
All Implemented Interfaces:
IContainedObject, IIdentifier, ITemplateSegmentContainer
Direct Known Subclasses:
TemplateEnvelope, TemplateFunctionalGroup, TemplateLoopContainer

public abstract class TemplateSegmentContainer
extends java.lang.Object
implements ITemplateSegmentContainer, IContainedObject

Template Segment Container

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

Version:
3.6.0
Author:
Joe McVerry - American Coders, Ltd.

Field Summary
protected  java.util.Vector templateContainer
          storage for segments
 
Constructor Summary
TemplateSegmentContainer()
           
 
Method Summary
 void addTemplateSegment(com.americancoders.edi.TemplateSegment inTemplateSegment)
          adds a templatesegment to the vector
 int getCount()
          returns the number of template segments
 int getCount(java.lang.String ID)
          returns the number of elements with the same id
 com.americancoders.edi.TemplateSegment getTemplateSegment(int inPosition)
          gets a templatesegment from the vector
 com.americancoders.edi.TemplateSegment getTemplateSegment(java.lang.String inID)
          gets a templatesegment from the vector
 com.americancoders.edi.TemplateSegment getTemplateSegment(java.lang.String inID, java.lang.String primaryIDValue)
          gets a templatesegment from the vector by its id and primary id value This method only works if the OBOE.properties property prevalidate is set to true
 com.americancoders.edi.TemplateSegment getTemplateSegmentByIDAndName(java.lang.String inID, java.lang.String inName)
          gets a templatesegment from the vector
 boolean isSegment(int i)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.americancoders.edi.IContainedObject
getParent, setParent
 
Methods inherited from interface com.americancoders.edi.IIdentifier
getID, getXMLTag
 

Field Detail

templateContainer

protected java.util.Vector templateContainer
storage for segments

Constructor Detail

TemplateSegmentContainer

public TemplateSegmentContainer()
Method Detail

addTemplateSegment

public void addTemplateSegment(com.americancoders.edi.TemplateSegment inTemplateSegment)
adds a templatesegment to the vector

Specified by:
addTemplateSegment in interface ITemplateSegmentContainer
Parameters:
inTemplateSegment - TemplateSegment to add

getCount

public int getCount()
returns the number of template segments

Specified by:
getCount in interface ITemplateSegmentContainer
Returns:
int

getTemplateSegment

public com.americancoders.edi.TemplateSegment getTemplateSegment(int inPosition)
gets a templatesegment from the vector

Specified by:
getTemplateSegment in interface ITemplateSegmentContainer
Parameters:
inPosition - int position in array
Returns:
TemplateSegment

getTemplateSegment

public com.americancoders.edi.TemplateSegment getTemplateSegment(java.lang.String inID)
gets a templatesegment from the vector

Specified by:
getTemplateSegment in interface ITemplateSegmentContainer
Parameters:
inID - String template id
Returns:
TemplateSegment

getTemplateSegment

public com.americancoders.edi.TemplateSegment getTemplateSegment(java.lang.String inID,
                                                                 java.lang.String primaryIDValue)
                                                          throws OBOEException
gets a templatesegment from the vector by its id and primary id value This method only works if the OBOE.properties property prevalidate is set to true

Parameters:
inID - String template id
primaryIDValue - String id value
Returns:
TemplateSegment
Throws:
OBOEException - - primaryIDValue (2nd parameter) is not a valid value or segmentnotfound

getTemplateSegmentByIDAndName

public com.americancoders.edi.TemplateSegment getTemplateSegmentByIDAndName(java.lang.String inID,
                                                                            java.lang.String inName)
gets a templatesegment from the vector

Parameters:
inID - String template id
inName - String template name
Returns:
TemplateSegment

isSegment

public boolean isSegment(int i)

getCount

public int getCount(java.lang.String ID)
returns the number of elements with the same id

Parameters:
ID - String id to count
Returns:
int
Throws:
OBOEException - ID unknown.

Open Business Objects for EDI
v3.6.0


OBOE is a trademark or registered trademark of American Coders, Ltd. in the US and other countries.
Copyright 1999-2004 American Coders, Ltd.
POB 97462
Raleigh NC 27624 USA
All Rights Reserved.