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

Side by Side Diff: client/dom/common/implementation.dart

Issue 9009002: Promote DOMType to public dart:dom type. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 9 years 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 | « no previous file | client/dom/common/public.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 class DOMType extends DOMWrapperBase {
2 // FIXME: Remove if/when Dart supports OLS for all objects.
3 var dartObjectLocalStorage;
4
5 String get typeName() {
6 throw new UnsupportedOperationException("typeName must be overridden.");
7 }
8 }
9
10 class ListBase<E> extends DOMType implements List<E> { 1 class ListBase<E> extends DOMType implements List<E> {
11 ListBase(); 2 ListBase();
12 3
13 void forEach(void f(E element)) => Collections.forEach(this, f); 4 void forEach(void f(E element)) => Collections.forEach(this, f);
14 Collection<E> filter(bool f(E element)) => Collections.filter(this, [], f); 5 Collection<E> filter(bool f(E element)) => Collections.filter(this, [], f);
15 bool every(bool f(E element)) => Collections.every(this, f); 6 bool every(bool f(E element)) => Collections.every(this, f);
16 bool some(bool f(E element)) => Collections.some(this, f); 7 bool some(bool f(E element)) => Collections.some(this, f);
17 bool isEmpty() => Collections.isEmpty(this); 8 bool isEmpty() => Collections.isEmpty(this);
18 9
19 void sort(int compare(E a, E b)) { 10 void sort(int compare(E a, E b)) {
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 } 113 }
123 114
124 V remove(K key) { 115 V remove(K key) {
125 throw 'Immutable collection'; 116 throw 'Immutable collection';
126 } 117 }
127 118
128 Collection<K> getKeys() { 119 Collection<K> getKeys() {
129 throw 'Must be implemented'; 120 throw 'Must be implemented';
130 } 121 }
131 } 122 }
OLDNEW
« no previous file with comments | « no previous file | client/dom/common/public.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698