fromMap static method

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

Construct from Map.

Implementation

static UnreadReaction? 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 type = ReactionType.fromMap(_map['type'])!;
  var sender_id = MessageSender.fromMap(_map['sender_id'])!;
  var is_big = _map['is_big']! as bool;
  return UnreadReaction(
    extra: extra,
    clientId: clientId,
    type: type,
    sender_id: sender_id,
    is_big: is_big,
  );
}