How are Observer and Observable used?
Answers were Sorted based on User's Feedback
Answer / nimisha
Objects that subclass the Observable class maintain a list
of observers. When an Observable object is updated it
invokes the update() method of each of its observers to
notify the observers that it has changed state. The
Observer interface is implemented by objects that observe
Observable objects.
| Is This Answer Correct ? | 2 Yes | 1 No |
Answer / guest
Objects that subclass the Observable class maintain a list
of observers. When an Observable object is updated it
invokes the update() method of each of its observers to
notify the observers that it has changed state. The
Observer interface is implemented by objects that observe
Observable objects.
| Is This Answer Correct ? | 2 Yes | 1 No |
Answer / supriya
Subclass of Observable class maintain a list of observers.
Whenever an Observable object is updated, it invokes the
update() method of each of its observers to notify the
observers that it has a changed state.
An observer is any object that implements the interface
Observer.
| Is This Answer Correct ? | 2 Yes | 1 No |
What is the differenc between Enemuration interface and iterator interface according to accessing?
Can we use catch statement for checked exceptions?
In how many ways we can do exception handling in java?
what release of java technology are currently available what do they contain?
difference between arraylist and linkedlist otherthan performance
What is a method in programming?
What is meant by interface?
Is java a prime method?
Explain different ways of creating a thread?
What is runtime polymorphism or dynamic method dispatch?
Java violates few objected oriented concepts. Can you explain in what way?
Can one thread block the other thread?