DateTime::Set iterator

2003-03-15 Thread fglock
I'm not sure of how the DateTime::Set iterator should behave. Would you give me an example? I've got a sketch: if ( $set->is_infinite ) { warn "this is an infinite set"; print "first date is ", $set->min; print "second date is " ...

Re: DateTime::Set iterator

2003-03-15 Thread Dave Rolsky
On Sat, 15 Mar 2003 [EMAIL PROTECTED] wrote: > I'm not sure of how the DateTime::Set iterator should behave. > > Would you give me an example? I've got a sketch: > > if ( $set->is_infinite ) { > warn "this is an infinite set"; > print "fir

Re: DateTime::Set iterator

2003-03-15 Thread fglock
ction parameter as well. > It will return an object of the DateTime::Set::Iterator class, though it's possible there will be a need for multiple subclasses of that class (I don't know yet). > > BTW, how does Set::Infinite decide the "min" and "max" eleme

Re: DateTime::Set iterator

2003-03-15 Thread Dave Rolsky
On Sat, 15 Mar 2003 [EMAIL PROTECTED] wrote: > By "multiple subclasses", do you mean > DateTime::Set::Iterator, DateTime::Span::Iterator, SpanSet::Iterator ? No, I was thinking more for internal implementation details like there might be one iterator to handle user-provided call

Re: DateTime::Set iterator

2003-03-15 Thread fglock
> No, I was thinking more for internal implementation There is no need for a different iterator. Internally, everything are "sets". You could create a set using new DateTime::Set( day => 3, every => 'month' ) and then use the same iterator that works with callbacks. > Anyway, the start and