WebCFace 2.9.0
Web-based Communication Framework & Dashboard-like UI
Loading...
Searching...
No Matches
MutexProxy< T > Class Template Reference

RustのMutexのようにデータを保護するクラス More...

#include <webcface/common/internal/mutex.h>

Inheritance diagram for MutexProxy< T >:
[legend]

Public Member Functions

ScopedLock< MutexProxy, std::unique_lock< std::mutex > > lock ()
 
ScopedLock< const MutexProxy, std::unique_lock< std::mutex > > const_lock () const
 

Friends

template<typename Proxy , typename Lock >
class ScopedLock
 

Detailed Description

template<typename T>
class webcface::internal::MutexProxy< T >

RustのMutexのようにデータを保護するクラス

{
auto lock = data.lock();
lock->foo();
}
{
data.lock()->foo();
}
RustのMutexのようにデータを保護するクラス
Definition mutex.h:49
ScopedLock< MutexProxy, std::unique_lock< std::mutex > > lock()
Definition mutex.h:58

Member Function Documentation

◆ const_lock()

template<typename T >
ScopedLock< const MutexProxy, std::unique_lock< std::mutex > > const_lock ( ) const
inline

◆ lock()

template<typename T >
ScopedLock< MutexProxy, std::unique_lock< std::mutex > > lock ( )
inline

Friends And Related Symbol Documentation

◆ ScopedLock

template<typename T >
template<typename Proxy , typename Lock >
friend class ScopedLock
friend

The documentation for this class was generated from the following file: