- From: Kasahara, Miki <Miki.Kasahara@getronics.com>
- Date: Mon, 08 Jul 2002 11:39:47 -0600
- To: W3C XML Schema Comments list <www-xml-schema-comments@w3.org>
We define some common simpleTypes because we will use them several times in XMLs. and I would like to choose one simpleType between common simpleType in one tag(element). If you know some answers, please advice me! ex) ================== in XML, it will be... ------------------ <A>abcde</A> <!-- 6 small character --> ------------------ OR ------------------ <A>1234567890</A> <!-- 10 number --> ------------------ ================== in schema, I would like to choose several simpleTypes. ================== <xs:element name="A"> <!-- WE WOULD LIKE TO CHOOSE TYPE --> CHOOSE REF="alf simpleType" OR REF="num simpleType" </xs:element> <!-- "alf" simpleType --> <xs:simpleType name="alf"> <xs:restriction base="xs:string"> <xs:pattern value="[a-z]{6}"/> </xs:restriction> </xs:simpleType> <!-- "num" simpleType --> <xs:simpleType name="num"> <xs:restriction base="xs:string"> <xs:pattern value="[0-9]{10}"/> </xs:restriction> </xs:simpleType> Thank you! miki kasahara -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*- Miki Kasahara http://jp.getronics.com/ Professional ServiceDivision e-Solutions Development Department Getronics Japan, LTD -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-
Received on Monday, 8 July 2002 13:50:39 UTC