combine2<A, B, R> static method
Constructs a CombineLatestStream from a pair of Streams
where combiner
is used to create a new event of type R
, based on the
latest events emitted by the provided Streams.
Implementation
static CombineLatestStream<dynamic, R> combine2<A, B, R>(
Stream<A> streamOne,
Stream<B> streamTwo,
R Function(A a, B b) combiner,
) =>
CombineLatestStream<dynamic, R>(
[streamOne, streamTwo],
(List<dynamic> values) => combiner(values[0] as A, values[1] as B),
);