Units of measurement?
rbourret at ito.tu-darmstadt.de
Thu Jul 15 09:50:12 BST 1999
Jeffrey E. Sussna wrote:
> Does the XSchema datatypes spec support the notion of units of
> In other words:
> element "x" is of type "speed", which can be in "mph" or "kph"
> A potential representation of this might be:
> <x units="mph">200</x>
Sort of. What you can actually do is define a speed data type and say that
the *units* attribute (not the x element) is of type speed -- that is, its
value is either "mph" or "kph". You can also say that the x element must
have a units attribute.
Note that you can also do this specific example with DTDs, by defining
units as an attribute with an enumerated type.
(Nit: XSchema is the name of the predecessor of DDML. I believe you are
referring to XML Schemas -- the schema language being developed by the W3C.
Given the amount of confusion over these names, I'm beginning to wonder if
we shouldn't donate the XSchema name to the W3C...)
-- Ron Bourret
xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1
To (un)subscribe, mailto:majordomo at ic.ac.uk the following message;
To subscribe to the digests, mailto:majordomo at ic.ac.uk the following message;
List coordinator, Henry Rzepa (mailto:rzepa at ic.ac.uk)
More information about the Xml-dev