On Wed, Oct 25, 2006 at 09:41:27AM -0500, Dave Rolsky wrote:
 
> I saw that you uploaded a new version with this name. The one other thing 
> I'd like to see to make it "fit in" is to make parse_datetime a class 
> method (at least optionally). Also, rather than taking a hash ref of 
> options, how about just making it check the number of args, so we can do 
> something like this:
> 
>   ->parse_datetime($string)
> 
>   ->parse_datetime( string => $string, debug => 1 );

Did both of it. But shouldn't we provide the options hash to new() instead?

> This would be more like all the other modules. It's quite possible you'll 
> need more options in the future. For example, you might want to have a 
> parameter that allows people to specify whether dates are in mdy or dmy 
> order.

Yeah, you're probably right.

> One thing I was thinking was that maybe eventually there could something 
> like this:
> 
>   DateTime::Format::Natural->parse_datetime( string => $string, locale => 
>   $dt_local_object );
> 
> The module could use the locale to figure out what module to load, or 
> maybe it could construct a parser based on info in the locale. It could 
> also use the locale to determine the native order for various components.

Could you elaborate some more about it; I currently don't grasp the meaning
of your words provided above.

> -dave

Regards,
Steven

--
#!/usr/bin/perl            http://steven.accognoscere.org   | /"\
print /\d+/ ? chr($_) : "\n" for grep {/[\d\%]+/} reverse   | \ /
split /\$/, '%$114$101$107$99$97$72$32$108$$114$101$80$32   |  X 
????????????$114$101$104$116$111$110$65$32$116$115$117$74'; | / \ 

Reply via email to