"Pattern Hatching"

Daniel Altman (Da Vinci) Daniel.Altman at disco.com.ar
Fri Nov 29 13:32:12 UTC 2002


Hi Richard!

>>	- variables --> internal collaborators
>>	- parameters --> external collaborators

>The collaborators are NOT the variables, they are the VALUES of the
variables. 
Of course! You won´t expect an object to send a message to a computer memory
area! ;-P

Maybe I wasn´t clear enough, as you said in another post, we usually don´t
say exactly (formaly) what we mean, which is impossible because spoken
language is not formal. So, please don´t take things too literally.

We call "collaborators" to the objects, not to their memory storage. 

More important than this is that an object really don´t "know" its
collaborators, it only knows that behind a certain "role" (or "variable
name", or "collaborator name", or simply "name") there is someone that is
expected to complain to some protocol.



> The distinction between 'internal collaborators' and 'external
collaborators' is also a bad one.
>  The distinction between instance variables and method arguments is one of
BINDING TIME only, having nothing whatsoever to do with internal/external

The concept is that an external collaborator is one that the object "knows"
only in the context of a certain collaboration. An internal collaborator is
one "known" along the entire lifetime of the object.


>What I find very serious here is that someone (almost certainly NOT Daniel
Altman, but perhaps someone who taught him) has tried to LEGITIMISE the
distinction between primitive values and objects that we find in C++ and
Java.  We find no such distinction in Eiffel or Smalltalk.  In both Eiffel
and Smalltalk, *everything* is an object.
>It has been conventional to call the boxes that hold references to objects
"variables"

That´s a very unfair conclusion...I was taught that in OOP we only have
objects and messages, nothing else. May also be that there are things I
didn´t catch, so please don´t put my teachers in the middle.
One of the reasons we don´t use the word "variable" is that it sounds too
imperative, thus making more difficult to switch our minds to OO.




More information about the Squeak-dev mailing list