On Sat, 20 Sep 2003, Syamala Tadigadapa wrote:

> Even in the datetime project code, may be you can add a method to supply the
> weekday of jan_first of present year if desired useful. May be a method can

 $dt->clone->truncate( to => 'year' )->day_of_week

I don't think that justifies a new method.  Also, I don't want to add
accessor methods that return information about dates which the current
object doesn't represent.  That's just too confusing.

> be added to return the count of specific week day occurrence in the year
> present. And these methods could be based on the Zeller's congruence

Do you mean something like this:

  $dt->weekday_count; # returns 33, because this is the 33rd Sunday of the year

or something like this:

  DateTime->day_count_in_year( year => 1999, day => 4 );

What would people need this info for?


-dave

/*=======================
House Absolute Consulting
www.houseabsolute.com
=======================*/

Reply via email to