- From: Jason Diamond <jason@injektilo.org>
- Date: Tue, 12 Dec 2000 15:20:26 -0800
- To: <xmlschema-dev@w3.org>
Hi.
4.3.3 of the Structures CR says:
"Careful consideration of the above concrete syntax reveals that a type
definition need consist of no more than a name, i.e. that <complexType
name="anyThing"/> is allowed. The result is however not of much use, as it
will have empty {content type} and no allowed attributes."
My careful consideration of the syntax revealed something different, though.
"Content: (annotation? , (simpleContent | complexContent | ((group | all |
choice | sequence)? , ((attribute | attributeGroup)* , anyAttribute?))))"
This looks like there has to be a simpleContent, complexContent, or one of
the particles followed by some attribute declarations.
The complexTypeModel complexType in the Schema for Schemas shows this:
<group name="complexTypeModel">
<choice>
<element ref="simpleContent"/>
<element ref="complexContent"/>
<sequence>
<annotation>
<documentation xml:lang="en">
This branch is short for
<complexContent>
<restriction base="anyType">
...
</restriction>
</complexContent></documentation>
</annotation>
<group ref="typeDefParticle" minOccurs="0"/>
<group ref="attrDecls"/>
</sequence>
</choice>
</group>
The minOccurs on the choice, element refs, and sequence default to 1, don't
they?
Lastly, the DTD for Schemas shows this:
<!ELEMENT %complexType; ((%annotation;)?,
(%simpleContent;|%complexContent;|
%particleAndAttrs;))>
Am I reading these correctly? Since an empty complexType is essentially
worthless, I don't see any value in allowing it. Was it removed from the
schemas but accidentally left in the text?
Thanks,
Jason.
Received on Tuesday, 12 December 2000 18:24:11 UTC