This is the mail archive of the
insight@sources.redhat.com
mailing list for the Insight project.
Re: [RFA] New Event Model Prototype
- To: Jim Ingham <jingham at apple dot com>
- Subject: Re: [RFA] New Event Model Prototype
- From: Fernando Nasser <fnasser at cygnus dot com>
- Date: Tue, 17 Apr 2001 10:28:06 -0400
- CC: Keith Seitz <keiths at cygnus dot com>, Fernando Nasser <fnasser at redhat dot com>, Insight Maling List <insight at sources dot redhat dot com>
- Organization: Red Hat , Inc. - Toronto
- References: <200104162048.NAA19033@scv2.apple.com>
Jim Ingham wrote:
>
> Keith,
>
> I have another question about this. How were you planning to pass all
> the details about the event? Will there be methods in the GDBEvent
> class to get out the event data? It almost seems like you want to have:
>
> GDBEvent
> |
> ------> BreakpointEvent
> |
> ------> ExecutionStateEvent
>
> and ALL you ever pass to the dispatch method is an event of the
> appropriate class. This would really simplify the code in the event
> listeners, and we wouldn't get into the situation of the current code,
> where the event handlers have to know the order of the parameters in the
> hook call, which is very fragile.
>
I agree with your concerns that the fixed position list of arguments (different for each event) is a drag.
Being able to do like Java exception and inherit the (classes corresponding to) the events you plan to use would be nice.
But how do we circumvent the itcl limitation that you cannot use multiple inheritance if the classes you are inheriting from have common ancestors? Maybe this restriction has already been lifted, I am only as up-to-date as the itcl book...
Cheers,
Fernando
--
Fernando Nasser
Red Hat - Toronto E-Mail: fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario M4P 2C9