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

Unified Diff: tools/dom/templates/html/impl/impl_Storage.darttemplate

Issue 23055008: Making almost all dom_ methods private. Exceptions will be addressed in a later CL. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 4 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
Index: tools/dom/templates/html/impl/impl_Storage.darttemplate
diff --git a/tools/dom/templates/html/impl/impl_Storage.darttemplate b/tools/dom/templates/html/impl/impl_Storage.darttemplate
index 9e48ff9e3d93411fc24d327eb70ad35b72378880..d9b0e1ae74f9052bbdd760d4c094f11bc14884f0 100644
--- a/tools/dom/templates/html/impl/impl_Storage.darttemplate
+++ b/tools/dom/templates/html/impl/impl_Storage.darttemplate
@@ -35,11 +35,11 @@ $(ANNOTATIONS)$(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS
// TODO(nweiz): update this when maps support lazy iteration
bool containsValue(String value) => values.any((e) => e == value);
- bool containsKey(String key) => $dom_getItem(key) != null;
+ bool containsKey(String key) => _getItem(key) != null;
- String operator [](String key) => $dom_getItem(key);
+ String operator [](String key) => _getItem(key);
- void operator []=(String key, String value) { $dom_setItem(key, value); }
+ void operator []=(String key, String value) { _setItem(key, value); }
String putIfAbsent(String key, String ifAbsent()) {
if (!containsKey(key)) this[key] = ifAbsent();
@@ -48,15 +48,15 @@ $(ANNOTATIONS)$(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS
String remove(String key) {
final value = this[key];
- $dom_removeItem(key);
+ _removeItem(key);
return value;
}
- void clear() => $dom_clear();
+ void clear() => _clear();
void forEach(void f(String key, String value)) {
for (var i = 0; true; i++) {
- final key = $dom_key(i);
+ final key = _key(i);
if (key == null) return;
f(key, this[key]);
@@ -75,9 +75,9 @@ $(ANNOTATIONS)$(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS
return values;
}
- int get length => $dom_length;
+ int get length => _length;
- bool get isEmpty => $dom_key(0) == null;
+ bool get isEmpty => _key(0) == null;
bool get isNotEmpty => !isEmpty;
$!MEMBERS
« no previous file with comments | « tools/dom/templates/html/impl/impl_Screen.darttemplate ('k') | tools/dom/templates/html/impl/impl_StorageEvent.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698