You can call a setter on a "val". You're not replacing the reference altogether, only updating a field.