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

Unified Diff: tools/dom/src/WrappedList.dart

Issue 13704017: Make html lists print a nice toString method. (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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/html/node_test.dart ('k') | tools/dom/templates/html/impl/impl_Element.darttemplate » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/src/WrappedList.dart
diff --git a/tools/dom/src/WrappedList.dart b/tools/dom/src/WrappedList.dart
index 171dd7e49c8323735d4b13cfde4987b2b4ad6fa5..d0c80031b642ff95a77ca64665fa31683a63ca5c 100644
--- a/tools/dom/src/WrappedList.dart
+++ b/tools/dom/src/WrappedList.dart
@@ -131,6 +131,13 @@ class _WrappedList<E> implements List<E> {
}
Map<int, E> asMap() => IterableMixinWorkaround.asMapList(_list);
+
+ String toString() {
+ StringBuffer buffer = new StringBuffer('[');
+ buffer.writeAll(this, ', ');
+ buffer.write(']');
+ return buffer.toString();
+ }
}
/**
« no previous file with comments | « tests/html/node_test.dart ('k') | tools/dom/templates/html/impl/impl_Element.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698