2010/8/23 Mariano Martinez Peck <marianopeck@gmail.com>


On Mon, Aug 23, 2010 at 9:07 AM, Fernando olivero <fernando.olivero@usi.ch> wrote:
humm...I agree with Kent Beck and Stef, because conceptually a String shouldnt know how to answer #seconds.

Maybe its a matter of having better interactions, smarter text morphs , than introducing this in the "model".



maybe where are discussing what we prefer...if nice in words/language or better in OOP.

For example, I may (not sure) agree Number understands #seconds. But I may think also that a better OOP would not Number understand #seconds but stead have Duration seconds: 3

But...'3 seconds' is nicer...it is more similar to our language.


What do you think of��http://api.rubyonrails.org/classes/ActiveSupport/CoreExtensions/Numeric/Time.html��?

Indeed ��I don't like ��'2010/08/01' asTime, but I like 3 seconds.

Laurent

��

��
Fernando


On Aug 23, 2010, at 9:00 AM, Brent Pinkney wrote:

>> I would really like to have the approach proposed by K. Beck on conversion
>> methods. Conversion methods for API compatible objects. Of course it will
>> lead to less compact program (URL readFrom: 'http://' instead of 'http://'
>> url) but avoids a lot of code in String (of course class extensions limit
>> the plague).
>
> Hi, please reconsider this. There is just no way (Duration seconds: 3) is
> better than '3 seconds'.
>
> This smacks of working for the computer instead of the other way around.
>
> Brent
>
> _______________________________________________
> Pharo-project mailing list
> Pharo-project@lists.gforge.inria.fr
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
Pharo-project@lists.gforge.inria.fr
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
Pharo-project@lists.gforge.inria.fr
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project