The existing code has some serious problems with the use of the base datetime.
For example, the set() method will attempt to unconditionally call set() on the base object. But if the base is 2003-02-10T00:00:00 and one calls "$dti->set( day => 30 )" then we'll get a validation error. But if the incomplete object only has a known year, there's no reason to error out (yet). And the docs say you can do "set( day => undef )" but that will clearly break badly. So clearly this needs fixing. I'm also not too keen on the way it stores the datetime data in both the incomplete object and the base object. It should all be in one spot, ideally, otherwise we'd end having to re-implement things like "quarter" and "day_of_week" and so on. I'm not quite sure how to do this though. Also, the whole attempt to be base class agnostic is only half there, and it makes a bit of a mess of the code. I'd rather take it out, because really implementing it is quite hard, and just makes for overly complex code. I think auto-generating incomplete classes for other calendars is a simpler solution, if it's ever needed. -dave /*======================= House Absolute Consulting www.houseabsolute.com =======================*/
