sendMessage abstract method

Future<ZIMMessageSentResult> sendMessage(
  1. ZIMMessage message,
  2. String toConversationID,
  3. ZIMConversationType conversationType,
  4. ZIMMessageSendConfig config, [
  5. ZIMMessageSendNotification? notification,
])

Supported versions: 2.4.0 and above.

Detailed description: This method can be used to send messages in single chat, room and group chat.

Business scenario: When you need to send message to the target user, target message room, and target group chat after logging in, send it through this interface.

Call timing: It can be called after login.

Usage limit: no more than 10/s, available after login, unavailable after logout.

Related callback: ZIMMessageSentResult, ZIMMessageSendNotification, ZIMEventHandler.onReceivePeerMessage, ZIMEventHandler.onReceiveRoomMessage, ZIMEventHandler.onReceiveGroupMessage, ZIMEventHandler.onConversationChanged, ZIMEventHandler.onConversationTotalUnreadMessageCountUpdated.

Related interfaces: queryHistoryMessage, deleteAllMessage, deleteMessages,sendMediaMessage.

Implementation

Future<ZIMMessageSentResult> sendMessage(
    ZIMMessage message,
    String toConversationID,
    ZIMConversationType conversationType,
    ZIMMessageSendConfig config,
    [ZIMMessageSendNotification? notification]);