20 #ifndef PBD_ATOMIC_COUNTER_H
21 #define PBD_ATOMIC_COUNTER_H
44 return g_atomic_int_get (&
m_value);
47 void set (gint new_value)
49 g_atomic_int_set (&
m_value, new_value);
64 return g_atomic_int_dec_and_test (&
m_value);
74 return g_atomic_int_compare_and_exchange
85 bool cas (gint old_value, gint new_value)
99 #endif // PBD_ATOMIC_COUNTER_H
atomic_counter(gint value=0)
bool cas(gint old_value, gint new_value)
bool compare_and_exchange(gint old_value, gint new_value)
atomic_counter & operator=(const atomic_counter &)
bool decrement_and_test()
atomic_counter(const atomic_counter &)