On Mon, 21 Jun 2004, Rick Measham wrote:

> On 20 Jun 2004, at 9:04 AM, [EMAIL PROTECTED] wrote:
>
> > Dave Rolsky wrote:
> >> OTOH, set_time_zone() doesn't seem like it should
> >> be creating a new set.
> >
> > How about removing "set" from the method name -
>
> Ooh .. I like that.
>
> Although 'set' is a common mutator name, in DateTime::Set operations
> it's a bit ambiguous:
>
> $set->set_time_zone($x)
>
> Does this:
>       a) Change the time zone of the set: 'set' is a verb
>       b) Return a set with the time zone specified: 'set' is a noun
>
> However:
>
> $set->with_time_zone($x)
> Would return a set with the time zone
>
> $set->change_time_zone($x)
> Would change the time zone in the set

But DateTime.pm already has a set_time_zone() method, and people are
likely going to be exposed to that before DateTime::Set, so I think
keeping them consistent is more important.


-dave

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

Reply via email to