Re: Parser Interface (Was Re: Picking up the ball)

2003-01-14 Thread Matthew Simon Cavalletto
On Monday, January 13, 2003, at 10:14 PM, Dave Rolsky wrote: I _don't_ want to discuss implementation of this. I want to talk about the API! Agreed; I'm making this argument specifically because I think the proposed API is clearer. Looking at the two alternatives, does the second really

Re: Parser Interface (Was Re: Picking up the ball)

2003-01-14 Thread John Peacock
Dave Rolsky wrote: use DateTime; use DateTime::Parse::MySQL; my $dt = DateTime::Parse::MySQL-new_datetime( $mysql_dt ); print DateTime::Parse::MySQL-mysql_datetime( $dt ); I can also imagine some other scheme, where parse/format modules register the formats they can handle with

Re: Parser Interface (Was Re: Picking up the ball)

2003-01-13 Thread Dave Rolsky
On Mon, 13 Jan 2003, Matthew Simon Cavalletto wrote: What's the benefit of making this distinction between core and other formats? Because core parsing would be available simply by doing: use DateTime; That's about it. Why not define a parser interface and include the basic formats as