MessageContent class

Chat message content.

Annotations
  • @freezed

Constructors

MessageContent({@JsonKey(name: 'text') required String text, @JsonKey(name: 'type') required String type, @JsonKey(name: 'subtype') String? subtype, @Deprecated('Upload id, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'upload') String? upload, @Deprecated('Upload url, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'mediaURL') String? mediaUrl, @Deprecated('Upload size, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'size') int? size, @Deprecated('Upload duration, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'duration') int? duration, @Default(false) @Deprecated('Upload still processing, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'processing') bool? processing, @Deprecated('Compact representation of a placeholder for an image. Deprecated: use Uploads instead.') @JsonKey(name: 'blurhash') String? blurhash, @Deprecated('Upload preview height, in pixels, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'previewHeight') int? previewHeight, @Deprecated('Upload width, in pixels, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'previewWidth') int? previewWidth, @Deprecated('Upload preview absolute url, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'previewURL') String? previewUrl, @Deprecated('Upload high resolution preview absolute url, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'preview2xURL') String? preview2xUrl, @Deprecated('Upload name, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'name') String? name, @Default(false) @Deprecated('Upload is animated image, if any. Deprecated: use Uploads instead.') @JsonKey(name: 'animated') bool? animated, @JsonKey(name: 'title') String? title, @JsonKey(name: 'old') String? old, @JsonKey(name: 'new') String? isNew, @JsonKey(name: 'actor') String? actor, @JsonKey(name: 'comment') String? comment, @JsonKey(name: 'given_name') String? givenName, @JsonKey(name: 'family_name') String? familyName, @JsonKey(name: 'patronymic') String? patronymic, @JsonKey(name: 'phones') List<String>? phones, @JsonKey(name: 'emails') List<String>? emails, @JsonKey(name: 'stickerpack') String? stickerpack, @JsonKey(name: 'pdf_version') PdfVersion? pdfVersion})
const
factory
MessageContent.fromJson(Map<String, dynamic> json)
factory

Properties

actor String?
Change actor contact id (for "change" mediatype).
no setterinherited
animated bool?
Upload is animated image, if any. Deprecated: use Uploads instead.
no setterinherited
blurhash String?
Compact representation of a placeholder for an image. Deprecated: use Uploads instead.
no setterinherited
comment String?
Comment (for "audiomsg" mediatype).
no setterinherited
copyWith → $MessageContentCopyWith<MessageContent>
no setterinherited
duration int?
Upload duration, if any. Deprecated: use Uploads instead.
no setterinherited
emails List<String>?
Emails list (for "contact" mediatype).
no setterinherited
familyName String?
Family name (for "contact" mediatype).
no setterinherited
givenName String?
Given name (for "contact" mediatype).
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
isNew String?
Change new value (for "change" mediatype).
no setterinherited
mediaUrl String?
Upload url, if any. Deprecated: use Uploads instead.
no setterinherited
name String?
Upload name, if any. Deprecated: use Uploads instead.
no setterinherited
old String?
Change old value (for "change" mediatype).
no setterinherited
patronymic String?
Patronymic name (for "contact" mediatype).
no setterinherited
pdfVersion PdfVersion?
Pdf version, if any.
no setterinherited
phones List<String>?
Contact phones list (for "contact" mediatype).
no setterinherited
preview2xUrl String?
Upload high resolution preview absolute url, if any. Deprecated: use Uploads instead.
no setterinherited
previewHeight int?
Upload preview height, in pixels, if any. Deprecated: use Uploads instead.
no setterinherited
previewUrl String?
Upload preview absolute url, if any. Deprecated: use Uploads instead.
no setterinherited
previewWidth int?
Upload width, in pixels, if any. Deprecated: use Uploads instead.
no setterinherited
processing bool?
Upload still processing, if any. Deprecated: use Uploads instead.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
size int?
Upload size, if any. Deprecated: use Uploads instead.
no setterinherited
stickerpack String?
Stickerpack name (for "sticker" subtype).
no setterinherited
subtype String?
Message subtype, if any.
no setterinherited
text String
Text representation of message.
no setterinherited
title String?
Change title (for "change" mediatype).
no setterinherited
type String
Message type.
no setterinherited
upload String?
Upload id, if any. Deprecated: use Uploads instead.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited