|
|
| P is for Practical | |
| PerlMonks |
Re^3: design suggestions for object integration wantedby GrandFather (Cardinal) |
| on Sep 20, 2006 at 19:43 UTC ( #573979=note: print w/ replies, xml ) | Need Help?? |
|
I've not thought it through in detail, but I envisage a forward_message method on your CDAT object that disallows recursive calls with the same message object. Consider:
Note that both CDAT and the message are objects and retain state. Messages may trigger the immediate processing of more messages, but reprocessing "identical" messages is prohibited. The id_hash determines what is considered to be "identical". The idea of dynamic dispatch appeals to me for this application so I'd likely have a chunk of code in the target objects's message handlers that looks like:
DWIM is Perl's answer to Gödel
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||