deepCopyList function

List deepCopyList(
  1. List list, {
  2. bool throwOnNonJsonObjects = true,
  3. bool ignoreNonJsonObjects = false,
  4. bool where(
    1. String key,
    2. dynamic value
    )?,
})

Deep copies a JSON List.

Implementation

List<dynamic> deepCopyList(
  List<dynamic> list, {
  bool throwOnNonJsonObjects = true,
  bool ignoreNonJsonObjects = false,
  bool Function(String key, dynamic value)? where,
}) {
  if (where == null && !throwOnNonJsonObjects && !ignoreNonJsonObjects) {
    return _deepCopyListFast(list);
  }
  return _deepCopyListGeneral(
    list,
    throwOnNonJsonObjects,
    ignoreNonJsonObjects,
    where,
  );
}