pub trait Zip {
    type Item;
    type Stream: Stream<Item = Self::Item>;

    // Required method
    fn zip(self) -> Self::Stream;
}
Expand description

‘Zips up’ multiple streams into a single stream of pairs.

Required Associated Types§

source

type Item

What’s the return type of our stream?

source

type Stream: Stream<Item = Self::Item>

What stream do we return?

Required Methods§

source

fn zip(self) -> Self::Stream

Combine multiple streams into a single stream.

Implementations on Foreign Types§

source§

impl<S, const N: usize> Zip for [S; N]where
S: IntoStream,

§

type Item = <Zip<<S as IntoStream>::IntoStream, N> as Stream>::Item

§

type Stream = Zip<<S as IntoStream>::IntoStream, N>

source§

fn zip(self) -> Self::Stream

source§

impl<S> Zip for Vec<S>where
S: IntoStream,

§

type Item = <Zip<<S as IntoStream>::IntoStream> as Stream>::Item

§

type Stream = Zip<<S as IntoStream>::IntoStream>

source§

fn zip(self) -> Self::Stream

Implementors§