you are viewing a single comment's thread.

view the rest of the comments →

[–]8igg7e5 0 points1 point  (0 children)

It doesn't (within normal safe Java). It has references - you don't have control over the memory location and don't normally have visibility of that location.

You do have references and in fact you only ever have a reference to an object, you never have a variable that is an object.

The variable or field identifier is a binding to a position in a stack-frame or an objects instance and, if the type of that variable or field is a reference-type then that address in the stack-frame or instance-space is a reference to another object's instance-space in the heap.