Trait mz_ore::iter::IteratorExt

source ·
pub trait IteratorExtwhere
    Self: Iterator + Sized,
{ fn chain_one(self, item: Self::Item) -> Chain<Self, Once<Self::Item>> { ... } fn all_equal(self) -> bool
        Self::Item: PartialEq
, { ... } }
Expand description

Extension methods for iterators.

Provided Methods§

Chains a single item onto the end of this iterator.

Equivalent to self.chain(iter::once(item)).

Reports whether all the elements of the iterator are the same.

This condition is trivially true for iterators with zero or one elements.