markAllConversationsAsRead method

Future<void> markAllConversationsAsRead()

~english Marks all messages as read.

This method is for the local conversations only.

Throws A description of the exception. See EMError. ~end

~chinese 把所有的会话都设成已读。

这里针对的是本地会话。

Throws 如果有异常会在这里抛出,包含错误码和错误描述,详见 EMError。 ~end

Implementation

Future<void> markAllConversationsAsRead() async {
  Map result =
      await ChatChannel.invokeMethod(ChatMethodKeys.markAllChatMsgAsRead);
  try {
    EMError.hasErrorFromResult(result);
  } on EMError catch (e) {
    throw e;
  }
}