Expand description
Atomic, thread-safe counters of differing integer widths
§Comes with
These counters support
- Incrementing/decrementing by default (1) or specified amounts,
- Using per-operation atomic orderings, (see this also)
- Instantiation with default offset (0) and default atomic ordering ( sequentially consistent ),
- Instantiation with custom offset, custom ordering or both,
- Instantiation with custom enum-flag-based counting behaviors (monotonic, nonmonotonic, incrementing, decrementing, cyclic, acyclic)
- PartialEq, Eq, Hash, PartialOrd, Ord, Clone, Debug, Display
- Send, Sync
§Optional features
serde
: serialization and deserialization supportiterators
: iterator support
Modules§
- behavior
- Counter behavioral elements
Structs§
- Counter
I8 - An atomic counter using AtomicI8 / (core::i8).
- Counter
I16 - An atomic counter using AtomicI16 / (core::i16).
- Counter
I32 - An atomic counter using AtomicI32 / (core::i32).
- Counter
I64 - An atomic counter using AtomicI64 / (core::i64).
- Counter
Isize - An atomic counter using AtomicIsize / (core::isize).
- Counter
U8 - An atomic counter using AtomicU8 / (core::u8).
- Counter
U16 - An atomic counter using AtomicU16 / (core::u16).
- Counter
U32 - An atomic counter using AtomicU32 / (core::u32).
- Counter
U64 - An atomic counter using AtomicU64 / (core::u64).
- Counter
Usize - An atomic counter using AtomicUsize / (core::usize).
- Counting
Behavior Conflict Iter - An iterator over the variants of Self
Enums§
- Counting
Behavior - Counting behaviors
- Counting
Behavior Conflict - A conflict between counting behaviors
Traits§
- Counts
Nonmotonically - Something that can counts up or down
- HasCounting
Behavior - Something that has counting behaviors
- IsCounter
- Something that is a counter