Bummer! You must be logged in to access this page.
Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
Well done!
You have completed Java Objects!
You have completed Java Objects!
Preview
You can protect your variables from re-assignment using the final keyword
Resources
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign upRelated Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up
and after creation,
you currently can't change the character.
0:00
This models what happens in real life.
0:02
Pez dispenser heads
don't change after manufacturing.
0:04
But we're only pretty safe right now.
0:07
Like we said earlier,
0:09
what if we accidentally add a method later
that changes the character name?
0:11
Or what if we're working on a team
and someone doesn't realize
0:15
that the character names shouldn't change?
0:18
We would hopefully catch this in code
review, but there's something even better
0:20
we can do.
0:23
Let's simulate the scenario,
and I'll introduce
0:25
a concept
that will help solve this problem.
0:27
You need to sign up for Treehouse in order to download course files.
Sign upYou need to sign up for Treehouse in order to set up Workspace
Sign up