decodeMapOrNull<K, V> method
Decodes the data as a nullable map of key-value pairs.
Optionally takes Decodables to decode the keys and values of the map.
Implementation
@override
Map<K, V>? decodeMapOrNull<K, V>({Decodable<K>? keyUsing, Decodable<V>? valueUsing}) {
if (_done) return null;
final key = keys.current;
return decoder.decodeMapOrNull(key is String ? key : '',
id: key is int ? key : null, keyUsing: keyUsing, valueUsing: valueUsing);
}