org.exolab.castor.xml.schema
public class Group extends Particle implements ContentModelGroup, Referable
Version: $Revision: 1.3 $ $Date: 2004/10/01 13:25:21 $
Constructor Summary | |
---|---|
Group()
Creates a new Group, with no name
| |
Group(String name)
Creates a new Group with the given name |
Method Summary | |
---|---|
void | addElementDecl(ElementDecl elementDecl)
Adds the given ElementDecl to this ContentModelGroup |
void | addGroup(Group group)
Adds the given Group to this ContentModelGroup |
void | addGroup(ModelGroup group)
Adds the given ModelGroup Definition to this Group |
void | addWildcard(Wildcard wildcard)
Adds a wildcard to this Group model |
Enumeration | enumerate()
Returns an enumeration of all the Particles of this
ContentModelGroup
|
ContentModelGroup | getContentModelGroup()
Returns the ContentModelGroup for this group
Only used for a |
ElementDecl | getElementDecl(String name)
Returns the element declaration with the given name, or null if no
element declaration with that name exists in this ContentModelGroup.
|
String | getId()
Returns the ID for this Group |
String | getName()
Returns the name of this Group, or null if no name was defined. |
Order | getOrder()
Returns the compositor for this Group |
Structure | getParent()
Returns the parent of this Group, this value may be null if
no parent has been set.
|
Particle | getParticle(int index)
Returns the Particle at the specified index |
int | getParticleCount()
Returns the number of particles contained within
this ContentModelGroup
|
String | getReferenceId()
Returns the Id used to Refer to this Object |
short | getStructureType()
Returns the type of this Schema Structure |
boolean | hasAny()
A helper method that returns true if this group
contains an |
boolean | isModelGroupDefinition()
Tells if the group is a model group definition |
boolean | removeElementDecl(ElementDecl element)
Removes the given ElementDecl from this ContentModelGroup. |
boolean | removeGroup(Group group)
Removes the given Group from this Group. |
boolean | removeGroup(ModelGroup group)
Removes the given ModelGroup Definition from this Group. |
boolean | removeWildcard(Wildcard wildcard)
Removes the given Wildcard from this Group. |
void | setId(String id)
Sets the ID for this Group |
void | setIsModelGroupDefinition(boolean isModelGroupDefinition)
Sets if the group is a model group definition |
void | setName(String name)
Sets the name of this Group |
void | setOrder(Order order)
Sets the Order option for this Group |
protected void | setParent(Structure parent)
Sets the parent for this Group
|
void | validate()
Checks the validity of this Group defintion.
|
Parameters: name of the Group
Parameters: elementDecl the ElementDecl to add
Throws: SchemaException when an ElementDecl already exists with the same name as the given ElementDecl
Parameters: group the Group to add
Throws: SchemaException when a group with the same name as the specified group already exists in the current scope
Parameters: group the ModelGroup to add
Throws: SchemaException when a group with the same name as the specified group already exists in the current scope
Parameters: WildCard the wildcard to add
Throws: SchemaException thrown when the wildcard
is an
Returns: an enumeration of the Particles contained within this ContentModelGroup
Returns: the ContentModelGroup for this group
Parameters: name the name of the element.
Returns: the ElementDecl with the given name, or null if no ElementDecl exists in this ContentModelGroup.
Returns: the ID for this Group, or null if no ID is present
Returns: the name of this Group, or null if no name was defined
Returns: the compositor for this Group
Returns: the parent Structure of this Group.
Parameters: index the index of the particle to return
UNKNOWN: the CMParticle at the specified index
Returns: the number of particles
Returns: the type of this Schema Structure
Returns: method that returns true if this group
contains an
Deprecated: Since Castor 0.9.2, to handle properly the
Returns: true if the group is a model group definition (
Parameters: elementDecl the ElementDecl to remove.
Returns: true if the element has been successfully removed, false otherwise.
Parameters: group the Group to remove.
Returns: true if the group has been successfully removed, false otherwise.
Parameters: group the ModelGroup Definition to remove.
Returns: true if the group has been successfully removed, false otherwise.
Parameters: wilcard the Wildcard to remove.
Returns: true if the wildcard has been successfully removed, false otherwise.
Parameters: id the ID for this Group
Deprecated: Since Castor 0.9.2, to handle properly the
Parameters: name the new name for this Group
Parameters: order the type of order that this group is restricted to
Parameters: parent the parent Structure for this Group
Throws: ValidationException when this Group definition is invalid.