Orocos Real-Time Toolkit
2.9.0
|
C++ abstraction of atomic integer operations. More...
#include <rtt/os/Atomic.hpp>
Public Member Functions | |
AtomicInt (int value=0) | |
AtomicInt (const AtomicInt &orig) | |
~AtomicInt () | |
const AtomicInt & | operator= (const AtomicInt &orig) |
int | read () const |
Read the current value of the integer. More... | |
void | set (int i) |
Set the integer to a new value. More... | |
void | add (int i) |
void | sub (int i) |
bool | sub_and_test (int i) |
Subtract a value and test if the result is zero. More... | |
void | inc () |
void | dec () |
bool | dec_and_test () |
Decrement and test if the result is zero. More... | |
bool | inc_and_test () |
Increment and test if the result is zero. More... | |
C++ abstraction of atomic integer operations.
Definition at line 49 of file Atomic.hpp.
|
inline |
Definition at line 53 of file Atomic.hpp.
References ORO_ATOMIC_SETUP().
|
inline |
Definition at line 58 of file Atomic.hpp.
References oro_atomic_read(), and ORO_ATOMIC_SETUP().
|
inline |
Definition at line 63 of file Atomic.hpp.
References ORO_ATOMIC_CLEANUP().
|
inline |
Definition at line 84 of file Atomic.hpp.
References oro_atomic_add().
Referenced by RTT::base::BufferLockFree< T >::Push().
|
inline |
Definition at line 97 of file Atomic.hpp.
References oro_atomic_dec().
Referenced by RTT::mqueue::Dispatcher::removeQueue().
|
inline |
Decrement and test if the result is zero.
Definition at line 104 of file Atomic.hpp.
References oro_atomic_dec_and_test().
Referenced by RTT::internal::ConnectionBase::deref(), RTT::base::DataSourceBase::deref(), and RTT::mqueue::intrusive_ptr_release().
|
inline |
Definition at line 95 of file Atomic.hpp.
References oro_atomic_inc().
Referenced by RTT::mqueue::Dispatcher::addQueue(), RTT::mqueue::intrusive_ptr_add_ref(), RTT::base::BufferLockFree< T >::Push(), RTT::internal::ConnectionBase::ref(), RTT::base::DataSourceBase::ref(), and RTT::os::ThreadInterface::ThreadInterface().
|
inline |
Increment and test if the result is zero.
Definition at line 111 of file Atomic.hpp.
References oro_atomic_inc_and_test().
Definition at line 68 of file Atomic.hpp.
References oro_atomic_read(), and oro_atomic_set().
|
inline |
Read the current value of the integer.
Definition at line 77 of file Atomic.hpp.
References oro_atomic_read().
Referenced by RTT::base::BufferLockFree< T >::dropped(), and RTT::os::ThreadInterface::ThreadInterface().
|
inline |
Set the integer to a new value.
Definition at line 82 of file Atomic.hpp.
References oro_atomic_set().
|
inline |
Definition at line 86 of file Atomic.hpp.
References oro_atomic_sub().
|
inline |
Subtract a value and test if the result is zero.
Definition at line 93 of file Atomic.hpp.
References oro_atomic_sub_and_test().