August 2003
Intermediate to advanced
672 pages
16h 23m
English
If an actual parameter is a reference to an object, then the reference value is passed. This means that both the actual parameter and the formal parameter are aliases to the object denoted by this reference value during the invocation of the method. In particular, this implies that changes made to the object via the formal parameter will be apparent after the call returns. The actual parameter expression must evaluate to an object reference before the reference value can be passed.
Type conversions between actual and formal parameters of reference types are discussed in Section 6.6.
public class CustomerTwo { public static void main (String[] args) { Pizza favoritePizza ... |
Read now
Unlock full access