bufferCountTimeout method

Stream<List<T>> bufferCountTimeout(
  1. int count,
  2. Duration timeout, {
  3. dynamic ignoreEmptyWindows = true,
})

Buffers the stream and emits the buffer when EITHER: a) the number of elements reaches count, OR b) a periodic timeout occurs

Implementation

Stream<List<T>> bufferCountTimeout(int count, Duration timeout,
        {ignoreEmptyWindows = true}) =>
    transform(BufferCountWindowStreamTransformer(
        count, (_) => Stream.periodic(timeout), 0, ignoreEmptyWindows));