Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 /** | |
| 6 * Help for combining multiple Iterables into a single Iterable. | |
| 7 * | |
| 8 * This API is also available as part of the | |
| 9 * [sequence_zip](#sequence_zip) library. | |
|
Lasse Reichstein Nielsen
2013/08/26 13:57:30
Will the fragment-link work in all cases where thi
Kathy Walrath
2013/08/26 14:15:58
Good question. It works in the new dartdoc, but al
| |
| 10 */ | |
| 5 library iterable_zip; | 11 library iterable_zip; |
| 6 | 12 |
| 7 import "dart:collection"; | 13 import "dart:collection"; |
| 8 | 14 |
| 9 /** | 15 /** |
| 10 * Iterable that iterates over lists of values from other iterables. | 16 * Iterable that iterates over lists of values from other iterables. |
| 11 * | 17 * |
| 12 * When [iterator] is read, an [Iterator] is created for each [Iterable] in | 18 * When [iterator] is read, an [Iterator] is created for each [Iterable] in |
| 13 * the [Iterable] passed to the constructor. | 19 * the [Iterable] passed to the constructor. |
| 14 * | 20 * |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 47 } | 53 } |
| 48 _current = new List(_iterators.length); | 54 _current = new List(_iterators.length); |
| 49 for (int i = 0; i < _iterators.length; i++) { | 55 for (int i = 0; i < _iterators.length; i++) { |
| 50 _current[i] = _iterators[i].current; | 56 _current[i] = _iterators[i].current; |
| 51 } | 57 } |
| 52 return true; | 58 return true; |
| 53 } | 59 } |
| 54 | 60 |
| 55 List get current => _current; | 61 List get current => _current; |
| 56 } | 62 } |
| OLD | NEW |