skip method Null safety

Future<int> skip(
  1. int count

Skips the next count data events.

The count must be non-negative.

When successful, this is equivalent to using take and ignoring the result.

If an error occurs before count data events have been skipped, the returned future completes with that error instead.

If the stream closes before count data events, the remaining unskipped event count is returned. If the returned future completes with the integer 0, then all events were succssfully skipped. If the value is greater than zero then the stream ended early.


Future<int> skip(int count) {
  RangeError.checkNotNegative(count, 'count');
  var request = _SkipRequest<T>(count);
  return request.future;