Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: tools/dom/src/WrappedList.dart

Issue 13685004: Reduce usage of ItearbleMixinWorkaround. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 part of dart.dom.html; 5 part of dart.dom.html;
6 6
7 /** 7 /**
8 * A list which just wraps another list, for either intercepting list calls or 8 * A list which just wraps another list, for either intercepting list calls or
9 * retyping the list (for example, from List<A> to List<B> where B extends A). 9 * retyping the list (for example, from List<A> to List<B> where B extends A).
10 */ 10 */
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 void setRange(int start, int length, List<E> from, [int startFrom]) { 120 void setRange(int start, int length, List<E> from, [int startFrom]) {
121 _list.setRange(start, length, from, startFrom); 121 _list.setRange(start, length, from, startFrom);
122 } 122 }
123 123
124 void removeRange(int start, int length) { _list.removeRange(start, length); } 124 void removeRange(int start, int length) { _list.removeRange(start, length); }
125 125
126 void insertRange(int start, int length, [E fill]) { 126 void insertRange(int start, int length, [E fill]) {
127 _list.insertRange(start, length, fill); 127 _list.insertRange(start, length, fill);
128 } 128 }
129 129
130 Map<int, E> asMap() => IterableMixinWorkaround.asMapList(_list); 130 Map<int, E> asMap() => _list.asMap();
131 } 131 }
132 132
133 /** 133 /**
134 * Iterator wrapper for _WrappedList. 134 * Iterator wrapper for _WrappedList.
135 */ 135 */
136 class _WrappedIterator<E> implements Iterator<E> { 136 class _WrappedIterator<E> implements Iterator<E> {
137 Iterator _iterator; 137 Iterator _iterator;
138 138
139 _WrappedIterator(this._iterator); 139 _WrappedIterator(this._iterator);
140 140
141 bool moveNext() { 141 bool moveNext() {
142 return _iterator.moveNext(); 142 return _iterator.moveNext();
143 } 143 }
144 144
145 E get current => _iterator.current; 145 E get current => _iterator.current;
146 } 146 }
OLDNEW
« sdk/lib/collection/hash_set.dart ('K') | « tests/corelib/iterable_min_max_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698