fromMap static method

ArchiveChatListSettings? fromMap(
  1. Map<String, dynamic>? _map
)
override

Construct from Map.

Implementation

static ArchiveChatListSettings? fromMap(Map<String, dynamic>? _map) {
  if (_map == null) return null;
  var _ = _map["@type"];
  if (_ != CONSTRUCTOR) return null;
  var extra = _map['@extra'];
  var clientId = _map['@clientId'];
  var archive_and_mute_new_chats_from_unknown_users =
      _map['archive_and_mute_new_chats_from_unknown_users']! as bool;
  var keep_unmuted_chats_archived =
      _map['keep_unmuted_chats_archived']! as bool;
  var keep_chats_from_folders_archived =
      _map['keep_chats_from_folders_archived']! as bool;
  return ArchiveChatListSettings(
    extra: extra,
    clientId: clientId,
    archive_and_mute_new_chats_from_unknown_users:
        archive_and_mute_new_chats_from_unknown_users,
    keep_unmuted_chats_archived: keep_unmuted_chats_archived,
    keep_chats_from_folders_archived: keep_chats_from_folders_archived,
  );
}