Hold/manage thread locks for arbitrary resource keys
Methods
|
|
__getitem__
__init__
attempt
locked
obtain
release
|
|
__getitem__
|
__getitem__ ( self, key )
|
|
__init__
|
__init__ ( self )
|
|
attempt
|
attempt ( self, key )
Nonblocking, nestable attempt to acquire; returns success flag
|
|
locked
|
locked ( self, key )
Is this key owned by the current thread?
|
|
obtain
|
obtain ( self, key )
Blocking, nestable wait to acquire; success unless error
|
|
release
|
release ( self, key )
Release one level of locking; key must be locked() when called
|
|