RepeatIterable<T> constructor

RepeatIterable<T>(
  1. T element,
  2. int count
)

Creates an iterable consisting of element repeated count times.

If the value of count is zero, this will result in an empty iterable. Having the value of count be less than zero will result in an empty iterable.

Implementation

RepeatIterable(this.element, this.count) : assert(count >= 0);