codec_string_map top-level property
Implementation
BitCodec<Map<String, dynamic>> codec_string_map = BitCodec(writer: (writer, t) {
writer.writeCodec(codec_int_best, t.length);
t.forEach((key, value) {
writer.writeCodec(codec_string_best, key);
writer.writeCodec(codec_any, value);
});
}, reader: (reader) {
int length = reader.readCodec(codec_int_best);
Map<String, dynamic> map = <String, dynamic>{};
for (int i = 0; i < length; i++) {
map[reader.readCodec(codec_string_best)] = reader.readCodec(codec_any);
}
return map;
});