[][src]Struct ddo::core::common::VarSetIter

pub struct VarSetIter<'a>(pub BitSetIter<'a>);

This type denotes the iterator used to iterate over the Variables to a given VarSet. It should never be manually instantiated, but always via the iter() method from the varset.

Example

let mut vs = VarSet::all(5);
vs.remove(Variable(3));
// iterates for variables 0, 1, 4
for v in vs.iter() {
    println!("{:?}", v);
}

Trait Implementations

impl<'_> Iterator for VarSetIter<'_>[src]

Actually implement the iterator protocol.

type Item = Variable

The type of the elements being iterated over.

fn next(&mut self) -> Option<Variable>[src]

Returns the next variable from the set, or None if all variables have already been iterated upon.

Auto Trait Implementations

impl<'a> RefUnwindSafe for VarSetIter<'a>

impl<'a> Send for VarSetIter<'a>

impl<'a> Sync for VarSetIter<'a>

impl<'a> Unpin for VarSetIter<'a>

impl<'a> UnwindSafe for VarSetIter<'a>

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, 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.