OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] What are the characteristics of a good type system for XML

[ Lists Home | Date Index | Thread Index ]

From: "J.Pietschmann" <j3322ptm@yahoo.de>

> Dare Obasanjo wrote:
> > the (a + b) + c !=  a + (b + c) problem if a is an xs:date
> > and b and c are durations,
> 
> You can have (a + b) + c !=  a + (b + c) with IEEE 754 floating
> point numbers too. Calendar algebra isn't as easy as everybody
> seems to think it should be, otherwise we'd have a standard for
> it for years. In particular it seems to be impossible to
> make it obey some axioms which hold for mathematical numbers.
> That's not all that unusual. Get over it.

I think the conventional answer is that uses of types outside the
characteristics that the WXS specs set is application dependent.
In other words, WXS does not tell you how to compare floats and 
doubles, but that does not mean it should not be done: it is just that
the details belong to you (and your implementation's) decisions. 

My feeling about the types needed by schema languages are that
by-and-large the types in the schema language only need to match
the types of the subsequent processing systems. So Schematron 
using XSLT expressions is entirely appropriate for validating
documents that then go to XSLT transformations, for example,
and XML Schemas is overkill for that kind of use. On the other
hand, for data going in to a database (in particular if the
data is not really being validated by the DBMS on import but
just being shovelled in) then a schema language with a type
system like that of the DBMS is appropriate (*and* Schematron!).

I kept out of the datatype side of WXS, but clearly numbers and 
dates are much more tricky to get even half workable than people
often expect. 

Cheers
Rick Jelliffe




 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS