A `quiver.streams` version of `interleave` would also have the advantage
over `zip(streams).expand((e) => e)` that it wouldn't have to wait for each
stream to emit an event before starting to emit events for each cycle.

Cheers,
Sean Eagan


On Wed, May 21, 2014 at 12:39 PM, Yegor <notifications@github.com> wrote:

> In lib/src/iterables/interleave.dart:
>
> > +//
> > +//     http://www.apache.org/licenses/LICENSE-2.0
> > +//
> > +// Unless required by applicable law or agreed to in writing, software
> > +// distributed under the License is distributed on an "AS IS" BASIS,
> > +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
> > +// See the License for the specific language governing permissions and
> > +// limitations under the License.
> > +
> > +part of quiver.iterables;
> > +
> > +/**
> > + * Returns an [Iterable] of first item in each iterable, then the second etc. The
> > + * returned Iterable contains number of elements in the shortest Iterable times number of
> > + * [iterables]. If [iterables] is empty, it returns an empty list.
> > + */
>
> We should contrast this method to:
>
> zip(iterables).expand((e) => e);
>
> I believe the idea is that this is more efficient?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/google/quiver-dart/pull/129/files#r12909763>
> .
>