toJson method

Map<String, dynamic> toJson()

Serialize this object to json.

Implementation

Map<String, dynamic> toJson() => Map.fromEntries(Iterable.castFrom(
        keys.fold(<MapEntry<String, dynamic>>[], (json, key) {
      if (key.serialized != null) {
        json.add(MapEntry(key.key, key.serialized));
      }
      return json;
    })));