[Twisted-Python] Is it a good/recommended practice to pass Instance Method into reactor.callFromThread()/callInThread()?
hellojianwu at gmail.com
Tue Jan 23 02:16:50 EST 2007
Hi Twisted Guru,
I'm new to Twisted, I am just experimenting Twisted 2.5 with Python 2.5.
It seems that I can pass either a python function or a python object
to reactor.callInThread() for blocking operation and
reactor.callFromThread() in main
I just want to see whether it is a good/recommended practice to pass
into reactor.callFromThread()/callInThread(), which implies that the
context information stored in the python object instance is available
when the method
is invoked, so I don't have to pass all the context info as
parameters. Do I miss anything
Any suggestion or tip is really appreciated.
Thanks a lot for your help!
More information about the Twisted-Python