Re: More tweaks on time related datatypes and minor editorial

Steve Slatcher wrote:

> In a timeDuration a month has 30 days!
So if someone is charging me $10 per month for a service, and I place an
order using XML Schema for P12M,  I will get 360 days of the service?  I
think not.  I would expect a year - 365 days or 366 days depending on the
context.  If I wanted 360 days, I would use P360D

Hopefully, the spec will make it clear that any approximation (either 1M ==
30D or 1M= 30.43D) is only used in the evaluation of boundaries.  I would
suggest that the parsers represent time duration as a class with both a
integer number of months and a float number of seconds.  Definitely, an
application must be able to distinguish between 1M and 30D.

Knowing the approximations, you can then choose your boundaries
appropriately.  If the approximation was 1M == 30D, then you would probably
use P366 as an maxInclusive bound which would both include the approximation
of 1Y == 360D and 365D or 366D.

Unfortunately, without an approximation (or some way to bind a timeDuration
to a specific instant in time), it is not possible to do a comparision
between durations with month and year terms and those with day, hour, minute
or second terms.

I still like my values better since they reduce some of the more blatant
errors in the approximation, however they are still an approximation.

Received on Tuesday, 25 January 2000 09:48:37 UTC