Re: new DateTime::Format module
[email protected] (Dan Muey)
| Newsgroups | perl.datetime |
|---|---|
| Message-ID | <[email protected]> |
> Right, the confusion is that there is a DateTime::Span class, and > I'd expect DateTime::Format::Span to take an object of that class > and format it. > > However, your module only operates on durations. Even more > confusingly, it offers a "format_duration" method which only accepts > a single duration, which is _not_ a span. > > This really is not a good name for your module, because of this > reason. Ah I see, that does make sense. I see what he means now. I'm not sure how I didn't see that. I'll take it offline until I can get a better name. >> Some of the information you define in the locale modules does exist >> in CLDR, notably singular versions of things like "day", "month", >> etc. if you add the singular and plural information to the auto generated DateTime::Locale I'd be happy to use it instead > CLDR also includes formats for doing things like formatting a span > based on the "greatest unit of differnece" between two dates. It's > rather complicated, so I haven't implemented it yet. Basically, it > lets you format something intelligently so you get "Jan 10-12" vs > "Jan 10 - Feb 10". cool