|
TracktionEngine
|
Wraps an atomic with an interface compatible with var so it can be used within CachedValues in a thread safe way. More...
#include <tracktion_AtomicWrapper.h>
Public Member Functions | |
| AtomicWrapper ()=default | |
| Constructor. | |
| template<typename OtherType > | |
| AtomicWrapper (const OtherType &other) | |
| Constructs a copy of another wrapper type. | |
| AtomicWrapper (const AtomicWrapper &other) | |
| Constructs a copy of another AtomicWrapper. | |
| AtomicWrapper & | operator= (const AtomicWrapper &other) noexcept |
| Assigns another AtomicWrapper's underlying value to this one atomically. | |
| AtomicWrapper & | operator= (const Type &other) noexcept |
| Assigns a value to this one atomically. | |
| bool | operator== (const AtomicWrapper &other) const noexcept |
| Compares the underlaying value of another wrapper with this one. | |
| bool | operator!= (const AtomicWrapper &other) const noexcept |
| Compares the underlaying value of another wrapper with this one. | |
| bool | operator== (const Type &other) const noexcept |
| Compares another value with this one. | |
| bool | operator!= (const Type &other) const noexcept |
| Compares another value with this one. | |
| operator juce::var () const noexcept | |
| Returns the underlying value as a var. | |
| operator Type () const noexcept | |
| Returns the underlying value. | |
Wraps an atomic with an interface compatible with var so it can be used within CachedValues in a thread safe way.
Optionally supply a Constrainer to limit the value in some way.
|
default |
Constructor.
| tracktion::engine::AtomicWrapper< Type, Constrainer, MemoryOrderLoad, MemoryOrderStore >::AtomicWrapper | ( | const OtherType & | other | ) |
Constructs a copy of another wrapper type.
| tracktion::engine::AtomicWrapper< Type, Constrainer, MemoryOrderLoad, MemoryOrderStore >::AtomicWrapper | ( | const AtomicWrapper< Type, Constrainer, MemoryOrderLoad, MemoryOrderStore > & | other | ) |
Constructs a copy of another AtomicWrapper.
|
noexcept |
Assigns another AtomicWrapper's underlying value to this one atomically.
|
noexcept |
Assigns a value to this one atomically.
|
noexcept |
Compares the underlaying value of another wrapper with this one.
|
noexcept |
Compares the underlaying value of another wrapper with this one.
|
noexcept |
Compares another value with this one.
|
noexcept |
Compares another value with this one.
|
noexcept |
Returns the underlying value as a var.
|
noexcept |
Returns the underlying value.