Re: namespace DateTime::BusinessHours

[email protected] ("Flavio S. Glock")
Newsgroups perl.datetime
Message-ID <[email protected]>
2008/3/15, Rick Measham <[email protected]>:
>
>  (NOTE for other DT devs: It would be good if, given a DateTime::Set (or
>  DateTime::Set::ICal) you could get the $Nth day .. like the 10th day.
>  rather than an iterator and call it $N times or turning the set into a
>  list (which in this case is infinite))

DateTime::Event::ICal constructor allows to select the Nth occurrence:

  $dtset = DateTime::Event::ICal->new( ...., bysetpos => [ 10 ] );

"bysetpos" is not in the DateTime::Set API, but the infrastructure is
there (in Set::Infinite):

  $set = $set1->select( by => [ 10 ] );

- Flavio S. Glock
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.