Java reference storage question

Posted by aab on Stack Overflow See other posts from Stack Overflow or by aab
Published on 2010-05-22T16:42:03Z Indexed on 2010/05/22 16:50 UTC
Read the original article Hit count: 131

Filed under:
|

In java, when you pass an object to a method as a parameter, it is actually passing a reference, or a pointer, to that object because objects in Java are references.

Inside the function, it has a pointer to that object which is a location in memory. I am wondering where this pointer lives in memory? Is a new memory location created once inside the function to hold this reference?

© Stack Overflow or respective owner

Related posts about java

Related posts about references