- From: Micah Dubinko <MDubinko@cardiff.com>
- Date: Mon, 3 Dec 2001 10:29:25 -0800
- To: "'Hiroshi Iwasaki'" <Iwasaki_Hiroshi@mse.mei.co.jp>, www-forms@w3.org
Hello,
If my understanding is correct, the three lines you show below aren't
necessary, due to the attribute
memberTypes="xsd:string"
In schema unions, the datatypes-being-unioned can be in a space separated
list on that attribute, and also as children.
Thanks!
.micah
-----Original Message-----
From: Hiroshi Iwasaki [mailto:Iwasaki_Hiroshi@mse.mei.co.jp]
Sent: Sunday, December 02, 2001 5:41 PM
To: www-forms@w3.org
Subject: Question about open enumeration
Hi all xformers;
I have a question about open enumeration.
An example of schema syntax declaring an open enumeration
is given in 5.4.3 Open Enumeration as follows:
<xsd:simpleType>
<xsd:union memberTypes="xsd:string">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Mastercard"/>
<xsd:enumeration value="Diner's Club"/>
<xsd:enumeration value="American Express"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:union>
</xsd:simpleType>
But I don't think this gives us any space to specify other choice.
In order to allow us to specify other choice, I think we need additional
three lienes as follows:
<xsd:simpleType>
<xsd:union memberTypes="xsd:string">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Mastercard"/>
<xsd:enumeration value="Diner's Club"/>
<xsd:enumeration value="American Express"/>
</xsd:restriction>
</xsd:simpleType>
<!-- following three lines make this an open enumeration -->
<xsd:simpleType>
<xsd:restriction base="xsd:string"/>
</xsd:simpleType>
</xsd:union>
</xsd:simpleType>
Am I correct?
Best Reards.
Hiroshi Iwasaki
Iwasaki_Hiroshi@mse.mei.co.jp
Received on Monday, 3 December 2001 13:30:48 UTC