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

Unified Diff: sdk/lib/html/html_common/filtered_element_list.dart

Issue 12391046: Add List.asMap(). (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sdk/lib/core/list.dart ('k') | tests/corelib/list_as_map_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/html/html_common/filtered_element_list.dart
diff --git a/sdk/lib/html/html_common/filtered_element_list.dart b/sdk/lib/html/html_common/filtered_element_list.dart
index bc0a6af1c790e923df5fd01b0f548e16f7a8c4de..264472070b6cf7cd6b0ac9252dc493ff4a66577c 100644
--- a/sdk/lib/html/html_common/filtered_element_list.dart
+++ b/sdk/lib/html/html_common/filtered_element_list.dart
@@ -205,4 +205,8 @@ class FilteredElementList implements List {
Element min([int compare(Element a, Element b)]) => _filtered.min(compare);
Element max([int compare(Element a, Element b)]) => _filtered.max(compare);
+
+ Map<int, Element> asMap() {
+ return IterableMixinWorkaround.asMapList(this);
+ }
}
« no previous file with comments | « sdk/lib/core/list.dart ('k') | tests/corelib/list_as_map_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698