JUCE
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | Static Protected Member Functions | List of all members
AtomicBase< Type > Class Template Reference
Inheritance diagram for AtomicBase< Type >:

Public Types

typedef AtomicHelpers::DiffTypeHelper< Type >::Type DiffType
 

Public Member Functions

 AtomicBase () noexcept
 
 AtomicBase (const Type v) noexcept
 
 AtomicBase (const AtomicBase &other) noexcept
 
Type get () const noexcept
 
AtomicBaseoperator= (const AtomicBase< Type > &other) noexcept
 
AtomicBaseoperator= (const Type newValue) noexcept
 
void set (Type newValue) noexcept
 
Type exchange (Type) noexcept
 
bool compareAndSetBool (Type, Type) noexcept
 
Type compareAndSetValue (Type, Type) noexcept
 

Static Public Member Functions

static void memoryBarrier () noexcept
 

Public Attributes

volatile Type value
 The raw value that this class operates on. More...
 

Protected Member Functions

Type operator++ (int)
 
Type operator-- (int)
 
template<typename ValueType >
ValueType negateValue (ValueType n) noexcept
 This templated negate function will negate pointers as well as integers. More...
 
template<typename PointerType >
PointerType * negateValue (PointerType *n) noexcept
 This templated negate function will negate pointers as well as integers. More...
 

Static Protected Member Functions

template<typename Dest , typename Source >
static Dest castTo (Source value) noexcept
 
static Type castFrom32Bit (int32 value) noexcept
 
static Type castFrom64Bit (int64 value) noexcept
 
static int32 castTo32Bit (Type value) noexcept
 
static int64 castTo64Bit (Type value) noexcept
 

Member Typedef Documentation

◆ DiffType

template<typename Type>
typedef AtomicHelpers::DiffTypeHelper<Type>::Type AtomicBase< Type >::DiffType

Constructor & Destructor Documentation

◆ AtomicBase() [1/3]

template<typename Type>
AtomicBase< Type >::AtomicBase ( )
noexcept

◆ AtomicBase() [2/3]

template<typename Type>
AtomicBase< Type >::AtomicBase ( const Type  v)
explicitnoexcept

◆ AtomicBase() [3/3]

template<typename Type>
AtomicBase< Type >::AtomicBase ( const AtomicBase< Type > &  other)
noexcept

Member Function Documentation

◆ operator=() [1/2]

template<typename Type>
AtomicBase& AtomicBase< Type >::operator= ( const AtomicBase< Type > &  other)
noexcept

◆ operator=() [2/2]

template<typename Type>
AtomicBase& AtomicBase< Type >::operator= ( const Type  newValue)
noexcept

◆ set()

template<typename Type>
void AtomicBase< Type >::set ( Type  newValue)
noexcept

◆ castTo()

template<typename Type>
template<typename Dest , typename Source >
static Dest AtomicBase< Type >::castTo ( Source  value)
staticprotectednoexcept

◆ castFrom32Bit()

template<typename Type>
static Type AtomicBase< Type >::castFrom32Bit ( int32  value)
staticprotectednoexcept

◆ castFrom64Bit()

template<typename Type>
static Type AtomicBase< Type >::castFrom64Bit ( int64  value)
staticprotectednoexcept

◆ castTo32Bit()

template<typename Type>
static int32 AtomicBase< Type >::castTo32Bit ( Type  value)
staticprotectednoexcept

◆ castTo64Bit()

template<typename Type>
static int64 AtomicBase< Type >::castTo64Bit ( Type  value)
staticprotectednoexcept

◆ operator++()

template<typename Type>
Type AtomicBase< Type >::operator++ ( int  )
protected

◆ operator--()

template<typename Type>
Type AtomicBase< Type >::operator-- ( int  )
protected

◆ negateValue() [1/2]

template<typename Type>
template<typename ValueType >
ValueType AtomicBase< Type >::negateValue ( ValueType  n)
protectednoexcept

This templated negate function will negate pointers as well as integers.

◆ negateValue() [2/2]

template<typename Type>
template<typename PointerType >
PointerType* AtomicBase< Type >::negateValue ( PointerType *  n)
protectednoexcept

This templated negate function will negate pointers as well as integers.

Member Data Documentation

◆ value

template<typename Type>
volatile Type AtomicBase< Type >::value

The raw value that this class operates on.

This is exposed publicly in case you need to manipulate it directly for performance reasons.


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