A Brief insight into The Java 1.0 Event Model
The Java 1.0 Event Model was
based on Inheritance. It was thus called the Java 1.0 Inheritance
Event Model. A program that needed to process GUI events was
required to subclass GUI components and override either the
action() or handleEvent() methods.
Returning "true" from one of these subclassed methods
consumed the event so the event was not propagated furthur up the
heirarchy. Otherwise the event was propagated sequentially up the
GUI hierarchy until it was either consumed or the root of the
hierarchy was reached. Programs thus had two ways to structure
their event-handling code:
| Either individual components could be subclassed to specifically handle their target events or, | |
| All events for an entire hierarchy could be handled by a particular container. |
Thus there was no filtering of
events. Events were always delivered to components regardless of
whether the components actually required or handled them or not.
This was considered a severe performance problem.
This site was developed and is maintained by Gopalan Suresh Raj This page has been visited |
||
Last Updated :May13,'98 |
||
Copyright (c) 1997-98, Gopalan Suresh Raj - All rights reserved. Terms of use. |
All products and companies mentioned at this site,are trademarks of their respective owners. |