Stream expand(Iterable convert(T value))

Creates a new stream from this stream that converts each element into zero or more events.

Each incoming event is converted to an Iterable of new events, and each of these new events are then sent by the returned stream in order.

The returned stream is a broadcast stream if this stream is. If a broadcast stream is listened to more than once, each subscription will individually call convert and expand the events.


Stream/*<S>*/ expand/*<S>*/(Iterable/*<S>*/ convert(T value)) {
  return new _ExpandStream<T, dynamic/*=S*/>(this, convert);