> I expected the following to work since Objects are supposedly
> pass-by-reference. Am I doing something wrong here?
Yes: in the method you are chaning the reference, not the obejct.
E.g.:
Boolean a = Boolean.TRUE;
Boolean b = a;
b = Boolean.FALSE;
at this point, a is still equal to Boolean.TRUE. The third line simply
assigns b (the reference, NOT the object) to point to Boolean.FALSE.
--
/ Peter Schuller
PGP userID: 0x5584BD98 or 'Peter Schuller <[EMAIL PROTECTED]>'
Key retrival: Send an E-Mail to [EMAIL PROTECTED]
E-Mail: [EMAIL PROTECTED] Web: http://hem.passagen.se/petersch
----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]