Struct tinyset::u64set::U64Set
[−]
[src]
pub struct U64Set { /* fields omitted */ }
A set implemented of u64 elements
Methods
impl U64Set
[src]
fn default() -> U64Set
Creates an empty set..
fn new() -> U64Set
Creates an empty set..
fn with_capacity(cap: usize) -> U64Set
Creates an empty set with the specified capacity.
fn with_max_and_capacity(max: u64, cap: usize) -> U64Set
Creates an empty set with the specified capacity.
fn len(&self) -> usize
Returns the number of elements in the set.
fn reserve(&mut self, additional: usize)
Reserves capacity for at least additional
more elements to be
inserted in the set. The collection may reserve more space
to avoid frequent reallocations.
fn reserve_with_max(&mut self, max: u64, additional: usize)
Reserves capacity for at least additional
more elements to
be inserted in the set, with maximum value of max
. The
collection may reserve more space to avoid frequent
reallocations.
fn insert(&mut self, elem: u64) -> bool
Adds a value to the set.
If the set did not have this value present, true
is returned.
If the set did have this value present, false
is returned.
fn contains(&self, value: &u64) -> bool
Returns true if the set contains a value.
fn remove(&mut self, value: &u64) -> bool
Removes an element, and returns true if that element was present.
fn iter(&self) -> Iter
Returns an iterator over the set.
Trait Implementations
impl Debug for U64Set
[src]
impl Clone for U64Set
[src]
fn clone(&self) -> U64Set
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more