> Flavio S. Glock <[EMAIL PROTECTED]> wrote:
>
> How about to extend the 'to_datetime' method,
instead of creating a
> new
> one:
>
>if ($dti->can_be_datetime) {
> $dti = $dti->to_datetime
>}
>
Sounds good .. and it's as simple as using
DateTime->today as the base, wh
> Flavio S. Glock <[EMAIL PROTECTED]> wrote:
> > sub has {
>
> I implemented this in CVS with tests, but I believe it
> should be 2 separate methods instead. What do
you think?
I'm cool with two different methods ... it really is two
different things. Maybe there's also a need for
has_a
> [EMAIL PROTECTED]
<[EMAIL PROTECTED]> wrote:
> sub has_time { $_[0]->has{'hour', 'minute'} }
Maybe should be:
sub has_time {
return 1 if ($_[0]->has('hour', 'minute') and not
$_[0]->has('nanosecond'));
return 1 if ($_[0]->has('hour', 'minute', 'second'))
return 0
}
Whic
[webmail logged me out, so sorry if you get ++ copies]
> Flavio S. Glock <[EMAIL PROTECTED]> wrote:
> So this is the current list of proposed
DT::Incomplete methods that
> are
> "waiting for votes":
>
> * epoch
> $epoch = $dti->epoch if $dti->can_be_datetime;
Sounds go
> David Hood <[EMAIL PROTECTED]> wrote:
> Perhaps you should return only the information that
is given, in an
> iso 8601
> compliant format, so for November 2003 you could
simply return
> 2003-11. The
Nah, that's not going to happen. The entire point of
the module is to get a DateTime obj