ChatMedia class

Annotations

Constructors

ChatMedia.new({required String url, required MediaType mediaType})
Creates a new ChatMedia.
const
ChatMedia.fromJson(String source)
Deserializes a JSON string into a ChatMedia.
factory
ChatMedia.fromMap(Map<String, dynamic> map)
Creates a new ChatMedia from a map (e.g. decoded JSON).
factory

Properties

hashCode int
The hash code for this object.
no setteroverride
mediaType MediaType
The type of media (image, audio, or video).
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
url String
The remote URL of the media.
final

Methods

copyWith({String? url, MediaType? mediaType}) ChatMedia
Returns a copy of this ChatMedia with any provided fields replaced.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() String
Serializes this object to a JSON string.
toMap() Map<String, dynamic>
Converts this object into a Map<String, dynamic> suitable for JSON encoding.
toString() String
A string representation of this object.
override

Operators

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