- From: <xsd@themartian.com>
- Date: Sat, 1 Dec 2001 13:29:08 -0500 (EST)
- To: xmlschema-dev@w3.org
Just a clarification on these (not for me): Do these three parts of the schema work together? In particular can the role, remark, and accept elements legally be in a substitutionGroup with the contextElement as its head (even though their types are not derived from contextType)? <xsd:complexType name="contextType"> <xsd:choice minOccurs="0" maxOccurs="unbounded"> <xsd:element ref="context" minOccurs="0" maxOccurs="unbounded"/> <xsd:element ref="contextElement" minOccurs="0" maxOccurs="unbounded"/> </xsd:choice> <xsd:attributeGroup ref="IDGroup"/> </xsd:complexType> <xsd:element name="context" type="contextType"/> <xsd:element name="contextElement" type="contextType"/> <xsd:element name="role" substitutionGroup="contextElement"> <xsd:complexType> <xsd:simpleContent> <xsd:extension base="xsd:string"> <xsd:attribute name="idscheme" use="optional"> <xsd:simpleType> <xsd:restriction base="xsd:NMTOKEN"> <xsd:enumeration value="MARC"/> <xsd:enumeration value="ONIX"/> <xsd:enumeration value="MPEG7"/> </xsd:restriction> </xsd:simpleType> </xsd:attribute> </xsd:extension> </xsd:simpleContent> </xsd:complexType> </xsd:element> <xsd:element name="remark" type="xsd:string" substitutionGroup="contextElement"/> <xsd:element name="accept" substitutionGroup="contextElement"/> Thanks in advance. From: xsd@themartian.com To: xmlschema-dev@w3.org Subject: SubstitutionGroup / Derivation Clarification Just a clarification on these (not for me): Do these three parts of the schema work together? In particular can the role, remark, and accept elements legally be in a substitutionGroup with the contextElement as its head (even though their types are not derived from contextType)? <xsd:complexType name="contextType"> <xsd:choice minOccurs="0" maxOccurs="unbounded"> <xsd:element ref="context" minOccurs="0" maxOccurs="unbounded"/> <xsd:element ref="contextElement" minOccurs="0" maxOccurs="unbounded"/> </xsd:choice> <xsd:attributeGroup ref="IDGroup"/> </xsd:complexType> <xsd:element name="context" type="contextType"/> <xsd:element name="contextElement" type="contextType"/> <xsd:element name="role" substitutionGroup="contextElement"> <xsd:complexType> <xsd:simpleContent> <xsd:extension base="xsd:string"> <xsd:attribute name="idscheme" use="optional"> <xsd:simpleType> <xsd:restriction base="xsd:NMTOKEN"> <xsd:enumeration value="MARC"/> <xsd:enumeration value="ONIX"/> <xsd:enumeration value="MPEG7"/> </xsd:restriction> </xsd:simpleType> </xsd:attribute> </xsd:extension> </xsd:simpleContent> </xsd:complexType> </xsd:element> <xsd:element name="remark" type="xsd:string" substitutionGroup="contextElement"/> <xsd:element name="accept" substitutionGroup="contextElement"/> Thanks in advance.
Received on Monday, 3 December 2001 15:36:41 UTC