fromMap static method
override
Construct from Map.
Implementation
static ChatEventActiveUsernamesChanged? 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 old_usernames = List<String>.from(
(_map["old_usernames"] ?? []).map(
(e) => e as String,
),
);
var new_usernames = List<String>.from(
(_map["new_usernames"] ?? []).map(
(e) => e as String,
),
);
return ChatEventActiveUsernamesChanged(
extra: extra,
clientId: clientId,
old_usernames: old_usernames,
new_usernames: new_usernames,
);
}