Index: tools/dom/templates/html/impl/impl_Element.darttemplate |
diff --git a/tools/dom/templates/html/impl/impl_Element.darttemplate b/tools/dom/templates/html/impl/impl_Element.darttemplate |
index 6d34148c72457c2b0e0d4ecf50f8053071d8dbe3..4993f03c6f472e7cd0c181ea58f37a5e8e00fe80 100644 |
--- a/tools/dom/templates/html/impl/impl_Element.darttemplate |
+++ b/tools/dom/templates/html/impl/impl_Element.darttemplate |
@@ -282,6 +282,13 @@ class _ChildrenElementList implements List { |
Map<int, Element> asMap() { |
return IterableMixinWorkaround.asMapList(this); |
} |
+ |
+ String toString() { |
+ StringBuffer buffer = new StringBuffer('['); |
+ buffer.writeAll(this, ', '); |
+ buffer.write(']'); |
+ return buffer.toString(); |
+ } |
} |
// TODO(jacobr): this is an inefficient implementation but it is hard to see |
@@ -492,6 +499,13 @@ class _FrozenElementList implements List { |
Map<int, Element> asMap() { |
return IterableMixinWorkaround.asMapList(this); |
} |
+ |
+ String toString() { |
+ StringBuffer buffer = new StringBuffer('['); |
+ buffer.writeAll(this, ', '); |
+ buffer.write(']'); |
+ return buffer.toString(); |
+ } |
} |
class _FrozenElementListIterator implements Iterator<Element> { |
@@ -979,6 +993,12 @@ $if DART2JS |
$else |
$endif |
+ /** |
+ * Print out a String representation of this Element. By default, this is |
+ * this Element's tagName. |
+ */ |
+ String toString() => this.tagName; |
+ |
$!MEMBERS |
} |