Electroneum
epee::shared_critical_section Class Reference

#include <winobj.h>

Public Member Functions

 shared_critical_section ()
 
 ~shared_critical_section ()
 
bool lock_shared ()
 
bool unlock_shared ()
 
bool lock_exclusive ()
 
bool unlock_exclusive ()
 

Detailed Description

Definition at line 95 of file winobj.h.

Constructor & Destructor Documentation

◆ shared_critical_section()

epee::shared_critical_section::shared_critical_section ( )
inline

Definition at line 98 of file winobj.h.

99  {
100  ::InitializeSRWLock(&m_srw_lock);
101  }

◆ ~shared_critical_section()

epee::shared_critical_section::~shared_critical_section ( )
inline

Definition at line 102 of file winobj.h.

103  {}

Member Function Documentation

◆ lock_exclusive()

bool epee::shared_critical_section::lock_exclusive ( )
inline

Definition at line 115 of file winobj.h.

116  {
117  ::AcquireSRWLockExclusive(&m_srw_lock);
118  return true;
119  }
Here is the caller graph for this function:

◆ lock_shared()

bool epee::shared_critical_section::lock_shared ( )
inline

Definition at line 105 of file winobj.h.

106  {
107  AcquireSRWLockShared(&m_srw_lock);
108  return true;
109  }
Here is the caller graph for this function:

◆ unlock_exclusive()

bool epee::shared_critical_section::unlock_exclusive ( )
inline

Definition at line 120 of file winobj.h.

121  {
122  ::ReleaseSRWLockExclusive(&m_srw_lock);
123  return true;
124  }
Here is the caller graph for this function:

◆ unlock_shared()

bool epee::shared_critical_section::unlock_shared ( )
inline

Definition at line 110 of file winobj.h.

111  {
112  ReleaseSRWLockShared(&m_srw_lock);
113  return true;
114  }
Here is the caller graph for this function:

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