W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > April to June 2002

XML1..1: Can we please have a derived atomic type?

From: by way of <mark@magpiesnest.co.uk>
Date: Wed, 05 Jun 2002 10:30:23 +0200
Message-Id: <5.1.0.14.1.20020605103020.02685458@localhost>
To: W3C XML Schema Comments list <www-xml-schema-comments@w3.org>




One of the major things missing from version 1 is the ability to define new 
atomic types as a combination of existing types. As an example, the 
construction of a "currency" type that might consist of the two simple 
atomic types:

eg. currencycode: string, restricted to "", "$" etc.
     currencyval : decimal, 2 fractional digits

->  currency    : union of: currencycode & currencyval

So, this new atomic type would permit values such as 27.20 and $7.01 but 
would reject both "" and "15.88" and "15.1" etc.

Comments would be welcome.
Received on Wednesday, 5 June 2002 04:39:39 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Sunday, 6 December 2009 18:13:01 GMT