On Sat, 19 Jun 2004 [EMAIL PROTECTED] wrote:

> How about removing "set" from the method name -
>
>  $br_set = $set->with_time_zone('America/Sao Paulo');
>  $br_set = $br_set->with_locale('pt_BR');

Well, the idiom which I use in the DateTime.pm docs, and in my actual
code, is this:

 my $new_dt = $dt->clone->set_time_zone( ... );

So if I want a new set I simply call clone() and then chain on mutators.

> The mutators, if any, could be:
>
>  $set->change_time_zone(to => 'America/Sao Paulo');
>  $set->change_locale(to => 'pt_BR');

I don't see change_ as being preferable to set_.

> Anyway, should I change both set_time_zone() and set(locale=>) to be
> mutators ?

I think so, but let's give people some time to voice any objections.  This
will break backwards compatibility, so I want to hear from anyone who
might have a problem with it.


-dave

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

Reply via email to