Struct std::iter::ScanExperimental [-]  [+] [src]

pub struct Scan<'a, A, B, T, St> {
    pub state: St,
    // some fields omitted
}

An iterator to maintain state while iterating another iterator

Fields

state

The current internal state to be passed to the closure next.

Trait Implementations

impl<'a, A, B, T: Iterator<A>, St> Iterator<B> for Scan<'a, A, B, T, St>

fn next(&mut self) -> Option<B>

fn size_hint(&self) -> (uint, Option<uint>)

fn size_hint(&self) -> (uint, Option<uint>)

fn chain<U: Iterator<B>>(self, U) -> Chain<Scan<'a, A, B, T, St>, U>

fn zip<B, U: Iterator<B>>(self, U) -> Zip<Scan<'a, A, B, T, St>, U>

fn map<B>(self, |B| -> B) -> Map<'r, B, B, Scan<'a, A, B, T, St>>

fn filter(self, |&B| -> bool) -> Filter<'r, B, Scan<'a, A, B, T, St>>

fn filter_map<B>(self, |B| -> Option<B>) -> FilterMap<'r, B, B, Scan<'a, A, B, T, St>>

fn enumerate(self) -> Enumerate<Scan<'a, A, B, T, St>>

fn peekable(self) -> Peekable<B, Scan<'a, A, B, T, St>>

fn skip_while(self, |&B| -> bool) -> SkipWhile<'r, B, Scan<'a, A, B, T, St>>

fn take_while(self, |&B| -> bool) -> TakeWhile<'r, B, Scan<'a, A, B, T, St>>

fn skip(self, uint) -> Skip<Scan<'a, A, B, T, St>>

fn take(self, uint) -> Take<Scan<'a, A, B, T, St>>

fn scan<St, B>(self, St, |&mut St, B| -> Option<B>) -> Scan<'r, B, B, Scan<'a, A, B, T, St>, St>

fn flat_map<B, U: Iterator<B>>(self, |B| -> U) -> FlatMap<'r, B, Scan<'a, A, B, T, St>, U>

fn fuse(self) -> Fuse<Scan<'a, A, B, T, St>>

fn inspect(self, |&B|) -> Inspect<'r, B, Scan<'a, A, B, T, St>>

fn by_ref(&'r mut self) -> ByRef<'r, Scan<'a, A, B, T, St>>

fn collect<B: FromIterator<B>>(&mut self) -> B

fn nth(&mut self, uint) -> Option<B>

fn last(&mut self) -> Option<B>

fn fold<B>(&mut self, B, |B, B| -> B) -> B

fn count(&mut self) -> uint

fn all(&mut self, |B| -> bool) -> bool

fn any(&mut self, |B| -> bool) -> bool

fn find(&mut self, |&B| -> bool) -> Option<B>

fn position(&mut self, |B| -> bool) -> Option<uint>

fn max_by<B: Ord>(&mut self, |&B| -> B) -> Option<B>

fn min_by<B: Ord>(&mut self, |&B| -> B) -> Option<B>