![]() |
Murl Engine API
Version 2025.1
|
The atomic integer class. More...
#include <murl_system_mutex.h>
The atomic integer class.
The atomic integer is a thread-safe integer. On modern platforms the operations are supported by intrinsic CPU commands without using a mutex.
Public Member Functions | |
| AtomicSInt32 (const SInt32 value) | |
| The constructor. More... | |
| SInt32 | operator++ () |
| Increment prefix operator. More... | |
| SInt32 | operator++ (int) |
| Increment suffix operator. More... | |
| SInt32 | operator-- () |
| Decrement prefix operator. More... | |
| SInt32 | operator-- (int) |
| Decrement suffix operator. More... | |
| SInt32 | ExchangeAndAdd (SInt32 valueToAdd) |
| Exchange and add a value. More... | |
| operator SInt32 () | |
| Conversion operator. More... | |
Public Member Functions inherited from Murl::NonCopyable | |
| NonCopyable ()=default | |
| The default constructor. | |
Protected Attributes | |
| SInt32 | mValue |
| The value store. | |
|
inlineexplicit |
The constructor.
| value | The initial value. |
| SInt32 Murl::System::AtomicSInt32::operator++ | ( | ) |
Increment prefix operator.
| SInt32 Murl::System::AtomicSInt32::operator++ | ( | int | ) |
Increment suffix operator.
| SInt32 Murl::System::AtomicSInt32::operator-- | ( | ) |
Decrement prefix operator.
| SInt32 Murl::System::AtomicSInt32::operator-- | ( | int | ) |
Decrement suffix operator.
Exchange and add a value.
| valueToAdd | The value to add. |
|
inline |
Conversion operator.