> That's more or less how it works, actually :) I admit I've been way to busy to really follow how this module has been evolving (or even started!). It's unfortunate because I really am interested in it...
> > > week_year / set_week_year > > > week_number / set_week_number > > > day_of_week / set_day_of_week > > > > DateTime->new( year => $y ) or a undef > > DateTime::Duration( weeks => $w, days => $d ); > > No, year-week-day is a _different_ calendar. Ya - the screwed up ISO calendar. > That's why DateTime has "week_year". Now that I think about it this really should be a separate implementation unless we want to have special case logic. > > How about checking to see if an opposing value is > > already set? > > Yes, that's what I mean. > > Do you think this is better than having _separate_ > implementations for each calendar type? I did but I've changed my mind. :) I think there would be too many special cases to have it as an all in one. > Separate implementations would allow for easier > error checking (there will be a different syntax > for each class) and better program documentation. This is more important. > But a more "intelligent", single implementation, is > easier to use. Not necessarily. We'll just need to do some clever dispatching based on the named parameters. -J --
