#include <userver/utils/flags.hpp>
Wrapper to extend enum with atomic flags interface.
Public Types | |
using | ValueType = std::underlying_type_t<Enum> |
Public Member Functions | |
constexpr | AtomicFlags (Enum) |
constexpr | AtomicFlags (std::initializer_list< Enum >) |
operator bool () const | |
operator Flags< Enum > () const | |
Flags< Enum > | Load (std::memory_order=std::memory_order_seq_cst) const |
AtomicFlags & | operator= (Flags< Enum >) |
AtomicFlags & | Store (Flags< Enum >, std::memory_order=std::memory_order_seq_cst) |
Flags< Enum > | Exchange (Flags< Enum >) |
AtomicFlags & | operator|= (Flags< Enum >) |
AtomicFlags & | operator&= (Flags< Enum >) |
AtomicFlags & | Clear (Flags< Enum >) |
Flags< Enum > | FetchOr (Flags< Enum >, std::memory_order=std::memory_order_seq_cst) |
Flags< Enum > | FetchAnd (Flags< Enum >, std::memory_order=std::memory_order_seq_cst) |
Flags< Enum > | FetchClear (Flags< Enum >, std::memory_order=std::memory_order_seq_cst) |
bool | CompareExchangeWeak (Flags< Enum > &expected, Flags< Enum > desired, std::memory_order order=std::memory_order_seq_cst) |
bool | CompareExchangeStrong (Flags< Enum > &expected, Flags< Enum > desired, std::memory_order order=std::memory_order_seq_cst) |
bool | CompareExchangeWeak (Flags< Enum > &expected, Flags< Enum > desired, std::memory_order success, std::memory_order failure) |
bool | CompareExchangeStrong (Flags< Enum > &expected, Flags< Enum > desired, std::memory_order success, std::memory_order failure) |
Flags< Enum > | operator| (Flags< Enum >) const |
Flags< Enum > | operator& (Flags< Enum >) const |
bool | operator== (Flags< Enum >) const |
bool | operator!= (Flags< Enum >) const |
ValueType | GetValue () |
using utils::AtomicFlags< Enum >::ValueType = std::underlying_type_t<Enum> |
|
inlineconstexpr |
|
explicitconstexpr |
|
constexpr |
AtomicFlags< Enum > & utils::AtomicFlags< Enum >::Clear | ( | Flags< Enum > | flags | ) |
bool utils::AtomicFlags< Enum >::CompareExchangeStrong | ( | Flags< Enum > & | expected, |
Flags< Enum > | desired, | ||
std::memory_order | order = std::memory_order_seq_cst ) |
bool utils::AtomicFlags< Enum >::CompareExchangeStrong | ( | Flags< Enum > & | expected, |
Flags< Enum > | desired, | ||
std::memory_order | success, | ||
std::memory_order | failure ) |
bool utils::AtomicFlags< Enum >::CompareExchangeWeak | ( | Flags< Enum > & | expected, |
Flags< Enum > | desired, | ||
std::memory_order | order = std::memory_order_seq_cst ) |
bool utils::AtomicFlags< Enum >::CompareExchangeWeak | ( | Flags< Enum > & | expected, |
Flags< Enum > | desired, | ||
std::memory_order | success, | ||
std::memory_order | failure ) |
Flags< Enum > utils::AtomicFlags< Enum >::Exchange | ( | Flags< Enum > | flags | ) |
Flags< Enum > utils::AtomicFlags< Enum >::FetchAnd | ( | Flags< Enum > | rhs, |
std::memory_order | memory_order = std::memory_order_seq_cst ) |
Flags< Enum > utils::AtomicFlags< Enum >::FetchClear | ( | Flags< Enum > | flags, |
std::memory_order | memory_order = std::memory_order_seq_cst ) |
Flags< Enum > utils::AtomicFlags< Enum >::FetchOr | ( | Flags< Enum > | rhs, |
std::memory_order | memory_order = std::memory_order_seq_cst ) |
AtomicFlags< Enum >::ValueType utils::AtomicFlags< Enum >::GetValue | ( | ) |
Flags< Enum > utils::AtomicFlags< Enum >::Load | ( | std::memory_order | order = std::memory_order_seq_cst | ) | const |
|
explicit |
utils::AtomicFlags< Enum >::operator Flags< Enum > | ( | ) | const |
bool utils::AtomicFlags< Enum >::operator!= | ( | Flags< Enum > | rhs | ) | const |
Flags< Enum > utils::AtomicFlags< Enum >::operator& | ( | Flags< Enum > | rhs | ) | const |
AtomicFlags< Enum > & utils::AtomicFlags< Enum >::operator&= | ( | Flags< Enum > | rhs | ) |
AtomicFlags< Enum > & utils::AtomicFlags< Enum >::operator= | ( | Flags< Enum > | rhs | ) |
bool utils::AtomicFlags< Enum >::operator== | ( | Flags< Enum > | rhs | ) | const |
Flags< Enum > utils::AtomicFlags< Enum >::operator| | ( | Flags< Enum > | rhs | ) | const |
AtomicFlags< Enum > & utils::AtomicFlags< Enum >::operator|= | ( | Flags< Enum > | rhs | ) |
AtomicFlags< Enum > & utils::AtomicFlags< Enum >::Store | ( | Flags< Enum > | rhs, |
std::memory_order | order = std::memory_order_seq_cst ) |