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

Unified Diff: sdk/lib/collection/iterable.dart

Issue 15263004: Adding isNotEmpty property to collection and string. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix template generation Created 7 years, 7 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/collection/hash_set.dart ('k') | sdk/lib/collection/linked_hash_map.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/collection/iterable.dart
diff --git a/sdk/lib/collection/iterable.dart b/sdk/lib/collection/iterable.dart
index 2ec143b8c495e2a462275c06b3f4118b4b9cb5fa..a9505432dd30f91ebfb62596764fd25fbc2ec4be 100644
--- a/sdk/lib/collection/iterable.dart
+++ b/sdk/lib/collection/iterable.dart
@@ -95,6 +95,8 @@ abstract class IterableMixin<E> implements Iterable<E> {
bool get isEmpty => !iterator.moveNext();
+ bool get isNotEmpty => !isEmpty;
+
Iterable<E> take(int n) {
return new TakeIterable<E>(this, n);
}
@@ -287,6 +289,8 @@ abstract class IterableBase<E> implements Iterable<E> {
bool get isEmpty => !iterator.moveNext();
+ bool get isNotEmpty => !isEmpty;
+
Iterable<E> take(int n) {
return new TakeIterable<E>(this, n);
}
« no previous file with comments | « sdk/lib/collection/hash_set.dart ('k') | sdk/lib/collection/linked_hash_map.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698