Public Member Functions | |
ElementDecl (Schema schema) | |
ElementDecl (Schema schema, String name) | |
void | addIdentityConstraint (IdentityConstraint constraint) |
BlockList | getBlock () |
String | getDefaultValue () |
FinalList | getFinal () |
String | getFixedValue () |
Form | getForm () |
String | getId () |
Enumeration | getIdentityConstraints () |
String | getName () |
String | getName (boolean ignoreRef) |
Structure | getParent () |
XMLType | getType () |
ElementDecl | getReference () |
String | getReferenceName () |
String | getReferenceId () |
Schema | getSchema () |
String | getSubstitutionGroup () |
Enumeration | getSubstitutionGroupMembers () |
boolean | isAbstract () |
boolean | isNillable () |
boolean | isReference () |
void | setAbstract (boolean isAbstract) |
boolean | hasChildren () |
boolean | removeIdentityConstraint (IdentityConstraint constraint) |
void | setBlock (BlockList block) |
void | setBlock (String block) |
void | setDefaultValue (String value) |
void | setFinal (FinalList finalList) |
void | setFinal (String finalValue) |
void | setFixedValue (String value) |
void | setForm (Form form) |
void | setId (String id) |
void | setName (String name) |
void | setNillable (boolean nillable) |
void | setReference (ElementDecl reference) |
void | setReference (String reference) |
void | setSubstitutionGroup (String substitutionGroup) |
void | setType (XMLType type) |
void | setTypeReference (String name) |
short | getStructureType () |
void | validate () throws ValidationException |
Protected Member Functions | |
void | setParent (Structure parent) |
An XML Schema ElementDecl
org.exolab.castor.xml.schema.ElementDecl.ElementDecl | ( | Schema | schema | ) |
Creates a new default element definition
schema,the | XML Schema to which this element declartion belongs This element definition will not be valid until a name has been set |
org.exolab.castor.xml.schema.ElementDecl.ElementDecl | ( | Schema | schema, | |
String | name | |||
) |
Creates a new default element definition
schema,the | XML Schema to which this Element Declartion belongs | |
name | the name of the Element being declared |
References org.exolab.castor.xml.schema.ElementDecl.setName().
void org.exolab.castor.xml.schema.ElementDecl.addIdentityConstraint | ( | IdentityConstraint | constraint | ) |
Adds the given IdentityConstraint to this element definition.
constraint | the IdentityConstraint to add. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.endElement().
BlockList org.exolab.castor.xml.schema.ElementDecl.getBlock | ( | ) |
Returns the value of the 'block' attribute for this element
String org.exolab.castor.xml.schema.ElementDecl.getDefaultValue | ( | ) |
Returns the default value of this element definition.
References org.exolab.castor.xml.schema.ElementDecl.getDefaultValue(), org.exolab.castor.xml.schema.ElementDecl.getReference(), and org.exolab.castor.xml.schema.ElementDecl.isReference().
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller(), and org.exolab.castor.xml.schema.ElementDecl.getDefaultValue().
FinalList org.exolab.castor.xml.schema.ElementDecl.getFinal | ( | ) |
Returns the value of the 'final' attribute for this element definition.
String org.exolab.castor.xml.schema.ElementDecl.getFixedValue | ( | ) |
Returns the fixed value of this element definition.
References org.exolab.castor.xml.schema.ElementDecl.getFixedValue(), org.exolab.castor.xml.schema.ElementDecl.getReference(), and org.exolab.castor.xml.schema.ElementDecl.isReference().
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller(), and org.exolab.castor.xml.schema.ElementDecl.getFixedValue().
Form org.exolab.castor.xml.schema.ElementDecl.getForm | ( | ) |
Returns the Form for this element definition. The Form object species whether or not names are qualified or unqualified in the scope of this element definition. If null, the Form should be obtained from the parent Schema.
Referenced by org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace().
String org.exolab.castor.xml.schema.ElementDecl.getId | ( | ) |
Returns the 'id' for this element definition.
Enumeration org.exolab.castor.xml.schema.ElementDecl.getIdentityConstraints | ( | ) |
Returns an Enumeration of IdentityConstraint objects contained within this element definition.
String org.exolab.castor.xml.schema.ElementDecl.getName | ( | ) |
Returns the name of this Element declaration. The name of the referenced element is returned if the 'ref' attribute was used. The name returned will be an NCName (no namespace prefix will be included with the name).
Referenced by org.exolab.castor.xml.dtd.Converter.convertDTDElementToSchemaElement(), com.cosylab.cdb.jdal.XSDElementTypeResolver.doesExtend(), org.exolab.castor.xml.schema.ContentModelGroupImpl.getElementDecl(), org.exolab.castor.xml.schema.ElementDecl.getReference(), com.cosylab.cdb.jdal.XSDElementTypeResolver.internalGetElementTypes(), org.exolab.castor.xml.schema.Schema.removeElement(), org.exolab.castor.xml.schema.ContentModelGroupImpl.removeElementDecl(), and org.exolab.castor.xml.schema.ElementDecl.setReference().
String org.exolab.castor.xml.schema.ElementDecl.getName | ( | boolean | ignoreRef | ) |
Returns the name of this Element declaration. The name returned, if not null, will be an NCName.
ingoreRef | if false the name of the referenced element (if specified) is returned, otherwise the localname (may be null). |
References org.exolab.castor.xml.schema.ElementDecl.isReference().
Structure org.exolab.castor.xml.schema.ElementDecl.getParent | ( | ) |
Returns the parent of this ElementDecl, this value may be null if no parent has been set.
Referenced by org.exolab.castor.builder.binding.XMLBindingComponent.getJavaMemberName(), org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace(), and org.exolab.castor.xml.schema.ElementDecl.validate().
ElementDecl org.exolab.castor.xml.schema.ElementDecl.getReference | ( | ) |
Returns the ElementDecl that this element definition references. This will return null if this element definition does not reference a different element definition.
References org.exolab.castor.xml.schema.Schema.getElementDecl(), and org.exolab.castor.xml.schema.ElementDecl.getName().
Referenced by org.exolab.castor.builder.binding.ExtendedBinding.getComponentBindingType(), org.exolab.castor.xml.schema.ElementDecl.getDefaultValue(), org.exolab.castor.xml.schema.ElementDecl.getFixedValue(), org.exolab.castor.builder.binding.XMLBindingComponent.getJavaClassName(), org.exolab.castor.builder.binding.XMLBindingComponent.getJavaMemberName(), org.exolab.castor.builder.binding.XMLBindingComponent.getSchema(), org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace(), and org.exolab.castor.xml.schema.ElementDecl.getType().
String org.exolab.castor.xml.schema.ElementDecl.getReferenceId | ( | ) |
Returns the Id used to Refer to this Object
Implements org.exolab.castor.xml.schema.Referable.
String org.exolab.castor.xml.schema.ElementDecl.getReferenceName | ( | ) |
Returns the actual reference name of this AttributeDecl, or null if this AttributeDecl is not a reference. The name returned, if not null, will be a QName, possibly containing the namespace prefix.
Referenced by org.exolab.castor.builder.binding.XMLBindingComponent.getJavaMemberName().
Schema org.exolab.castor.xml.schema.ElementDecl.getSchema | ( | ) |
Returns the XML Schema to which this element declaration belongs.
Referenced by org.exolab.castor.builder.binding.XMLBindingComponent.getSchema(), org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace(), and org.exolab.castor.xml.schema.ElementDecl.setReference().
short org.exolab.castor.xml.schema.ElementDecl.getStructureType | ( | ) |
Returns the type of this Schema Structure
Referenced by org.exolab.castor.xml.schema.ElementDecl.validate().
String org.exolab.castor.xml.schema.ElementDecl.getSubstitutionGroup | ( | ) |
Returns the substitutionGroup for this element declaration, or null if it's absent.
Referenced by org.exolab.castor.xml.schema.ElementDecl.getSubstitutionGroupMembers().
Enumeration org.exolab.castor.xml.schema.ElementDecl.getSubstitutionGroupMembers | ( | ) |
Returns an enumeration of the elements that can be substitute to this element declaration.
References org.exolab.castor.xml.schema.Schema.getElementDecls(), and org.exolab.castor.xml.schema.ElementDecl.getSubstitutionGroup().
XMLType org.exolab.castor.xml.schema.ElementDecl.getType | ( | ) |
Returns the XMLType (ComplexType or SimpleType) of this ElementDecl.
References org.exolab.castor.xml.schema.Schema.getMasterSchema(), org.exolab.castor.xml.schema.XMLType.getName(), org.exolab.castor.xml.schema.ElementDecl.getReference(), org.exolab.castor.xml.schema.XMLType.getSchema(), org.exolab.castor.xml.schema.Schema.getType(), org.exolab.castor.xml.schema.XMLType.getType(), org.exolab.castor.xml.schema.ElementDecl.getType(), and org.exolab.castor.xml.schema.ElementDecl.isReference().
Referenced by com.cosylab.cdb.jdal.XSDElementTypeResolver.doesExtend(), org.exolab.castor.xml.schema.util.XMLInstance2SchemaHandler.endElement(), org.exolab.castor.xml.schema.ElementDecl.getType(), org.exolab.castor.xml.schema.ElementDecl.hasChildren(), com.cosylab.cdb.jdal.XSDElementTypeResolver.internalGetElementTypes(), and org.exolab.castor.xml.schema.ElementDecl.validate().
boolean org.exolab.castor.xml.schema.ElementDecl.hasChildren | ( | ) |
Returns true if this element has children (i.e if it holds attributes or elements).
References org.exolab.castor.xml.schema.ElementDecl.getType().
boolean org.exolab.castor.xml.schema.ElementDecl.isAbstract | ( | ) |
Returns true if this element definition is abstract
boolean org.exolab.castor.xml.schema.ElementDecl.isNillable | ( | ) |
Returns whether or not instances of this element definition may appear with no content.
boolean org.exolab.castor.xml.schema.ElementDecl.isReference | ( | ) |
Returns true if this element definition simply references another element Definition
Referenced by org.exolab.castor.builder.binding.ExtendedBinding.getComponentBindingType(), org.exolab.castor.xml.schema.ElementDecl.getDefaultValue(), org.exolab.castor.xml.schema.ElementDecl.getFixedValue(), org.exolab.castor.builder.binding.XMLBindingComponent.getJavaClassName(), org.exolab.castor.builder.binding.XMLBindingComponent.getJavaMemberName(), org.exolab.castor.xml.schema.ElementDecl.getName(), org.exolab.castor.builder.binding.XMLBindingComponent.getSchema(), org.exolab.castor.builder.binding.XMLBindingComponent.getTargetNamespace(), org.exolab.castor.xml.schema.ElementDecl.getType(), and org.exolab.castor.xml.schema.ContentModelGroupImpl.removeElementDecl().
boolean org.exolab.castor.xml.schema.ElementDecl.removeIdentityConstraint | ( | IdentityConstraint | constraint | ) |
Removes the given IdentityConstraint from this element definition.
constraint | the IdentityConstraint to remove. |
void org.exolab.castor.xml.schema.ElementDecl.setAbstract | ( | boolean | isAbstract | ) |
Sets whether or not this element definition is abstract
isAbstract,a | boolean when true indicates that this element definition should be abstract |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setBlock | ( | BlockList | block | ) |
Sets the value of the 'block' attribute for this element
block | the value of the block attribute for this element definition. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setBlock | ( | String | block | ) |
Sets the value of the 'block' attribute for this element
block | the value of the block attribute for this element definition. |
void org.exolab.castor.xml.schema.ElementDecl.setDefaultValue | ( | String | value | ) |
Sets the default value for this element definition.
value | the default value for this element definition. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setFinal | ( | FinalList | finalList | ) |
Sets the value of the 'final' attribute for this element definition.
finalValue | the value of the final attribute for this element definition. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setFinal | ( | String | finalValue | ) |
Sets the value of the 'final' attribute for this element definition.
finalValue | the value of the final attribute for this element definition. |
void org.exolab.castor.xml.schema.ElementDecl.setFixedValue | ( | String | value | ) |
Sets the fixed value for this element definition.
value | the fixed value for this element definition. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setForm | ( | Form | form | ) |
Sets the Form for this element definition. The Form object species whether or not names are qualified or unqualified in the scope of this element definition. If null, the Form is to be obtained from the parent Schema.
form | the Form type for this element definition. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setId | ( | String | id | ) |
Sets the Id for this element definition.
id | the Id for this element definition. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setName | ( | String | name | ) |
Sets the name of the element that this Element definition defines.
name | the name of the defined element |
Referenced by org.exolab.castor.xml.schema.ElementDecl.ElementDecl(), and org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setNillable | ( | boolean | nillable | ) |
Sets whether or not instances of this element definition may contain empty content
nillable | the flag when true indicates that instances of this element definition may appear with empty content |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setParent | ( | Structure | parent | ) | [protected] |
Sets the parent for this ElementDecl.
parent | the parent Structure for this ElementDecl |
References org.exolab.castor.xml.schema.Structure.getStructureType().
void org.exolab.castor.xml.schema.ElementDecl.setReference | ( | ElementDecl | reference | ) |
Sets the reference for this element definition
reference | the Element definition that this definition references |
References org.exolab.castor.xml.schema.ElementDecl.getName(), org.exolab.castor.xml.schema.Schema.getNamespacePrefix(), org.exolab.castor.xml.schema.ElementDecl.getSchema(), and org.exolab.castor.xml.schema.Schema.getTargetNamespace().
Referenced by org.exolab.castor.xml.dtd.Converter.convertContentParticle(), org.exolab.castor.xml.dtd.Converter.convertDTDElementToSchemaElement(), and org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setReference | ( | String | reference | ) |
Sets the reference for this element definition
reference | the name of the element definition that this definition references |
void org.exolab.castor.xml.schema.ElementDecl.setSubstitutionGroup | ( | String | substitutionGroup | ) |
Sets the substitutionGroup for this element definition.
substitutionGroup | the substitutionGroup for this element definition. |
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller().
void org.exolab.castor.xml.schema.ElementDecl.setType | ( | XMLType | type | ) |
Sets the XMLType for this Element declaration.
type | the XMLType for this element declaration. Note: This method is mutually exclusive with setTypeReference, if a reference has previously been set it will be ignored. |
References org.exolab.castor.xml.schema.XMLType.setParent().
Referenced by org.exolab.castor.xml.dtd.Converter.convertDTDElementToSchemaElement(), org.exolab.castor.xml.schema.util.XMLInstance2SchemaHandler.endElement(), org.exolab.castor.xml.schema.reader.ElementUnmarshaller.endElement(), and org.exolab.castor.xml.schema.ElementDecl.setTypeReference().
void org.exolab.castor.xml.schema.ElementDecl.setTypeReference | ( | String | name | ) |
Sets the type of this element to be a reference.
References org.exolab.castor.xml.schema.XMLType.setName(), org.exolab.castor.xml.schema.XMLType.setSchema(), and org.exolab.castor.xml.schema.ElementDecl.setType().
Referenced by org.exolab.castor.xml.schema.reader.ElementUnmarshaller.ElementUnmarshaller(), and org.exolab.castor.xml.schema.util.XMLInstance2SchemaHandler.endElement().
void org.exolab.castor.xml.schema.ElementDecl.validate | ( | ) | throws ValidationException |
Checks the validity of this element definition.
ValidationException | when this element definition is invalid. |
References org.exolab.castor.xml.schema.Schema.getElementDecl(), org.exolab.castor.xml.schema.Particle.getMaxOccurs(), org.exolab.castor.xml.schema.Particle.getMinOccurs(), org.exolab.castor.xml.schema.XMLType.getName(), org.exolab.castor.xml.schema.SimpleType.getParent(), org.exolab.castor.xml.schema.ElementDecl.getParent(), org.exolab.castor.xml.schema.XMLType.getSchema(), org.exolab.castor.xml.schema.ElementDecl.getStructureType(), org.exolab.castor.xml.schema.ElementDecl.getType(), org.exolab.castor.xml.schema.SimpleType.getTypeCode(), org.exolab.castor.xml.schema.XMLType.isComplexType(), org.exolab.castor.xml.schema.XMLType.isSimpleType(), org.exolab.castor.xml.schema.ComplexType.isTopLevel(), org.exolab.castor.xml.schema.SimpleType.validate(), and org.exolab.castor.xml.schema.ComplexType.validate().