EMMessage class Null safety

Constructors

EMMessage.createCmdSendMessage({required String username, required dynamic action})
构造发送的cmd消息
EMMessage.createCustomSendMessage({required String username, required dynamic event, Map<String, String>? params})
构造发送的自定义消息
EMMessage.createFileSendMessage({required String username, required String filePath, String displayName = ''})
构造发送的文件消息
EMMessage.createImageSendMessage({required String username, required String filePath, String displayName = '', String thumbnailLocalPath = '', bool sendOriginalImage = false, double width = 0, double height = 0})
构造发送的图片消息
EMMessage.createLocationSendMessage({required String username, required double latitude, required double longitude, String address = ''})
构造发送的位置消息
EMMessage.createReceiveMessage({required EMMessageBody? body, EMMessageDirection direction = EMMessageDirection.RECEIVE})
构造接收的消息
EMMessage.createSendMessage({required EMMessageBody? body, EMMessageDirection direction = EMMessageDirection.SEND, String? to, bool? hasRead = true})
构造发送的消息
EMMessage.createTxtSendMessage(String username, String content)
构造发送的文字消息
EMMessage.createVideoSendMessage({required String username, required String filePath, String displayName = '', int duration = 0, String thumbnailLocalPath = '', double width = 0, double height = 0})
构造发送的视频消息
EMMessage.createVoiceSendMessage({required String username, required String filePath, int duration = 0, String displayName = ''})
构造发送的音频消息
EMMessage.fromJson(Map<String, dynamic> map)
factory

Properties

attributes ↔ Map
read / write
body EMMessageBody?
read / write
chatType EMMessageChatType
read / write
conversationId ↔ String?
read / write
direction EMMessageDirection
read / write
from ↔ String?
read / write
hasDeliverAck ↔ bool?
read / write
hashCode → int
The hash code for this object. [...]
read-only, inherited
hasRead ↔ bool?
read / write
hasReadAck ↔ bool?
read / write
listener EMMessageStatusListener?
read / write
localTime ↔ int?
read / write
msgId → String?
read-only
msgLocalId ↔ String?
read / write
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited
serverTime ↔ int?
read / write
status EMMessageStatus
read / write
to ↔ String?
read / write

Methods

dispose() → void
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
setMessageListener(EMMessageStatusListener? listener) → void
toJson() → Map<String, dynamic>
toString() → String
A string representation of this object. [...]

Operators

operator ==(Object other) → bool
The equality operator. [...]
inherited

Static Methods

chatTypeFromInt(int? type) EMMessageChatType
chatTypeToInt(EMMessageChatType type) → int