ImportMessages.fromMap constructor

ImportMessages.fromMap(
  1. Map<String, dynamic> map
)

Implementation

ImportMessages.fromMap(Map<String, dynamic> map) {
  extra = map['@extra'];
  client_id = map['@client_id'];
  chat_id = map['chat_id'];
  if (map['message_file'] != null) {
    message_file = TdApiMap.fromMap(map['message_file']) as InputFile;
  }
  if (map['attached_files'] != null) {
    attached_files = [];
    for (var someValue in map['attached_files']) {
      if (someValue != null) {
        attached_files?.add(TdApiMap.fromMap(someValue) as InputFile);
      }
    }
  }
}