SyncBool
- class thread_factory.concurrency.sync_types.sync_bool.SyncBool(*args, **kwargs)[source]
Bases:
ISyncThis class provides atomic access and mutation of the internal boolean value, along with logical and bitwise operations such as AND, OR, XOR, and NOT.
SyncBool does not inherit from bool or int to avoid unintentional coercion, but behaves identically for boolean logic and thread-safe use cases.
- get() bool[source]
Get the current boolean value in a thread-safe way.
- Returns:
The current state of the SyncBool.
- Return type:
bool