[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: Managing metadata about attribute types

James Britt

11/8/2003 5:28:00 PM


>
> Let me add that neither this point nor this whole discussion is
> exclusively about Ryan's StrongTyping module. That module provides a
> convenient wrapper for calling #is_a? a lot, and the robustness and
> scaleability of calling #is_a? a lot had been called into question by
> a number of Rubyists long before StrongTyping appeared. Ryan is
> bearing the brunt of the 'nay' side of it this time around, but that's
> just because of the timing :-)

In some ways this discussion reminds me of issues in teaching OO
programming, and the difference between "sending a message" and "calling
a method."

What seems like a good deal of OO literature (perhaps because of a focus
on Java) equate the two, losing the idea that, in OO-purist theory (at
least to the edtent I see it), the fact that because an object is
willing to handle some given message does not mean that the object
implements a method of the same name.

This disconnect often leads to the use of OO techniques to write nicely
namespaced procedural code, where classes mainly exist to group methods
rather than to coordinate behavior.


James