Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
chainbase::read_write_mutex_manager Class Reference

#include <chainbase.hpp>

Public Member Functions

 read_write_mutex_manager ()
 
 ~read_write_mutex_manager ()
 
void next_lock ()
 
read_write_mutexcurrent_lock ()
 
uint32_t current_lock_num ()
 

Detailed Description

Definition at line 217 of file chainbase.hpp.

Constructor & Destructor Documentation

◆ read_write_mutex_manager()

chainbase::read_write_mutex_manager::read_write_mutex_manager ( )
inline

Definition at line 220 of file chainbase.hpp.

221 {
222 _current_lock = 0;
223 }

◆ ~read_write_mutex_manager()

chainbase::read_write_mutex_manager::~read_write_mutex_manager ( )
inline

Definition at line 225 of file chainbase.hpp.

225{}

Member Function Documentation

◆ current_lock()

read_write_mutex & chainbase::read_write_mutex_manager::current_lock ( )
inline

Definition at line 233 of file chainbase.hpp.

234 {
235 return _locks[ _current_lock % CHAINBASE_NUM_RW_LOCKS ];
236 }
#define CHAINBASE_NUM_RW_LOCKS
Definition chainbase.hpp:37

◆ current_lock_num()

uint32_t chainbase::read_write_mutex_manager::current_lock_num ( )
inline

Definition at line 238 of file chainbase.hpp.

239 {
240 return _current_lock;
241 }

◆ next_lock()

void chainbase::read_write_mutex_manager::next_lock ( )
inline

Definition at line 227 of file chainbase.hpp.

228 {
229 _current_lock++;
230 new( &_locks[ _current_lock % CHAINBASE_NUM_RW_LOCKS ] ) read_write_mutex();
231 }
boost::interprocess::interprocess_sharable_mutex read_write_mutex
Definition chainbase.hpp:63

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