Re: quick benchmarks DT vs. Date::Manip

2003-03-25 Thread Dave Rolsky
On Mon, 24 Mar 2003, Joshua Hoblitt wrote: Maybe something like this should be added to the docs? -- diff -ur DateTime-0.08/lib/DateTime.pm new.DateTime/lib/DateTime.pm --- DateTime-0.08/lib/DateTime.pm 2003-03-20 20:02:27.0 -1000 +++ new.DateTime/lib/DateTime.pm

Re: quick benchmarks DT vs. Date::Manip

2003-03-25 Thread Joshua Hoblitt
The reason I'm not sure it belongs in the docs is that it may be better as part of the upcoming FAQ. Or maybe a DateTime::Cookbook? -J --

Re: quick benchmarks DT vs. Date::Manip

2003-03-25 Thread Dave Rolsky
On Mon, 24 Mar 2003, Joshua Hoblitt wrote: The reason I'm not sure it belongs in the docs is that it may be better as part of the upcoming FAQ. Or maybe a DateTime::Cookbook? Sure. I suppose the FAQ could be turned into POD somehow and included with each DateTime.pm release or something

Re: Request for DateTime API addition: today() constructor

2003-03-25 Thread Tim Bunce
On Mon, Mar 24, 2003 at 06:59:17PM -0600, Dave Rolsky wrote: On Mon, 24 Mar 2003, Joshua Hoblitt wrote: True. Though it'll be so commonly used I think it deserves a constructor. Ditto. It would also be nice if it defaults to current TZ instead of a floating time. The same for -now.

DateTime::Event::Sunrise Beta number 2

2003-03-25 Thread Hill, Ronald
Hi All, I have just completed the beta 2 for the DtaeTime::Event::Sunrise module. Please test and let me know of any problems. I have changed the constructor to use named parameters. I also changed the names to use full names. Thanks for all of the suggestions! Ron Hill Sunrise.pm

Fundamental addition request

2003-03-25 Thread Tim Allwine
I was wondering if you would consider making a fundamental addition to DateTime. It would be to add the 'quarter' and 'day_of_quarter' to DateTime. Attached is a patch to DateTime.xs, DateTime.pm and t/03components.t. It is working for me, although t/09greg.t would have to be changed too.

Calsys Lang Namespaces

2003-03-25 Thread Daniel Yacob
Greetings, I was considering the issue of languages and calendar systems and would like to get some input from the group on the matter. Taking DateTime::Calendar::Ethiopic as a specific example, should languages then go under DateTime::Calendar::Ethiopic::Language::locale ? Versus possibly

DateTime::Event::Sunrise Beta number 3

2003-03-25 Thread Hill, Ronald
Hi All, I have just completed the third beta for the Sunrise module. I have added a set method (no documentation yet)I used the set API from Rick's easter module (Thanks Rick!!)Here is the perl script I used to test: #!/usr/bin/perl use strict; use warnings; use DateTime; use

Re: Calsys Lang Namespaces

2003-03-25 Thread Eugene van der Pijll
Daniel Yacob schreef: I favor the first option, but then I also favor Gregorian:: as a name space and no default calendar system being assumed... ;-) Unfortunately, us kalandariophiles are a minority on this list; I suspect Dave in particular of wanting to use DateTime for all kinds of worldy,

DateTime::Event::Easter - Beta 2

2003-03-25 Thread Rick Measham
Attached is Beta 2. I think I've incorporated all suggestions. If I've missed anything, let me know. Beta 2 includes support for Orthodox Easter, however I doubt it handles it the best way possible. Please take a look and offer suggestions (its the last sub before the POD). It should also be

