|
libqi-api
release-2.5.3-2016-11-18
|
#include <atomic.hpp>
Public Member Functions | |
| Atomic () | |
| Atomic (T value) | |
| Atomic (const Atomic &other) | |
| T | operator++ () |
| Atomic pre-increment of the value. More... | |
| T | operator-- () |
| Atomic pre-decrement of the value. More... | |
| T | operator++ (int) |
| Atomic post-increment of the value. More... | |
| T | operator-- (int) |
| Atomic post-decrement of the value. More... | |
| Atomic< T > & | operator= (T value) |
| Atomic< T > & | operator= (const Atomic< T > &value) |
| bool | setIfEquals (T testValue, T setValue) |
| T | swap (T value) |
| T | operator* () const |
| T | load () const |
Public Attributes | |
| std::atomic< T > | _value |
Atomic operations on integrals.
This class allows to do operations on an integral value from multiple threads, with the guarantee that each operation will not lead to a data race.
Definition at line 143 of file atomic.hpp.
|
inline |
Definition at line 149 of file atomic.hpp.
|
inline |
Atomic constructor setting value to its parameter.
| value | The default value of the atomic. |
Definition at line 155 of file atomic.hpp.
|
inline |
Definition at line 161 of file atomic.hpp.
|
inline |
Definition at line 208 of file atomic.hpp.
|
inline |
Return the contained valu Deprecated since 2.5.0
Definition at line 205 of file atomic.hpp.
|
inline |
Atomic pre-increment of the value.
Definition at line 166 of file atomic.hpp.
|
inline |
Atomic post-increment of the value.
Definition at line 173 of file atomic.hpp.
|
inline |
Atomic pre-decrement of the value.
Definition at line 169 of file atomic.hpp.
|
inline |
Atomic post-decrement of the value.
Definition at line 178 of file atomic.hpp.
|
inline |
Definition at line 183 of file atomic.hpp.
|
inline |
Definition at line 185 of file atomic.hpp.
|
inline |
If value is testValue, replace it with setValue.
Definition at line 191 of file atomic.hpp.
|
inline |
Swap the atomic value with value.
Definition at line 197 of file atomic.hpp.
| std::atomic<T> qi::Atomic< T >::_value |
Definition at line 145 of file atomic.hpp.