A RAII helper which tries to exclusively latch the global_lach in constructor and unlatches it, if needed, during destruction, preventing any other threads from activity within lock_sys for it's entire scope, if owns_lock().
More...
#include <lock0guards.h>
A RAII helper which tries to exclusively latch the global_lach in constructor and unlatches it, if needed, during destruction, preventing any other threads from activity within lock_sys for it's entire scope, if owns_lock().
◆ Global_exclusive_try_latch()
locksys::Global_exclusive_try_latch::Global_exclusive_try_latch |
( |
ut::Location |
location | ) |
|
◆ ~Global_exclusive_try_latch()
locksys::Global_exclusive_try_latch::~Global_exclusive_try_latch |
( |
| ) |
|
◆ owns_lock()
bool locksys::Global_exclusive_try_latch::owns_lock |
( |
| ) |
const |
|
inlinenoexcept |
Checks if succeeded to latch the global_latch during construction.
- Returns
- true iff the current thread owns (through this instance) the exclusive global lock_sys latch
◆ m_owns_exclusive_global_latch
bool locksys::Global_exclusive_try_latch::m_owns_exclusive_global_latch |
|
private |
Did the constructor succeed to acquire exclusive global lock_sys latch?
The documentation for this class was generated from the following files: