Heads up! To view this whole video, sign in with your Courses Plus account or enroll in your free 7-day trial. Sign In Enroll
Well done!
You have completed Observer Design Pattern using Java!
You have completed Observer Design Pattern using Java!
Preview
The casting and not being able to write your own Observable class properly has led to developers looking outside of the provided implementation. Turns out it's pretty straightforward.
Learn more
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
most likely, you'll have
the temptation to do it yourself.
0:00
Okay.
So,
0:02
I've got a pretty straightforward
example that we can use to create that,
0:03
hey, I should use that observer pattern,
feeling.
0:07
Now, the idea is that we have
a universal remote control.
0:10
One of these that controls
all sorts of devices.
0:13
I think if we just focus here on the power
button, we can get there pretty quickly.
0:15
When I press the power button, I want all
the devices on this control to turn on.
0:19
Let's take a look at some proof of
concept code for remote control.
0:23
So, let's open up the universal
remote module right here, right?
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