A MutexTryLock tries to lock an Mutex object on construction and if successful, unlocks it on destruction of the MutexTryLock. Use isSuccessful() to check whether the attempt succeeded.
More...
#include <MutexLock.hpp>
A MutexTryLock tries to lock an Mutex object on construction and if successful, unlocks it on destruction of the MutexTryLock. Use isSuccessful() to check whether the attempt succeeded.
Definition at line 87 of file MutexLock.hpp.
Try to lock a Mutex object
- Parameters
-
mutex | The Mutex which should be attempted to be locked |
Definition at line 97 of file MutexLock.hpp.
RTT::os::MutexTryLock::~MutexTryLock |
( |
| ) |
|
|
inline |
Releases, if any, a lock on the previously try-locked Mutex
Definition at line 115 of file MutexLock.hpp.
RTT::os::MutexTryLock::MutexTryLock |
( |
| ) |
|
|
inlineprotected |
bool RTT::os::MutexTryLock::isSuccessful |
( |
| ) |
|
|
inline |
Return if the locking of the Mutex was succesfull
- Returns
- true when the Mutex is locked
Definition at line 107 of file MutexLock.hpp.
bool RTT::os::MutexTryLock::successful |
|
private |
The documentation for this class was generated from the following file: