Fabcoin Core  0.16.2
P2P Digital Currency
Public Member Functions | Private Member Functions | Private Attributes | List of all members
CMutexLock< Mutex > Class Template Reference

Wrapper around boost::unique_lock<Mutex> More...

#include <sync.h>

Public Member Functions

 CMutexLock (Mutex &mutexIn, const char *pszName, const char *pszFile, int nLine, bool fTry=false) EXCLUSIVE_LOCK_FUNCTION(mutexIn)
 
 CMutexLock (Mutex *pmutexIn, const char *pszName, const char *pszFile, int nLine, bool fTry=false) EXCLUSIVE_LOCK_FUNCTION(pmutexIn)
 
 ~CMutexLock () UNLOCK_FUNCTION()
 
 operator bool ()
 

Private Member Functions

void Enter (const char *pszName, const char *pszFile, int nLine)
 
bool TryEnter (const char *pszName, const char *pszFile, int nLine)
 

Private Attributes

boost::unique_lock< Mutex > lock
 

Detailed Description

template<typename Mutex>
class CMutexLock< Mutex >

Wrapper around boost::unique_lock<Mutex>

Definition at line 111 of file sync.h.

Constructor & Destructor Documentation

template<typename Mutex >
CMutexLock< Mutex >::CMutexLock ( Mutex &  mutexIn,
const char *  pszName,
const char *  pszFile,
int  nLine,
bool  fTry = false 
)
inline

Definition at line 139 of file sync.h.

template<typename Mutex >
CMutexLock< Mutex >::CMutexLock ( Mutex *  pmutexIn,
const char *  pszName,
const char *  pszFile,
int  nLine,
bool  fTry = false 
)
inline

Definition at line 147 of file sync.h.

template<typename Mutex >
CMutexLock< Mutex >::~CMutexLock ( )
inline

Definition at line 158 of file sync.h.

Member Function Documentation

template<typename Mutex >
void CMutexLock< Mutex >::Enter ( const char *  pszName,
const char *  pszFile,
int  nLine 
)
inlineprivate

Definition at line 116 of file sync.h.

template<typename Mutex >
CMutexLock< Mutex >::operator bool ( )
inline

Definition at line 164 of file sync.h.

template<typename Mutex >
bool CMutexLock< Mutex >::TryEnter ( const char *  pszName,
const char *  pszFile,
int  nLine 
)
inlineprivate

Definition at line 129 of file sync.h.

Member Data Documentation

template<typename Mutex >
boost::unique_lock<Mutex> CMutexLock< Mutex >::lock
private

Definition at line 114 of file sync.h.


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