Trait ConcurrentSet

Source
pub trait ConcurrentSet<T> {
    // Required methods
    fn contains(&self, value: &T) -> bool;
    fn insert(&self, value: T) -> bool;
    fn remove(&self, value: &T) -> bool;
}
Expand description

Trait for a concurrent set.

Required Methods§

Source

fn contains(&self, value: &T) -> bool

Returns true iff the set contains the value.

Source

fn insert(&self, value: T) -> bool

Adds the value to the set. Returns whether the value was newly inserted.

Source

fn remove(&self, value: &T) -> bool

Removes the value from the set. Returns whether the value was present in the set.

Implementors§