compareCount method

int compareCount(
  1. Iterable other
)

Compares the length of this iterable and other and returns an integer representing their comparison.

If this iterable is longer than other, this method returns 1.

If other is longer than this iterable, this method returns -1.

If this iterable and other are the same length, this method returns 0.

Implementation

int compareCount(Iterable<dynamic> other) {
  return count().compareTo(other.count());
}