Hi,
I wrote simple implementation of the "synchroniz ed" methods (a-la Java),
could you please check if it is OK:
def synchronized(me thod):
"""
Guards method execution, similar to Java's synchronized keyword.
The class which uses this method, is required to have a
L{threading.Loc k} primitive as an attribute named 'lock'.
"""
def wrapper(self, *args):
self.lock.acqui re()
try:
return method(self, *args)
finally:
self.lock.relea se()
return wrapper
....I'm no big thread expert
tia.
.... The problem is not that there are problems. The problem is expecting
otherwise and thinking that having problems is a problem.
-- Theodore Rubin
Comment