From: Mike C. Fletcher <mcfletch@ro...> - 2004-04-07 16:11:41
Schoenborn, Oliver wrote:
>the user changes something in the view, say data in a text control box, the
>view commits the data to a leaf in the hierarchy of the document and
>generates a message for '(doc, changed, fromView)' topic, in case 'someone'
>is interested in the fact that document has been changed. Similarly, the
>import reader generates a message for topic '(doc, changed, fromImport)'
>when it imports some external data into some leaves of an existing document.
Okay, so the approach I outlined should work with PyDispatcher. I'll
put it on the (seemingly infinitely long) list of things to play with
some day. Basically it would look something like this:
def sendHier( signal=Any, sender=Anonymous, *arguments, **named ):
if isinstance( signal, HierMessage ):
responses = 
responses.extend(sendExact( signal, sender, *arguments, **named ))
signal = signal[:-1]
responses.extend( sendExact( Any, sender, *arguments, **named ))
return send( signal, sender, *arguments, **named )
I'd have to take some time to write up test cases and check that the
last sendExact would do the proper thing, but I think that basically
gives all the features you've described.
Mike C. Fletcher
Designer, VR Plumber, Coder