It's not a secret anymore!*
The moose likes Beginning Java and the fly likes What is Observer and Observable? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "What is Observer and Observable?" Watch "What is Observer and Observable?" New topic
Author

What is Observer and Observable?

Hemant Agarwal
Ranch Hand

Joined: Nov 21, 2005
Posts: 138
What is Observer and Observable? What is their use?
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 11161
    
  16

They're part of the Observer pattern. you have one object that notifies a bunch of others when needed. many "observers" may register with an "observable", and all may un-register.

Check out the Head First Design Patterns book, or google "design patterns observer" and you'll find tons of into...


There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41124
    
  45
There's a good IBM Developerworks tutorial on event delivery techniques, which you can find here. It covers Observer/Observable, JavaBean event techniques and more.
[ January 01, 2006: Message edited by: Ulf Dittmer ]

Ping & DNS - my free Android networking tools app
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: What is Observer and Observable?
 
Similar Threads
a doubt regarding course
Observer and Observable
How to write my own Event ( & Listener for it)??
What are Observer and Observable? How it is usfull?
Frame