pub trait CollectGroupBy: Iterator {
    // Provided methods
    fn collect_group_by_key<K, V, FA>(
        self,
        f: FA
    ) -> HashMap<K, Vec<V, Global>, RandomState>
       where Self: Sized + Iterator<Item = V>,
             K: Hash + Eq,
             FA: Fn(&V) -> K { ... }
    fn collect_group_by<K, V>(self) -> HashMap<K, Vec<V, Global>, RandomState>
       where Self: Sized + Iterator<Item = (K, V)>,
             K: Hash + Eq { ... }
}
Expand description

An iterator which collects items into group.

Provided Methods§

source

fn collect_group_by_key<K, V, FA>( self, f: FA ) -> HashMap<K, Vec<V, Global>, RandomState>where Self: Sized + Iterator<Item = V>, K: Hash + Eq, FA: Fn(&V) -> K,

Collects items into group.

source

fn collect_group_by<K, V>(self) -> HashMap<K, Vec<V, Global>, RandomState>where Self: Sized + Iterator<Item = (K, V)>, K: Hash + Eq,

Collects items into group.

Implementors§

source§

impl<T> CollectGroupBy for Twhere T: Iterator,