Q:

Regarding java references

When I going through java tutorials I got an idea about the pointers are not used in java. but java internally uses pointers, but when we look through developer perspective java supports references only. Then why java does not support pass by reference?

A:

All object variables are just references, so when you pass an object you're actually passing by reference (technically you're passing a reference variable which gets copied by value). The only things that are passed by value are primitive types like int.

A:

Java does manipulate objects by reference, and all object variables are references. However, Java doesn't pass method arguments by reference; it passes them by value.
Source
How to do the equivalent of pass by reference for primitives in Java
Possible Duplicate

