to map.
Map<String, dynamic> toDict() { Map<String, dynamic> d = {}; d['className'] = className; d['version'] = version; d['base'] = base.name; d['infoKey'] = infoKey; return d; }