Clean Java code to not change set in getter