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: Keith Seitz <keiths at cygnus dot com>
- Date: Wed, 18 Apr 2001 11:46:26 -0700 (PDT)
- cc: Fernando Nasser <fnasser at redhat dot com>, Insight Maling List <insight at sources dot redhat dot com>
On Wed, 18 Apr 2001, Jim Ingham wrote:
> I think that the second type is more likely to be what you want.
I came to the same conclusion. (So I'm not losing my mind.)
> > class MyObject {
> > inherit GdbEventListener
> >
> > public method foo {fooEvent} {
> > puts "varA = [$fooEvent cget -varA]"
> > puts "varB = [$fooEvent cget -varB]"
> > puts "varC = [$fooEvent cget -varC]"
> > }
> > }
I have decided NOT to go this route. Instead, I'm going to use arrays.
When an event is constructed, it builds an array of all data pertinent to
itself. Then we ask for this data:
proc handle_foo_event {foo_event} {
array set fooData [$foo_event get]
puts "varA = $fooData(varA)"
puts "varB = $fooData(varB)"
}
Ugh. I thought breakpoints would be easy. Guess again. Can anyone guess
the difference between clear_command and delete_command (other than
argument)? I'll give you a hint: using clear_command is EVIL.
Keith