W3C home > Mailing lists > Public > xmlschema-dev@w3.org > June 2002

RE: union(?) question

From: Biron,Paul V <Paul.V.Biron@kp.org>
Date: Tue, 4 Jun 2002 18:45:26 -0700
Message-Id: <8904C60CACA7D51191BC00805FEAAF4358ED34@crdc-exch-7.crdc.kp.org>
To: "'Doug'" <ummmmm22@yahoo.com>, xmlschema-dev@w3.org

> -----Original Message-----
> From:	Doug [SMTP:ummmmm22@yahoo.com]
> Sent:	Tuesday, June 04, 2002 6:20 PM
> To:	xmlschema-dev@w3.org
> Subject:	union(?) question
> 
> i'm trying to define 4 custom, "named" simpleTypes,
> each a restriction of xsd:string, then combine them
> into a "named" type that allows any one of those
> simpleType formats.
> 
> i'm very new to XML Schema, and the only thing i could
> come up with that seems promising is "union".  so...
> would this syntax do the trick?  is there a better
> way?
> 
>       <xsd:simpleType name="AcceptedCreditCards">
>          <xsd:union memberTypes="VisaNumber
> MasterCardNumber AMEXNumber DiscoverNumber"/>
>       </xsd:simpleType>
> 
that's exactly how you'd do it.

pvb
Received on Tuesday, 4 June 2002 21:47:47 GMT

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