doc.rust-lang.org
pub struct Empty<T>
An iterator that yields nothing.
struct
core
Stable since 1.2.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn zip<A, B>(a: A, b: B) -> Zip<<A as >::IntoIter, <B as >::IntoIter>
Converts the arguments to iterators and zips them.
function
core
Stable since 1.59.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Zip<A, B>
An iterator that iterates two other iterators simultaneously.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct TakeWhile<I, P>
An iterator that only accepts elements while predicate returns true.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Take<I>
An iterator that only iterates over the first n iterations of iter.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct StepBy<I>
An iterator for stepping iterators by a custom amount.
struct
core
Stable since 1.28.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct SkipWhile<I, P>
An iterator that rejects elements while predicate returns true.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Skip<I>
An iterator that skips over n elements of iter.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Scan<I, St, F>
An iterator to maintain state while iterating another iterator.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Rev<T>
A double-ended iterator with the direction inverted.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn peek_mut(&mut self) -> Option<&mut <I as >::Item>
Returns a mutable reference to the next() value without advancing the iterator.
method
core
Stable since 1.53.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn peek(&mut self) -> Option<&<I as >::Item>
Returns a reference to the next() value without advancing the iterator.
method
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn next_if_map_mut<R>(&mut self, f: impl FnOnce(&mut <I as >::Item) -> Option<R>) -> Option<R>
Gives a mutable reference to the next value of the iterator and applies a function f to it, returning the result and advancing the iterator if f returns Some.
method
core
Stable since 1.94.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn next_if_map<R>(&mut self, f: impl FnOnce(<I as >::Item) -> Result<R, <I as >::Item>) -> Option<R>
Consumes the next value of this iterator and applies a function f on it, returning the result if the closure returns Ok.
method
core
Stable since 1.94.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn next_if_eq<T>(&mut self, expected: &T) -> Option<<I as >::Item>
Consume and return the next item if it is equal to expected.
method
core
Stable since 1.51.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn next_if(&mut self, func: impl FnOnce(&<I as >::Item) -> bool) -> Option<<I as >::Item>
Consume and return the next value of this iterator if a condition is true.
method
core
Stable since 1.51.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Peekable<I>
An iterator with a peek() that returns an optional reference to the next element.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct MapWhile<I, P>
An iterator that only accepts elements while predicate returns Some(_).
struct
core
Stable since 1.57.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Map<I, F>
An iterator that maps the values of iter with f.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub struct Inspect<I, F>
An iterator that calls a function with a reference to each element before yielding it.
struct
core
Stable since 1.0.0
Version 1.100.0-nightly