[][src]Struct tinyset::setusize::SetUsize

pub struct SetUsize(_);

A set for usize elements.

Implementations

impl SetUsize[src]

pub fn is_empty(&self) -> bool[src]

Returns true if the set is empty

impl SetUsize[src]

pub fn new() -> Self[src]

Creates an empty set..

pub fn with_capacity(_cap: usize) -> Self[src]

Creates an empty set with the specified capacity.

pub fn insert(&mut self, elem: usize) -> bool[src]

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.

pub fn len(&self) -> usize[src]

Returns the number of elements in the set.

pub fn contains(&self, value: usize) -> bool[src]

Returns true if the set contains a value.

pub fn remove(&mut self, value: usize) -> bool[src]

Removes an element, and returns true if that element was present.

pub fn iter<'a>(&'a self) -> impl Iterator<Item = usize> + 'a[src]

Iterate

pub fn drain<'a>(&'a mut self) -> impl Iterator<Item = usize> + 'a[src]

Drain

Trait Implementations

impl Clone for SetUsize[src]

impl Default for SetUsize[src]

fn default() -> Self[src]

Creates an empty set..

impl FromIterator<usize> for SetUsize[src]

impl IntoIterator for SetUsize[src]

type Item = usize

The type of the elements being iterated over.

type IntoIter = IntoIter

Which kind of iterator are we turning this into?

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,