
On Tue, 11 May 2004 14:43:54 +0200, Daniel Krügler wrote
Hello boosters,
I would like to know whether there already exist ISO 8086
I assume you mean ISO 8601...
conforming extractors/inserters for the duration/period classes? Specifically I am looking for io/string functions which can handle "Periods of Time, no Specific Start or End", which begin with a 'P' following a list of periods, e.g.
"P18Y9M4DT11H9M8S" (18 years, 9 months, 4 days, 11 hours, 9 minutes and 8 seconds)
I'm afraid the library doesn't currently offer an extraction of this sort of duration. The primary reason is that I (and others) have had difficulty dealing with the imprecise nature of a time duration that includes years and months. The problem is, what is the length of a duration such as '3 months'? The answer is, it depends on which day you want to measure it from and what rules you want to apply. So for representing durations you currently only have days, hours, minutes, and seconds. So the question goes back to you -- what are you going to do with these durations? If you can answer that, it shouldn't be difficult to write a parsing function... Jeff