dynamicToListMap<T> static method

List<T> dynamicToListMap<T>(
  1. dynamic list,
  2. T f(
    1. Map<String, dynamic> e
    )
)

Implementation

static List<T> dynamicToListMap<T>(
  dynamic list,
  T Function(Map<String, dynamic> e) f,
) {
  if (list is Map) {
    return [f(Map<String, dynamic>.from(list))];
  }
  return dynamicToList<T>(
    list,
    (x) => f(Map<String, dynamic>.from(x as Map)),
  );
}