copy method

List<T> copy()

Implementation

List<T> copy() {
  if (isNullOrEmpty) return [];
  return List<T>.generate(this!.length, (i) => this![i]);
}