What is pass-by-reference?
Are you preparing for IT certification? With practice questions, study notes, interactive quizzes, tips and technical articles, uCertify PrepKits ensure that you get a solid grasp of core technical concepts to ace your certification exam in first attempt.
What is pass-by-reference?
Rating:
In pass-by-reference, an object reference is passed to the calling method. The object reference that is passed is a copy of the original object reference and not the actual reference itself. Therefore, the caller and the called method will have identical copies of the reference. Hence, both of them will refer to the same object, and the changes made in the object in the called method will be reflected in the original method also.
Rating:
Was this information helpful?
Other articles
- What is a native method?
- Modifiers
- What are static methods?
- What is static import?
- What is the finalize() method?