#include <OnixS/FIXEngine/Threading/Mutex.h>
Public Member Functions | |
| Mutex () | |
| ~Mutex () | |
| void | acquire () |
| bool | tryAcquire () |
| void | release () |
Friends | |
| friend | ONIXS_FIXENGINE_API_DECL (class, Condition) |
Protects a resources from the simultaneous access by multiple threads.
Only one thread at a time can own the instance of this class.
This implementation is optimized for locking threads that are in the same process.
| Mutex | ( | ) |
Initializes the instance.
| ~Mutex | ( | ) |
Destructs the instance.
| void acquire | ( | ) |
Acquires the lock ownership. If the Mutex already occupied by the other thread, blocks the current thread and waits until it will be released by the owner.
| void release | ( | ) |
Releases the ownership (lock) and unblocks one of waiting threads.
| bool tryAcquire | ( | ) |
|
friend |