Answer Posted / niranjanravi
There are 2 ways to handle the events.
1.EventInheritance model
2.EventDelegation model.
EVentDelegation model has 2 advantages over
EventInheritance model.
First it enables event handling by objects other than the
ones that generates the events.It allows a clean separation
between components design and its use.
Secondly it performs much better in applications where many
events are generated. This performance improvement is due
to the fact that EventDelegation model doesn't need to
repeatable habndle unhandled events as is the case of
EventInheritance
Is This Answer Correct ? | 2 Yes | 6 No |
Post New Answer View All Answers
How do you achieve polymorphism in java?
What is the difference between static and global variables and also define what are volatile variables?
What does exclamation mean in java?
What is currentthread()?
What is java virtual machine and how it is considered in context of java’s platform independent feature?
Can a class be declared as protected?
Can we serialize static variables in java?
List out five keywords related to exception handling ?
Define interface in java?
What is variable argument in java?
When will we prefer to use set and list in java and why?
what is thread? What are the high-level thread states? Or what are the states associated in the thread? : Java thread
What do you mean by multithreaded program?
How to sort an array in java without using sort method?
What is this () in java?