Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: Implementing an event-driven object model in Perl

by GrandFather (Saint)
on Jun 23, 2006 at 19:09 UTC ( [id://557296]=note: print w/replies, xml ) Need Help??


in reply to Implementing an event-driven object model in Perl

You may wish to consider whether individual objects notify all other objects, or a selected list of objects, or objects of a specific class.

Something to watch for in the "notify all" scenario is that the notification doesn't trigger another notification of the same type by the original object - that way leads to great activity with no forward motion. You may wish to tag notifications with a sender ID as a partial solution to that problem, although if another object responds to the notification by doing some work that notifies the original object (perhaps indirectly!), then you still have a problem.


DWIM is Perl's answer to Gödel
  • Comment on Re: Implementing an event-driven object model in Perl

Replies are listed 'Best First'.
Re^2: Implementing an event-driven object model in Perl
by jkva (Chaplain) on Jun 23, 2006 at 19:12 UTC
    Yes, of course. Good point. I guess certain objects would have defined to which events they should have to respond, and by what, of course. We don't want theoretically infinite notification. Also perhaps rule out any "tag-back" (as in playing tag, no tagging of $tagger).

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://557296]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (None)
    As of 2024-04-25 00:00 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      No recent polls found