Thread processing
Paul Moore
gustav at morpheus.demon.co.uk
Thu Mar 6 15:35:10 EST 2003
"Anders J. Munch" <andersjm at dancontrol.dk> writes:
> "Paul Moore" <gustav at morpheus.demon.co.uk> wrote:
>>
>> I can use a Queue to have the threads notify when they have finished,
>> but that means rewriting the thread procedures to do the notification,
>> which isn't really what I want.
>
> Don't rewrite. Wrap.
>
[...]
>
> Write all the logic for collaboration with the main thread just once
> in wrapped_threadprocedure, and you can keep the individual thread
> procedures simple and framework agnostic.
Doh. This just proves I was getting so wound up over this that I
wasn't thinking straight. I really should have known how to do
something like this.
Thanks for pointing out the obvious...
Paul.
--
This signature intentionally left blank
More information about the Python-list
mailing list