fromMap static method

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

Construct from Map.

Implementation

static MessageVideoNote? 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 video_note = VideoNote.fromMap(_map['video_note'])!;
  var is_viewed = _map['is_viewed']! as bool;
  var is_secret = _map['is_secret']! as bool;
  return MessageVideoNote(
    extra: extra,
    clientId: clientId,
    video_note: video_note,
    is_viewed: is_viewed,
    is_secret: is_secret,
  );
}