toJson method

  1. @override
Map<String, dynamic> toJson()
override

Converts an InlineQueryResultMpeg4Gif object to a JSON object

Implementation

@override
Map<String, dynamic> toJson() {
  return {
    'type': type.value,
    'mpeg4_url': mpeg4Url,
    'thumbnail_url': thumbnailUrl,
    'id': id,
    'mpeg4_width': mpeg4Width,
    'mpeg4_height': mpeg4Height,
    'mpeg4_duration': mpeg4Duration,
    'thumbnail_mime_type': thumbnailMimeType,
    'title': title,
    'caption': caption,
    'parse_mode': parseMode?.value,
    'caption_entities': captionEntities?.map((e) => e.toJson()).toList(),
    'reply_markup': replyMarkup?.toJson(),
    'input_message_content': inputMessageContent?.toJson(),
    'show_caption_above_media': showCaptionAboveMedia,
  }..removeWhere(_nullFilter);
}