User Tools

Site Tools


at:tutorial:objects

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
at:tutorial:objects [2007/07/02 13:43] jorgeat:tutorial:objects [2007/07/03 09:57] jorge
Line 101: Line 101:
  
 <note important> <note important>
-In AmbientTalk, ''self'' and ''super'' indicate the current object and its parent respectively. While the former corresponds a language keyword the latter is just a field name of the object.+In AmbientTalk, ''self'' and ''super'' indicate the current object and its parent respectively. While the former corresponds to a language keyword the latter is just a field name of the object.
 </note> </note>
  
 ===== First-class delegation ===== ===== First-class delegation =====
-AmbientTalk provides an explicit delegation operator ''^''. The code below illustrates the use of this operator in the implementation of the ''init'' method of the ''point3D'' object.+AmbientTalk provides an explicit delegation operator ''^'' (the "caret" or "hat" symbol). The code below illustrates the use of the ''^'' operator in the implementation of the ''init'' method of the ''point3D'' object.
  
 <code> <code>
Line 117: Line 117:
 </code> </code>
  
-A message sent to an object using this symbol (e.g. to the parent object in the example above) will first look for the method that matches the selector indicated in the message in this object (and its parents) and then execute the method body in the lexical scope of the message sender.+A message sent to an object using the ''^'' symbol (e.g. to the parent object in the example above) will start the method lookup in this object (and its parents) and then execute the method body in the lexical scope of the message sender (''self'' is bound to the message sender).
  
 ===== Encapsulation ===== ===== Encapsulation =====
at/tutorial/objects.txt · Last modified: 2013/05/17 20:23 by tvcutsem