![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
Parameters are names that serve as handles for
objects that are supplied as message arguments, such as 4
in the
expression 194 convertToCaloriesWith: 4
.
Accordingly, whenever a convertToCaloriesWith:
message appears,
Smalltalk must arrange for the following to be done:
4
, with a parametersay
caloriesPerGram
specified by you when you define the
convertToCaloriesWith:
method.
self * caloriesPerGram
.
self * caloriesPerGram
for use in other
computations.