toMapFromFields method

Map<String, dynamic> toMapFromFields([
  1. O? obj
])

Returns a Map from fieldsNames, calling getField for each one. See toJsonFromFields if you need a JSON Map (with valid JSON values).

  • If obj is not provided, uses object as instance.

Implementation

Map<String, dynamic> toMapFromFields([O? obj]) {
  obj ??= object;
  if (obj == null) {
    throw StateError("Null object!");
  }

  return _toMapFromFieldsImpl(obj);
}