pub trait StreamingIteratorMut: StreamingIterator {
    fn get_mut(&mut self) -> Option<&mut Self::Item>;

    fn next_mut(&mut self) -> Option<&mut Self::Item> { ... }
    fn fold_mut<B, F>(self, init: B, f: F) -> B
    where
        Self: Sized,
        F: FnMut(B, &mut Self::Item) -> B
, { ... } fn for_each_mut<F>(self, f: F)
    where
        Self: Sized,
        F: FnMut(&mut Self::Item)
, { ... } fn map_deref_mut<B, F>(self, f: F) -> MapDerefMut<Self, F>
    where
        Self: Sized,
        F: FnMut(&mut Self::Item) -> B
, { ... } fn flatten(self) -> Flatten<Self>
    where
        Self: Sized,
        Self::Item: StreamingIterator
, { ... } }
Expand description

An interface for dealing with mutable streaming iterators.

Required Methods§

Returns a mutable reference to the current element of the iterator.

The behavior of calling this method before advance has been called is unspecified.

Modifications through this reference may also have an unspecified effect on further iterator advancement, but implementations are encouraged to document this.

Provided Methods§

Advances the iterator and returns the next mutable value.

The behavior of calling this method after the end of the iterator has been reached is unspecified.

The default implementation simply calls advance followed by get_mut.

Reduces the iterator’s mutable elements to a single, final value.

Calls a closure on each mutable element of an iterator.

Creates a regular, non-streaming iterator which transforms mutable elements of this iterator by passing them to a closure.

Creates an iterator which flattens nested streaming iterators.

Implementations on Foreign Types§

Implementors§