org.exolab.castor.xml.dtd
public class ContentParticle extends Object
Version: $Revision: 1.1.1.1 $ $Date: 2003/03/03 07:09:19 $
Constructor Summary | |
---|---|
ContentParticle()
Constructor, setting occurance specification to ONE, by default. | |
ContentParticle(String reference)
Creates content particle and sets its type to REFERENCE, that is
the content is exactly one child-element. |
Method Summary | |
---|---|
void | addChild(ContentParticle cp)
Adds child to the vector of child elements (content particles). |
Enumeration | getChildren()
Returns enumeration of the children - content particles, that form
the content of this Content Particle, if has
SEQ or CHOICE type (sequence or choice list),
null otherwise. |
String | getReference()
Returns the name of the child element, if content is exactly one child. |
boolean | isChoiceType()
True if the content is a choice list of content particles,
false otherwise. |
boolean | isOneOccurance()
True if ocurence specification of the content particle is ONE,
false otherwise. |
boolean | isOneOrMoreOccurances()
True if occurance specification of the content particle
is ONE_OR_MORE, false otherwise. |
boolean | isReferenceType()
True if the content is exactly on child-element,
false otherwise. |
boolean | isSeqType()
True if the content is a sequence list of content particles,
false otherwise. |
boolean | isZeroOrMoreOccurances()
True if occurance specification of the content particle
is ZERO_OR_MORE, false otherwise. |
boolean | isZeroOrOneOccurance()
True if occurance specification of the content particle
is ZERO_OR_ONE, false otherwise. |
void | setChoiceType()
Sets the content to choice list of content particles. |
void | setOneOccurance()
Sets occurance specification of the content particle to ONE. |
void | setOneOrMoreOccurances()
Sets occurance specification of the content particle to
ONE_OR_MORE. |
void | setReferenceType(String reference)
Makes the content particle represent the content with exactly one
child-element. |
void | setSeqType()
Sets the content to sequence list of content particles. |
void | setZeroOrMoreOccurances()
Sets occurance specification of the content particle to
ZERO_OR_MORE. |
void | setZeroOrOneOccurance()
Sets occurance specification of the content particle to
ZERO_OR_ONE. |
Parameters: reference name of this child-element.
Parameters: cp content particle to add to the vector of children.
Parameters: reference the name of this child-element - must not be null or equal to empty String.