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

Side by Side Diff: runtime/lib/byte_array.dart

Issue 12090093: Reapply "Rename mappedBy to map." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fixed bug in previous commit. Created 7 years, 10 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
« no previous file with comments | « runtime/lib/array.dart ('k') | runtime/lib/growable_array.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 patch class Int8List { 5 patch class Int8List {
6 /* patch */ factory Int8List(int length) { 6 /* patch */ factory Int8List(int length) {
7 return new _Int8Array(length); 7 return new _Int8Array(length);
8 } 8 }
9 9
10 /* patch */ factory Int8List.transferable(int length) { 10 /* patch */ factory Int8List.transferable(int length) {
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 222
223 bool contains(element) => IterableMixinWorkaround.contains(this, element); 223 bool contains(element) => IterableMixinWorkaround.contains(this, element);
224 224
225 void forEach(void f(element)) { 225 void forEach(void f(element)) {
226 var len = this.length; 226 var len = this.length;
227 for (var i = 0; i < len; i++) { 227 for (var i = 0; i < len; i++) {
228 f(this[i]); 228 f(this[i]);
229 } 229 }
230 } 230 }
231 231
232 Iterable map(f(int element)) {
233 return IterableMixinWorkaround.map(this, f);
234 }
235
232 List mappedBy(f(int element)) { 236 List mappedBy(f(int element)) {
233 return IterableMixinWorkaround.mappedByList(this, f); 237 return IterableMixinWorkaround.mappedByList(this, f);
234 } 238 }
235 239
236 String join([String separator]) { 240 String join([String separator]) {
237 return IterableMixinWorkaround.join(this, separator); 241 return IterableMixinWorkaround.join(this, separator);
238 } 242 }
239 243
240 dynamic reduce(dynamic initialValue, 244 dynamic reduce(dynamic initialValue,
241 dynamic combine(dynamic initialValue, element)) { 245 dynamic combine(dynamic initialValue, element)) {
242 return IterableMixinWorkaround.reduce(this, initialValue, combine); 246 return IterableMixinWorkaround.reduce(this, initialValue, combine);
243 } 247 }
244 248
245 Collection where(bool f(element)) { 249 Collection where(bool f(element)) {
246 return IterableMixinWorkaround.where(this, f); 250 return IterableMixinWorkaround.where(this, f);
247 } 251 }
248 252
249 List<int> take(int n) { 253 Iterable<int> take(int n) {
250 return IterableMixinWorkaround.takeList(this, n); 254 return IterableMixinWorkaround.takeList(this, n);
251 } 255 }
252 256
253 Iterable<int> takeWhile(bool test(int value)) { 257 Iterable<int> takeWhile(bool test(int value)) {
254 return IterableMixinWorkaround.takeWhile(this, test); 258 return IterableMixinWorkaround.takeWhile(this, test);
255 } 259 }
256 260
257 List<int> skip(int n) { 261 Iterable<int> skip(int n) {
258 return IterableMixinWorkaround.skipList(this, n); 262 return IterableMixinWorkaround.skipList(this, n);
259 } 263 }
260 264
261 Iterable<int> skipWhile(bool test(int value)) { 265 Iterable<int> skipWhile(bool test(int value)) {
262 return IterableMixinWorkaround.skipWhile(this, test); 266 return IterableMixinWorkaround.skipWhile(this, test);
263 } 267 }
264 268
265 bool every(bool f(element)) { 269 bool every(bool f(element)) {
266 return IterableMixinWorkaround.every(this, f); 270 return IterableMixinWorkaround.every(this, f);
267 } 271 }
(...skipping 2401 matching lines...) Expand 10 before | Expand all | Expand 10 after
2669 ByteArray asByteArray([int start = 0, int length]) { 2673 ByteArray asByteArray([int start = 0, int length]) {
2670 if (length == null) { 2674 if (length == null) {
2671 length = this.lengthInBytes(); 2675 length = this.lengthInBytes();
2672 } 2676 }
2673 _rangeCheck(this.length, start, length); 2677 _rangeCheck(this.length, start, length);
2674 return _array.subByteArray(_offset + start, length); 2678 return _array.subByteArray(_offset + start, length);
2675 } 2679 }
2676 2680
2677 static const int _BYTES_PER_ELEMENT = 8; 2681 static const int _BYTES_PER_ELEMENT = 8;
2678 } 2682 }
OLDNEW
« no previous file with comments | « runtime/lib/array.dart ('k') | runtime/lib/growable_array.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698