PTLib
Version 2.14.3
|
This class implements an atomic "test and set" boolean. More...
#include <critsec.h>
Public Member Functions | |
PAtomicBoolean (bool value=false) | |
Create a PAtomicBoolean with the specified initial value. More... | |
__inline | operator bool () const |
__inline PAtomicBoolean & | operator= (bool value) |
Assign a value to the atomic boolean. More... | |
__inline bool | operator! () const |
Test if atomic integer has a zero value. More... | |
bool | TestAndSet (bool value) |
Test Set the value of the atomic boolean. More... | |
Friends | |
__inline ostream & | operator<< (ostream &strm, const PAtomicBoolean &b) |
Additional Inherited Members | |
![]() | |
typedef int | IntegerType |
![]() | |
~PAtomicBase () | |
Destroy the atomic integer. More... | |
PAtomicBase (IntegerType value) | |
This class implements an atomic "test and set" boolean.
|
inlineexplicit |
Create a PAtomicBoolean with the specified initial value.
value | initial value |
|
inline |
References PAtomicBase::m_value.
|
inline |
Test if atomic integer has a zero value.
References PAtomicBase::m_value.
|
inline |
Assign a value to the atomic boolean.
References PAtomicBase::m_value.
__inline bool PAtomicBoolean::TestAndSet | ( | bool | value | ) |
Test Set the value of the atomic boolean.
the previous value.
value | value to set |
References PAtomicBase::m_value.
|
friend |