Struct WithPosition
#[must_use = "iterator adaptors are lazy and do nothing unless consumed"]
pub struct WithPosition<I>
where
I: Iterator, { /* private fields */ }
An iterator adaptor that wraps each element in an Position.
Iterator element type is (Position, I::Item).
See .with_position() for more information.
Trait Implementations
impl<I> Clone for WithPosition<I>
where
I: Clone + Iterator,
I::Item: Clone,
fn clone(&self) -> Self
impl<I> Debug for WithPosition<I>
where
I: Iterator,
Peekable<Fuse<I>>: Debug,
fn fmt(&self, f: &mut Formatter<'_>) -> Result
impl<I> ExactSizeIterator for WithPosition<I>
where
I: ExactSizeIterator,
impl<I: Iterator> FusedIterator for WithPosition<I>
impl<I: Iterator> Iterator for WithPosition<I>
type Item = (Position, <I as Iterator>::Item);fn next(&mut self) -> Option<Self::Item>fn size_hint(&self) -> (usize, Option<usize>)fn fold<B, F>(self, init: B, f: F) -> B where F: FnMut(B, Self::Item) -> B,