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

Side by Side Diff: client/dom/generated/src/wrapping/_CanvasPixelArrayWrappingImplementation.dart

Issue 9114026: Add map to dart:dom collections. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: x Created 8 years, 11 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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 // WARNING: Do not edit - generated code. 5 // WARNING: Do not edit - generated code.
6 6
7 class _CanvasPixelArrayWrappingImplementation extends DOMWrapperBase implements CanvasPixelArray { 7 class _CanvasPixelArrayWrappingImplementation extends DOMWrapperBase implements CanvasPixelArray {
8 _CanvasPixelArrayWrappingImplementation() : super() {} 8 _CanvasPixelArrayWrappingImplementation() : super() {}
9 9
10 static create__CanvasPixelArrayWrappingImplementation() native { 10 static create__CanvasPixelArrayWrappingImplementation() native {
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 } 60 }
61 61
62 int last() { 62 int last() {
63 return this[length - 1]; 63 return this[length - 1];
64 } 64 }
65 65
66 void forEach(void f(int element)) { 66 void forEach(void f(int element)) {
67 _Collections.forEach(this, f); 67 _Collections.forEach(this, f);
68 } 68 }
69 69
70 Collection map(f(int element)) {
71 return _Collections.map(this, [], f);
72 }
73
70 Collection<int> filter(bool f(int element)) { 74 Collection<int> filter(bool f(int element)) {
71 return _Collections.filter(this, new List<int>(), f); 75 return _Collections.filter(this, new List<int>(), f);
72 } 76 }
73 77
74 bool every(bool f(int element)) { 78 bool every(bool f(int element)) {
75 return _Collections.every(this, f); 79 return _Collections.every(this, f);
76 } 80 }
77 81
78 bool some(bool f(int element)) { 82 bool some(bool f(int element)) {
79 return _Collections.some(this, f); 83 return _Collections.some(this, f);
(...skipping 18 matching lines...) Expand all
98 bool isEmpty() { 102 bool isEmpty() {
99 return length == 0; 103 return length == 0;
100 } 104 }
101 105
102 Iterator<int> iterator() { 106 Iterator<int> iterator() {
103 return new _FixedSizeListIterator<int>(this); 107 return new _FixedSizeListIterator<int>(this);
104 } 108 }
105 109
106 String get typeName() { return "CanvasPixelArray"; } 110 String get typeName() { return "CanvasPixelArray"; }
107 } 111 }
OLDNEW
« no previous file with comments | « client/dom/frog/dom_frog.dart ('k') | client/dom/generated/src/wrapping/_Float32ArrayWrappingImplementation.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698