Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Enumeration-facet of union-types

From: "Klaas Dellschaft" <klaasd@-----------.-->
To: <xmlschema-dev@--.--->
Date: 11/23/2004 6:39:00 PM
Hi,

I have a question about enumeration facets of union types. I have the
following schema:


----------------------------------
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
           elementFormDefault="qualified">

 <xs:element name="test" type="st.unionType"/>


 <xs:simpleType name="st.unionType">
  <xs:restriction>
   <xs:simpleType>
    <xs:union memberTypes="xs:string xs:integer"/>
   </xs:simpleType>
   <xs:enumeration value="11"/>
  </xs:restriction>
 </xs:simpleType>

</xs:schema>
----------------------------------


In section 2.5.1.3 of "XML Schema Part2: Datatypes" 
(http://www.w3.org/TR/xmlschema-2/#union-datatypes) it is said that the 
evaluation order of datatypes can be overridden with the use of xsi:type.

So my question is whether the value space of "st.unionType" only contains 
the String "11" or also the Integer "11". An example for the problem would 
be the following xml file:


----------------------------------
<test xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xmlns:xs="http://www.w3.org/2001/XMLSchema"
   xsi:noNamespaceSchemaLocation="test.xsd" xsi:type="xs:integer">
   11
</test>
----------------------------------


Is this file valid or should it be rejected? My problem is that I have two 
tools which interpret the enumeration-facet of union types in different ways 
and now I have to decide where to report the bug ;-)

Thanks for your help
Klaas Dellschaft



From nobody@w... Thu Nov 25 23:37:02 2004
Received: from wiggum.w3.org ([128.30.52.23])
	by frink.w


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent