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

Unified Diff: sdk/lib/html/dartium/html_dartium.dart

Side-by-side diff isn't available for this file because of its large size.
Issue 15263004: Adding isNotEmpty property to collection and string. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rename hasElement to isNotEmpty Created 7 years, 6 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:
Download patch
Index: sdk/lib/html/dartium/html_dartium.dart
diff --git a/sdk/lib/html/dartium/html_dartium.dart b/sdk/lib/html/dartium/html_dartium.dart
index a0b627850ce552666a0edfab998b9d2ce7b310d6..ef67ac0ed527256189794f2fa791f07831b5f292 100644
--- a/sdk/lib/html/dartium/html_dartium.dart
+++ b/sdk/lib/html/dartium/html_dartium.dart
@@ -21245,6 +21245,7 @@ class Storage extends NativeFieldWrapperClass1 implements Map<String, String>
int get length => $dom_length;
bool get isEmpty => $dom_key(0) == null;
+ bool get isNotEmpty => !isEmpty;
Storage.internal();
@DomName('Storage.length')
@@ -26725,6 +26726,11 @@ abstract class _AttributeMap implements Map<String, String> {
}
/**
+ * Returns true if there is at least one {key, value} pair in the map.
+ */
+ bool get isNotEmpty => !isEmpty;
+
+ /**
* Checks to see if the node should be included in this map.
*/
bool _matches(Node node);
@@ -26871,6 +26877,8 @@ class _DataAttributeMap implements Map<String, String> {
// TODO: Use lazy iterator when it is available on Map.
bool get isEmpty => length == 0;
+ bool get isNotEmpty => !isEmpty;
+
// Helpers.
String _attr(String key) => 'data-$key';
bool _matches(String key) => key.startsWith('data-');
@@ -31037,6 +31045,7 @@ class _DOMStringMap extends NativeFieldWrapperClass1 implements Map<String, Stri
Iterable<String> get values => Maps.getValues(this);
int get length => Maps.length(this);
bool get isEmpty => Maps.isEmpty(this);
+ bool get isNotEmpty => Maps.isNotEmpty(this);
}
final Future<SendPort> __HELPER_ISOLATE_PORT =

Powered by Google App Engine
This is Rietveld 408576698