RE: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Hill, Ronald
Hi Rick, [snipped] The -set method is now -as_list and I've added -as_set which returns a DateTime::Set object (although this isn't tested at ALL! CPAN wouldn't give me DateTime::Set :)) I guess I jumped the gun a bit, I will follow suit and make the changes to the Sunrise module. Does

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Flavio S. Glock
Hill, Ronald wrote: Does anyone know where I can get the DateTime::Set module? It is in the cvs (http://sourceforge.net -- project perl-date-time). I'll update CPAN now. - Flavio S. Glock

Re: DateTime::Event::Sunrise Beta number 3

2003-03-25 Thread Dave Rolsky
On Tue, 25 Mar 2003, Hill, Ronald wrote: my $sunrise = DateTime::Event::Sunrise -new( Longitude ='-118' , Latitude = '33', ); For consistency with other DateTime modules, it'd be good if the parameter names were lower case. A couple others nits:

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Dave Rolsky
I'm going to pick nits, because I'm anal. - It'd be good to name the variables that are constants either in all caps or in StudlyCaps - You don't need to load Data::Dumper - Your editor produces satanic tabbing indentation! What are you using? When I load the code in emacs or vi it scrolls off

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Rick Measham
Thanks Eugene! This is excellent! On 26/3/03 8:42 am, Eugene van der Pijll at [EMAIL PROTECTED] spake thus: Rick Measham schreef: Beta 2 includes support for Orthodox Easter, however I doubt it handles it the best way possible. Please take a look and offer suggestions (its the last sub

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Rick Measham
On 26/3/03 9:09 am, Dave Rolsky at [EMAIL PROTECTED] spake thus: I'm going to pick nits, because I'm anal. Picking nits is good, but I swear I showered and combed my hair this morning! - It'd be good to name the variables that are constants either in all caps or in StudlyCaps Will do -

Re: Fundamental addition request

2003-03-25 Thread Tim Allwine
Eugene van der Pijll wrote: Tim Allwine schreef: I was wondering if you would consider making a fundamental addition to DateTime. It would be to add the 'quarter' and 'day_of_quarter' to DateTime. RGH! Please no! 'week' and 'day_of_year' were two of the hardest methods to write in

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Eugene van der Pijll
Rick Measham schreef: Best solution would perhaps to convert to Julian at the start of those methods, and to convert them back to Gregorian at the end. (DateTime::Calendar::Julian could be useful here ;-) Yeah, I figured I might have to do that, although then rather than finding the

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Dave Rolsky
On Tue, 25 Mar 2003, Eugene van der Pijll wrote: other than: eval(use DateTime::Set); croak(Couldn't load DateTime::Set:.$@) if $@; Block-eval is better than string-eval. Also I think 'require' is used more often than 'use' in these kind of constructs, but I don't think there's a

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Rick Measham
On 26/3/03 9:44 am, Eugene van der Pijll at [EMAIL PROTECTED] spake thus: Rick Measham schreef: Best solution would perhaps to convert to Julian at the start of those methods, and to convert them back to Gregorian at the end. (DateTime::Calendar::Julian could be useful here ;-) Yeah, I

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Eugene van der Pijll
Rick Measham schreef: Can't use a block eval for 'use X'. All 'use X' commands are parsed before anything else, so it will always try to use X, even if we don't go there. Yes, of course, stupid me. 'require X' happens at run-time so doesn't need to be eval-ed. Except if you want to catch the

ANNOUNCE: DateTime::TimeZone 0.11

2003-03-25 Thread Dave Rolsky
0.11 2003-03-26 the Asia/Baghdad release - Fixed two bugs, both of which made some time zones unusable.. One affected time zones that do not have any DST changes, and the other affected time zones that have exactly two historical offsets (one of which would be the current offset), such as

Re: ICal and timezones

2003-03-25 Thread Iain 'Spoon' Truskett
* Joshua Hoblitt ([EMAIL PROTECTED]) [26 Mar 2003 18:05]: * Dave Rolsky wrote: [...] Certainly. I was just proposing returning something _correct_, but a bit unexpected. Something like this? I'll added tests if requested. Or the other option: (I make a clone so as to not disturb any

Re: Fundamental addition request

2003-03-25 Thread Eugene van der Pijll
Tim Allwine schreef: I was wondering if you would consider making a fundamental addition to DateTime. It would be to add the 'quarter' and 'day_of_quarter' to DateTime. RGH! Please no! 'week' and 'day_of_year' were two of the hardest methods to write in DT::C::Christian, and now you

Re: Request for DateTime API addition: today() constructor

2003-03-25 Thread Joshua Hoblitt
On Tue, 25 Mar 2003, Tim Bunce wrote: On Mon, Mar 24, 2003 at 06:59:17PM -0600, Dave Rolsky wrote: On Mon, 24 Mar 2003, Joshua Hoblitt wrote: True. Though it'll be so commonly used I think it deserves a constructor. Ditto. It would also be nice if it defaults to current TZ instead

RE: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Hill, Ronald
Hi Rick, Attached is Beta 2. I think I've incorporated all suggestions. If I've missed anything, let me know. [snipped] The -set method is now -as_list and I've added -as_set which returns a DateTime::Set object (although this isn't tested at ALL! CPAN wouldn't give me

Re: Quick question: fractional seconds

2003-03-25 Thread Dave Rolsky
On Tue, 25 Mar 2003, John Siracusa wrote: What's the status of fractional seconds? Static ;) As in not being worked on because I have no idea what do with it ;) Proposals, and even better, patches, are welcome. -dave /*=== House Absolute Consulting www.houseabsolute.com

Re: DateTime::Event::Easter - Beta 2

2003-03-25 Thread Eugene van der Pijll
Rick Measham schreef: Beta 2 includes support for Orthodox Easter, however I doubt it handles it the best way possible. Please take a look and offer suggestions (its the last sub before the POD). It should also be noted that both Easters should return Gregorian Dates as they do now. The

Re: Calsys Lang Namespaces

2003-03-25 Thread Dave Rolsky
On Tue, 25 Mar 2003, Eugene van der Pijll wrote: Unfortunately, us kalandariophiles are a minority on this list; I suspect Dave in particular of wanting to use DateTime for all kinds of worldy, modern, boring stuff. Well, I'm interested in other calendars as well. My wife's Taiwanese so I've