scistag.common.mt.stag_lock.StagLock¶
- class StagLock(thread_lock=True)[source]¶
Bases:
objectReplacement for the standard multithreading. Can be configured for different use cases. Behaves like a standard RLock by default.
Usage:
with my_lock() as lock:...- Parameters
thread_lock – Defines if a thread lock shall be used
Methods
Acquires this lock and prevents other users from accessing data it protects.
Releases the lock
Attributes
__dict____doc____module____weakref__list of weak references to the object (if defined)