foobar2000 SDK  2015-08-03
Public Member Functions | Private Member Functions | Private Attributes
CSRWorCS

#include <WTL-PP.h>

Public Member Functions

 CSRWorCS ()
 
 ~CSRWorCS ()
 
void EnterExclusive ()
 
void EnterShared ()
 
void LeaveExclusive ()
 
void LeaveShared ()
 

Private Member Functions

 CSRWorCS (const CSRWorCS &)
 
void operator= (const CSRWorCS &)
 

Private Attributes

CRITICAL_SECTION cs
 
CSRWlock srw
 

Detailed Description

Definition at line 305 of file WTL-PP.h.

Constructor & Destructor Documentation

CSRWorCS::CSRWorCS ( )
inline

Definition at line 307 of file WTL-PP.h.

307  : cs() {
309  }
CSRWlock srw
Definition: WTL-PP.h:333
CRITICAL_SECTION cs
Definition: WTL-PP.h:334
void InitializeCriticalSection(LPCRITICAL_SECTION lpCriticalSection)
Definition: pp-winapi.h:24
bool HaveAPI()
Definition: WTL-PP.h:266
CSRWorCS::~CSRWorCS ( )
inline

Definition at line 310 of file WTL-PP.h.

310  {
311  if (!srw.HaveAPI()) DeleteCriticalSection(& cs );
312  }
CSRWlock srw
Definition: WTL-PP.h:333
CRITICAL_SECTION cs
Definition: WTL-PP.h:334
bool HaveAPI()
Definition: WTL-PP.h:266
CSRWorCS::CSRWorCS ( const CSRWorCS )
private

Member Function Documentation

void CSRWorCS::EnterExclusive ( )
inline

Definition at line 317 of file WTL-PP.h.

317  {
318  if (srw.HaveAPI()) srw.EnterExclusive();
319  else EnterCriticalSection(&cs);
320  }
CSRWlock srw
Definition: WTL-PP.h:333
CRITICAL_SECTION cs
Definition: WTL-PP.h:334
void EnterExclusive()
Definition: WTL-PP.h:277
bool HaveAPI()
Definition: WTL-PP.h:266
void CSRWorCS::EnterShared ( )
inline

Definition at line 313 of file WTL-PP.h.

313  {
314  if (srw.HaveAPI()) srw.EnterShared();
315  else EnterCriticalSection(&cs);
316  }
void EnterShared()
Definition: WTL-PP.h:274
CSRWlock srw
Definition: WTL-PP.h:333
CRITICAL_SECTION cs
Definition: WTL-PP.h:334
bool HaveAPI()
Definition: WTL-PP.h:266
void CSRWorCS::LeaveExclusive ( )
inline

Definition at line 325 of file WTL-PP.h.

325  {
326  if (srw.HaveAPI()) srw.LeaveExclusive();
327  else LeaveCriticalSection(&cs);
328  }
CSRWlock srw
Definition: WTL-PP.h:333
CRITICAL_SECTION cs
Definition: WTL-PP.h:334
bool HaveAPI()
Definition: WTL-PP.h:266
void LeaveExclusive()
Definition: WTL-PP.h:283
void CSRWorCS::LeaveShared ( )
inline

Definition at line 321 of file WTL-PP.h.

321  {
322  if (srw.HaveAPI()) srw.LeaveShared();
323  else LeaveCriticalSection(&cs);
324  }
CSRWlock srw
Definition: WTL-PP.h:333
CRITICAL_SECTION cs
Definition: WTL-PP.h:334
bool HaveAPI()
Definition: WTL-PP.h:266
void LeaveShared()
Definition: WTL-PP.h:280
void CSRWorCS::operator= ( const CSRWorCS )
private

Field Documentation

CRITICAL_SECTION CSRWorCS::cs
private

Definition at line 334 of file WTL-PP.h.

CSRWlock CSRWorCS::srw
private

Definition at line 333 of file WTL-PP.h.


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