 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
| • |
When
memory for an object is allocated, a
|
|
|
reference
to that object is created and called the
|
|
|
“this”
reference
|
|
|
| • |
Like
C++, it is the first implicit argument to each
|
|
method
|
|
|
| • |
Unlike
C++, it is not a pointer but rather a
|
|
|
reference!
|
|
|
|
– |
list
func() { return this; }
|
|
|
|
– |
Which
means we do not need to dereference it
|
|
|
|
– |
It
allows member concatenation:
|
|
|
|
– |
Obj.func().func().func(); //etc.
|
|