Java: Pass by Value

Ever since I started coding in Java I’ve been regularly obliged to participate in conversations debating whether Java is a pass-by-value or pass-by-reference language. I’ve never been particularly hazy on the matter; Java is strictly a pass-by-value language and the values which are passed are pointers (to a memory location representing the data you are passing).

Lord knows there are enough articles online providing concrete examples of this fact. The one which I would recommend reading is here. Read the references too.

Leave a Reply