getFieldsKeysInMap method

Map<String, String?> getFieldsKeysInMap(
  1. List<String> fields,
  2. Map<String, Object?> map, {
  3. String? fieldLC,
  4. String? fieldSimple,
  5. Map<String, String>? mapLC,
  6. Map<String, String>? mapSimple,
})
inherited

Returns a Map of field keys from map.

  • field is case insensitive.

Implementation

Map<String, String?> getFieldsKeysInMap(
    List<String> fields, Map<String, Object?> map,
    {String? fieldLC,
    String? fieldSimple,
    Map<String, String>? mapLC,
    Map<String, String>? mapSimple}) {
  var fieldsMap = fields
      .map((f) => MapEntry(
          f,
          getFieldKeyInMap(f, map,
              fieldLC: fieldLC,
              fieldSimple: fieldSimple,
              mapLC: mapLC,
              mapSimple: mapSimple)))
      .toMapFromEntries();

  return fieldsMap;
}