EMChatEventHandler constructor

EMChatEventHandler(
  1. {void onMessagesReceived(
    1. List<EMMessage> messages
    )?,
  2. void onCmdMessagesReceived(
    1. List<EMMessage> messages
    )?,
  3. void onMessagesRead(
    1. List<EMMessage> messages
    )?,
  4. void onGroupMessageRead(
    1. List<EMGroupMessageAck> groupMessageAcks
    )?,
  5. VoidCallback? onReadAckForGroupMessageUpdated,
  6. void onMessagesDelivered(
    1. List<EMMessage> messages
    )?,
  7. void onMessagesRecalled(
    1. List<EMMessage> messages
    )?,
  8. VoidCallback? onConversationsUpdate,
  9. void onConversationRead(
    1. String from,
    2. String to
    )?,
  10. void onMessageReactionDidChange(
    1. List<EMMessageReactionEvent> events
    )?,
  11. void onMessageContentChanged(
    1. EMMessage message,
    2. String operatorId,
    3. int operationTime
    )?,
  12. void onMessagePinChanged(
    1. String messageId,
    2. String conversationId,
    3. MessagePinOperation pinOperation,
    4. MessagePinInfo pinInfo
    )?,
  13. void onMessagesRecalledInfo(
    1. List<RecallMessageInfo>
    )?}
)

消息事件监听。

Param onMessagesReceived 在收到文本、图片、视频、语音、地理位置和文件等消息时,通过此回调通知用户。

Param onCmdMessagesReceived 收到命令消息回调。

Param onMessagesRead 收到单聊消息已读回执的回调。

Param onGroupMessageRead 收到群组消息的已读回执的回调。

Param onReadAckForGroupMessageUpdated 群消息已读变更。

Param onMessagesDelivered 收到消息已送达回执的回调。

Param onMessagesRecalled 已收到的消息被撤回的回调。

Param onConversationsUpdate 会话更新事件回调。

Param onConversationRead 收到会话已读回执的回调。

Param onMessageReactionDidChange 消息表情回复(Reaction)变化监听器。

Param onMessageContentChanged 收到消息内容变化。

Param onMessagePinChanged 消息置顶状态变化。

Param onMessagesRecalledInfo 已收到的消息被撤回的回调。

Implementation

EMChatEventHandler(
    {this.onMessagesReceived,
    this.onCmdMessagesReceived,
    this.onMessagesRead,
    this.onGroupMessageRead,
    this.onReadAckForGroupMessageUpdated,
    this.onMessagesDelivered,
    this.onMessagesRecalled,
    this.onConversationsUpdate,
    this.onConversationRead,
    this.onMessageReactionDidChange,
    this.onMessageContentChanged,
    this.onMessagePinChanged,
    this.onMessagesRecalledInfo});