Nebula
Loading...
Searching...
No Matches
Threading::Interlocked::AtomicCounter64 Struct Reference

#include <interlocked.h>

Detailed Description

Atomic value only used to decrement, increment and read a 64 bit value.

Public Member Functions

 AtomicCounter64 ()
 AtomicCounter64 (int64 initial)
 Constructor.
bool operator== (int64 value) const
 Equals.
bool operator!= (int64 value) const
 Not-equals.
bool operator> (int64 value) const
 Greater.
bool operator>= (int64 value) const
 Greater or equal.
bool operator< (int64 value) const
 Less.
bool operator<= (int64 value) const
 Less or equal.
int Increment ()
 Increment and return the new value.
int Decrement ()
 Decrement and return the new value.
int64 Add (int64 addend)
 Add and return the old value.
int64 Subtract (int64 subtractor)
 Subtract and return the old value.
int64 Exchange (int64 value)
 Exchange and return the old value.
void RaceDecrement ()
 Unsafe decrement, only use before or after contention is possible.
void RaceIncrement ()
 Unsafe increment, only use before or after contention is possible.
void RaceExchange (int64 value)
 Unsafe exchange, only use before or after contention is possible.

Public Attributes

volatile int64 counter

Constructor & Destructor Documentation

◆ AtomicCounter64() [1/2]

Threading::Interlocked::AtomicCounter64::AtomicCounter64 ( )
inline

◆ AtomicCounter64() [2/2]

Threading::Interlocked::AtomicCounter64::AtomicCounter64 ( int64 initial)
inline

Constructor.

Member Function Documentation

◆ Add()

int64 Threading::Interlocked::AtomicCounter64::Add ( int64 addend)
inline

Add and return the old value.

◆ Decrement()

int Threading::Interlocked::AtomicCounter64::Decrement ( )
inline

Decrement and return the new value.

◆ Exchange()

int64 Threading::Interlocked::AtomicCounter64::Exchange ( int64 value)
inline

Exchange and return the old value.

◆ Increment()

int Threading::Interlocked::AtomicCounter64::Increment ( )
inline

Increment and return the new value.

◆ operator!=()

bool Threading::Interlocked::AtomicCounter64::operator!= ( int64 value) const
inline

Not-equals.

◆ operator<()

bool Threading::Interlocked::AtomicCounter64::operator< ( int64 value) const
inline

Less.

◆ operator<=()

bool Threading::Interlocked::AtomicCounter64::operator<= ( int64 value) const
inline

Less or equal.

◆ operator==()

bool Threading::Interlocked::AtomicCounter64::operator== ( int64 value) const
inline

Equals.

◆ operator>()

bool Threading::Interlocked::AtomicCounter64::operator> ( int64 value) const
inline

Greater.

◆ operator>=()

bool Threading::Interlocked::AtomicCounter64::operator>= ( int64 value) const
inline

Greater or equal.

◆ RaceDecrement()

void Threading::Interlocked::AtomicCounter64::RaceDecrement ( )
inline

Unsafe decrement, only use before or after contention is possible.

◆ RaceExchange()

void Threading::Interlocked::AtomicCounter64::RaceExchange ( int64 value)
inline

Unsafe exchange, only use before or after contention is possible.

◆ RaceIncrement()

void Threading::Interlocked::AtomicCounter64::RaceIncrement ( )
inline

Unsafe increment, only use before or after contention is possible.

◆ Subtract()

int64 Threading::Interlocked::AtomicCounter64::Subtract ( int64 subtractor)
inline

Subtract and return the old value.

Member Data Documentation

◆ counter

volatile int64 Threading::Interlocked::AtomicCounter64::counter

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