SharedMutex

class SharedMutex[U]

A mutex-protected data

Members defined in SharedMutex (1 member)

lock

Acquire access to the protected data.

Methods

lock() syside.WriteLocked[syside.U]

Acquire access to the protected data.

This returns a context manager that ensures the lock is released at the end of the scope:

with mutex.lock() as data:
    ...
Used in