[xml] Question about 'union' types in xmlSchemas
- From: GUY Fabrice <fabrice guy gmail com>
- To: xml gnome org
- Subject: [xml] Question about 'union' types in xmlSchemas
- Date: Wed, 25 May 2005 18:16:55 +0200
Hi,
I have this schema :
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:element name="ELEMENTS">
<xsd:simpleType>
<xsd:union>
<xsd:simpleType>
<xsd:restriction base="xsd:int">
<xsd:minInclusive value="10"/>
<xsd:maxInclusive value="20"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType>
<xsd:restriction base="xsd:int">
<xsd:minInclusive value="30"/>
<xsd:maxInclusive value="40"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:union>
</xsd:simpleType>
</xsd:element>
</xsd:schema>
and this simple xml file :
<ELEMENTS>5</ELEMENTS>
This xml file validates using xmllint (with libxml 2.6.19) although 5
does not fall in the interval [10,20] neither [30,40].
But maybe the 'union' type is not yet fully implemented ?
Regards,
Fabrice
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]