Kea: isc::util::MultiThreadingLock Struct Reference

| Kea 3.2.0-git

isc::util::MultiThreadingLock Struct Reference

RAII lock object to protect the code in the same scope with a mutex. More...

`#include <multi_threading_mgr.h>`

## Public Member Functions
| MultiThreadingLock (std::mutex &mutex)
| Constructor locks the mutex if multi-threading is enabled.

## Detailed Description

RAII lock object to protect the code in the same scope with a mutex.

Definition at line 349 of file multi_threading_mgr.h.

## Constructor & Destructor Documentation

## ◆ MultiThreadingLock()

isc::util::MultiThreadingLock::MultiThreadingLock | ( | std::mutex & | mutex | ) |

Constructor locks the mutex if multi-threading is enabled.

The lock is automatically unlocked in the default destructor.

Parameters

  mutex | the mutex to be locked

Definition at line 241 of file multi_threading_mgr.cc.

References isc::util::MultiThreadingMgr::instance().

Here is the call graph for this function:

The documentation for this struct was generated from the following files:

- multi_threading_mgr.h
- multi_threading_mgr.cc