filled static method

NSMutableArray filled(
  1. int length,
  2. ObjCObject fill
)
override

Creates a NSMutableArray of the given length with fill at each position.

The length must be a non-negative integer.

Implementation

static NSMutableArray filled(int length, objc.ObjCObject fill) {
  final a = arrayWithCapacity(length);
  for (var i = 0; i < length; ++i) a.addObject(fill);
  return a;
}