Re: ANNOUNCE: DateTime::Incomplete 0.00_03 in CVS

2003-07-21 Thread fglock
Flavio S. Glock wrote > There are a few missing bits: > > no has_month() - but has('month') is ok. Now month() and has_month() are ok! - Flavio S. Glock

ANNOUNCE: DateTime::Incomplete 0.00_03 in CVS

2003-07-21 Thread fglock
- DateTime::Incomplete 0.00_03 Most functionality discussed in the DT::Complex thread is implemented. Mayan calendar datetimes should work, but it has not been tested! There are a few missing bits: no has_month() - but has('month') is ok. no fields() no base_class() there is no def

Re: [Perl-date-time-dev] has(), get()

2003-07-21 Thread Dave Rolsky
On Mon, 21 Jul 2003, Flavio Soibelmann Glock wrote: > has(), get() I really dislike this API. The object should look as much like a DateTime.pm object as possible. For other calendars, we can come up with some clever way to auto-generate appropriate classes for them, if that's necessary. But I

Re: FAIL DateTime-TimeZone-Alias-0.05 sun4-solaris 2.8 (fwd)

2003-07-21 Thread Dave Rolsky
On Mon, 21 Jul 2003, Joshua Hoblitt wrote: > DateTime::TimeZone::Local::_from_etc_timezone needs to be modified for > Solaris. Is there a perfered way of doing this? I can either check the > osname then decided what path to execute or just always check for > /etc/TIMEZONE. The latter. I'd assu

FAIL DateTime-TimeZone-Alias-0.05 sun4-solaris 2.8 (fwd)

2003-07-21 Thread Joshua Hoblitt
DateTime::TimeZone::Local::_from_etc_timezone needs to be modified for Solaris. Is there a perfered way of doing this? I can either check the osname then decided what path to execute or just always check for /etc/TIMEZONE. -J -- -- Forwarded message -- Date: 21 Jul 2003 11:37

Re: RFC: DateTime::Complex

2003-07-21 Thread Dave Rolsky
On Mon, 21 Jul 2003, Flavio S. Glock wrote: > > We can also have autoloaded procedures like has_month(), get_month() or > > just month(). > > Yes, but I've seen some talk in this list, that autoloading is bad. > Anyone has opinions on this? Autoloading is bad, because it breaks '->can'. If DT::I

Re: RFC: DateTime::Complex

2003-07-21 Thread Flavio S. Glock
Claus Färber wrote: > > Flavio S. Glock <[EMAIL PROTECTED]> schrieb/wrote: > > print $dtij->has( 'month' ); > > # 0 > > print $dtim->has( 'kin' ); > > # 1 > > print $dtim->get( 'kin' ); > > # 8 > > We can also have autoloaded procedures like has_month(), get_month() or > just month().

Re: RFC: DateTime::Complex

2003-07-21 Thread Claus Färber
Flavio S. Glock <[EMAIL PROTECTED]> schrieb/wrote: > print $dtij->has( 'month' ); > # 0 > print $dtim->has( 'kin' ); > # 1 > print $dtim->get( 'kin' ); > # 8 We can also have autoloaded procedures like has_month(), get_month() or just month(). > You can get a 'normal' DateTime by ca

Re: RFC: DateTime::Complex

2003-07-21 Thread Flavio S. Glock
Dave Rolsky wrote: > > On Mon, 21 Jul 2003, Flavio S. Glock wrote: > > > I'd like to have this in DateTime: > > > > set( time_zone => $tz ); > > You mean as opposed to set_time_zone? Yes. We could have both. - Flavio S. Glock

Re: RFC: DateTime::Complex

2003-07-21 Thread Dave Rolsky
On Mon, 21 Jul 2003, Flavio S. Glock wrote: > I'd like to have this in DateTime: > > set( time_zone => $tz ); You mean as opposed to set_time_zone? > set( locale => $loc ); This already exists; > get( time_zone/locale/year/month/etc ); > # returns a number or an object > > get_str( t

Re: RFC: DateTime::Complex

2003-07-21 Thread Flavio S. Glock
This is a DateTime::Incomplete API upgrade RFC, based in ideas from Claus Färber, Eugene van der Pijll and others: $dtj = DateTime::Calendar::Julian->new( year => 1970 ); $dtm = DateTime::Calendar::Mayan->new( baktun => 0 ); $dtij = DateTime::Incomplete->new( y

Re: RFC: DateTime::Complex

2003-07-21 Thread Claus Färber
Dave Rolsky <[EMAIL PROTECTED]> schrieb/wrote: > In fact, we might even want to insist that "parse_datetime" _always_ > return a complete object or fail, and then offer an additional > "parse_incomplete_datetime" method or something like that. You're right. I thought of something like this: use

Re: DateTime::Format::ISO8601 namepsace

2003-07-21 Thread Claus Färber
Joshua Hoblitt <[EMAIL PROTECTED]> schrieb/wrote: >> But then, being able to specify the set of ISO formats used might be >> essential for parsers that use the ISO parser for some formats. > Can you give an example of how this might be useful? If someone wants to say "only > parse this format" th

[ANNOUNCE] DateTime::TimeZone::Alias 0.05

2003-07-21 Thread Joshua Hoblitt
Released to CPAN. Available immediately from: http://kolea.ifa.hawaii.edu/~jhoblitt/pm/DateTime-TimeZone-Alias-0.05.tar.gz Changes since 0.04 - floating, local, UTC, Z, and offsets can now be aliased - docs updated Cheers, -J --