r/learnjava • • Mar 30 '15

How to make Immutable objects in Java?

http://javarevisited.blogspot.sg/2013/03/how-to-create-immutable-class-object-java-example-tutorial.html
1 Upvotes

5 comments sorted by

View all comments

1

u/BertRenolds Mar 30 '15

Look up " final"

2

u/king_of_the_universe Mar 31 '15

OP fucked up the title. OP posts Java knowledge links all the time. This post was not a question.

Also, final has nothing to do with actual object mutability, just quasi when it comes to practice (using a certain identifier).

0

u/[deleted] Mar 30 '15

[deleted]

1

u/BertRenolds Mar 30 '15

0

u/[deleted] Mar 30 '15

[deleted]

0

u/BertRenolds Mar 30 '15

0

u/[deleted] Mar 30 '15

[deleted]

1

u/BertRenolds Mar 30 '15

which is why if you look up final, and immutable it tells you all the doc you need to know..

it's "learnJava" not "giveItToMeOnASilverPlatter".

I'm done with this