Alex Rivera | Logout

Is it inefficient to pass large objects as parameters in Java?

Asked 2011-07-29T08:38:50.067
42

Let's say for example I have a class A that creates an instance of a fairly big object B. Is passing B as a parameter to a method in a class C inefficient?

That is, does it just pass a reference or does it shift the object's memory around as well?

Thanks.

Edit
Report

1 Answer

1

It just pass a reference as value.

answered 2011-07-29T08:40:36.353

Your Answer