W3C home > Mailing lists > Public > xmlschema-dev@w3.org > January 2003

Extension and all-group

From: Oleg Tkachenko <olegt@multiconn.com>
Date: Fri, 31 Jan 2003 02:51:17 +0200
Message-ID: <3E39C885.1090705@multiconn.com>
To: xmlschema-dev@w3.org

Hello!

This question was raised at news:microsoft.public.dotnet.xml newsgroup - 
is the following schema valid? .NET gives errors, while XML Spy and W3C 
validator say okay.

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" 
elementFormDefault="qualified" attributeFormDefault="unqualified">
	<xs:element name="root">
		<xs:complexType>
			<xs:choice>
				<xs:element name="element0" type="derivedType"/>
			</xs:choice>
		</xs:complexType>
	</xs:element>
	<xs:complexType name="baseType">
		<xs:all minOccurs="0">
			<xs:element name="element1" minOccurs="0"/>
			<xs:element name="element2" minOccurs="0"/>
		</xs:all>
	</xs:complexType>
	<xs:complexType name="derivedType">
		<xs:complexContent>
			<xs:extension base="baseType">
				<xs:all>
					<xs:element name="element3"/>
					<xs:element name="element4"/>
				</xs:all>
			</xs:extension>
		</xs:complexContent>
	</xs:complexType>
</xs:schema>

-- 
Oleg Tkachenko
eXperanto team
Multiconn Technologies, Israel
Received on Thursday, 30 January 2003 19:50:53 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:35 GMT