On Sun, Jan 23, 2000 at 04:15:26AM -0500, [EMAIL PROTECTED] wrote:
> i have an idea we briefly covered a few weeks ago. i want a new
> attribute on all watchers called data (or something else) which is just
> used to hold whatever i want.

What is wrong with this:

  $watcher->{data} = ...; #?

> then i could subclass event.pm and not
> need to do this encapsulation stuff.
> 
> this still doesn't allow for autodestruction on leaving scope as you
> have class level structures holding refs to the watcher objects. if you
> returned a higher level object that contained the watcher info, then it
> might be possible to get DESTROY called as only the creator code will
> have a ref to this higher object. 

Yah, that's still a problem.

> i feel the user has to keep track of these higher level objects and not
> event.pm. there is no reason to offer these class level things unless
> they are requested. make them a subclass or sister/helper class and then
> we get the autodestruct feature. probably too hard to do now, but what
> do you think of it?

I'm not sure I follow your thinking.  What do you mean?

> does anyone use all_watchers or similar class level calls?

Again, I'm not sure what you're driving at.

-- 
"Never ascribe to malice that which can be explained by stupidity."
                            via, but not speaking for Deutsche Bank

Reply via email to