Obviously, the first is passed by value, but the second? We know p will reference the same object it referenced before the method invocation - the memory location it points to is the same. Because p will always point to the same memory location, is it not also passed by value?
;-) -----Original Message----- From: Mikkel Bruun [mailto:[EMAIL PROTECTED]] Sent: Friday, February 01, 2002 8:44 AM Ehh... primitives vs ojbects??? by value or by ref... whats the point?? -----Original Message----- From: Galbreath, Mark To: Struts (E-mail); J2ee (E-mail) What's the difference between int i = 3; someMethod( i); and Point p = new Point( 3, 3); someOtherMethod( p); ? Mark -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>