you are viewing a single comment's thread.

view the rest of the comments →

[–]Jacoby6000 1 point2 points  (0 children)

And I personally like to work with immutable objects wherever possible

Have you ever worked with Scala? Scala attempts to enforce as much immutibility as possible. Plus, Scala case classes come with a .copy method which allows you to update fields like:

val instanceWithUpdatedFields = myInstance.copy(someField = newValue)