You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: lib/src/em_chat_manager.dart
+46-43Lines changed: 46 additions & 43 deletions
Original file line number
Diff line number
Diff line change
@@ -181,7 +181,7 @@ class EMChatManager {
181
181
}
182
182
183
183
/// ~english
184
-
/// Resend a message.
184
+
/// Resends a message.
185
185
///
186
186
/// Param [message] The message object to be resent: [EMMessage].
187
187
/// ~end
@@ -478,7 +478,7 @@ class EMChatManager {
478
478
/// ~end
479
479
///
480
480
/// ~chinese
481
-
/// 根据threadId 获取 thread 会话。
481
+
/// 根据thread ID 获取 thread 会话。
482
482
///
483
483
/// Param [threadId] Thread ID.
484
484
///
@@ -746,7 +746,7 @@ class EMChatManager {
746
746
@Deprecated('Use [fetchConversation] instead')
747
747
748
748
/// ~english
749
-
/// fetch the conversations from the server.
749
+
/// Gets the list of conversations from the server.
750
750
///
751
751
/// Param [pageNum] The current page number.
752
752
///
@@ -758,11 +758,11 @@ class EMChatManager {
758
758
/// ~end
759
759
///
760
760
/// ~chinese
761
-
/// 获取服务器会话。
761
+
/// 获取服务器会话列表。
762
762
///
763
-
/// Param [pageNum]获取的页码。
763
+
/// Param [pageNum]当前页码。
764
764
///
765
-
/// Param [pageSize]获取页中返回数量。
765
+
/// Param [pageSize]每页期望返回的会话数量。
766
766
///
767
767
/// **Return** 当前用户的会话列表。
768
768
///
@@ -799,7 +799,7 @@ class EMChatManager {
799
799
/// The SDK retrieves the list of conversations in the reverse chronological order of their active time (the timestamp of the last message).
800
800
/// If there is no message in the conversation, the SDK retrieves the list of conversations in the reverse chronological order of their creation time.
801
801
///
802
-
/// Param [cursor] The position from which to start getting data. the SDK retrieves conversations from the latest active one if no set.
802
+
/// Param [cursor] The position from which to start getting data. The SDK retrieves conversations from the latest active one if this parameter is not set.
803
803
///
804
804
/// Param [pageSize] The number of conversations that you expect to get on each page. The value range is [1,50].
805
805
///
@@ -809,7 +809,7 @@ class EMChatManager {
809
809
/// ~end
810
810
///
811
811
/// ~chinese
812
-
/// 分页从服务器获取获取会话列表。
812
+
/// 从服务器分页获取会话列表。
813
813
///
814
814
/// SDK 按照会话活跃时间(会话的最后一条消息的时间戳)倒序返回会话列表。
815
815
/// 若会话中没有消息,则 SDK 按照会话创建时间的倒序返回会话列表。
@@ -978,11 +978,11 @@ class EMChatManager {
978
978
///
979
979
/// Param [pageSize] The number of messages per page.
980
980
///
981
-
/// Param [direction] The direction of the search to be fetched. See [EMSearchDirection].
981
+
/// Param [direction] The message search direction. See [EMSearchDirection].
982
982
///
983
-
/// Param [startMsgId] The ID of the message from which you start to get the historical messages. If `null` is passed, the SDK gets messages in reverse chronological order.
983
+
/// Param [startMsgId] The ID of the message from which you start to get the historical messages. If `null` is passed, the SDK gets messages in the reverse chronological order.
984
984
///
985
-
/// **Return** The obtained messages and the cursor for the next fetch action.
985
+
/// **Return** The obtained messages and the cursor for the next query.
986
986
///
987
987
/// **Throws** A description of the exception. See [EMError].
988
988
/// ~end
@@ -1032,7 +1032,7 @@ class EMChatManager {
1032
1032
}
1033
1033
1034
1034
/// ~english
1035
-
/// [FetchMessageOptions] paging from the server to retrieve the history message for the specified session.
1035
+
/// Gets historical messages of a conversation from the server according to [FetchMessageOptions].
1036
1036
///
1037
1037
/// Param [conversationId] The conversation ID, which is the user ID of the peer user for one-to-one chat, but the group ID for group chat.
1038
1038
///
@@ -1097,7 +1097,7 @@ class EMChatManager {
1097
1097
///
1098
1098
/// Param [maxCount] The maximum number of messages to retrieve each time.
1099
1099
///
1100
-
/// Param [from] A username or group ID at which the retrieval is targeted. Usually, it is the conversation ID.
1100
+
/// Param [from] A user ID or group ID at which the retrieval is targeted. Usually, it is the conversation ID.
1101
1101
///
1102
1102
/// **Return** The list of messages.
1103
1103
///
@@ -1152,7 +1152,6 @@ class EMChatManager {
1152
1152
/// ~english
1153
1153
/// Gets read receipts for group messages from the server with pagination.
1154
1154
///
1155
-
/// See also:
1156
1155
/// For how to send read receipts for group messages, see [sendConversationReadAck].
1157
1156
///
1158
1157
/// Param [msgId] The message ID.
@@ -1219,7 +1218,7 @@ class EMChatManager {
1219
1218
///
1220
1219
/// Param [conversationType] The conversation type. See [EMConversationType].
1221
1220
///
1222
-
/// Param [isDeleteRemoteMessage] Whether to delete the server chat history when deleting the conversation.
1221
+
/// Param [isDeleteMessage] Whether to delete the chat history when deleting the conversation.
/// **Throws** A description of the exception. See [EMError].
1340
1339
/// ~end
@@ -1363,11 +1362,11 @@ class EMChatManager {
1363
1362
}
1364
1363
1365
1364
/// ~english
1366
-
/// Deletes a reaction.
1365
+
/// Deletes a Reaction.
1367
1366
///
1368
1367
/// Param [messageId] The message ID.
1369
1368
///
1370
-
/// Param [reaction] The reaction content.
1369
+
/// Param [reaction] The Reaction content.
1371
1370
///
1372
1371
/// **Throws** A description of the exception. See [EMError].
1373
1372
/// ~end
@@ -1402,7 +1401,7 @@ class EMChatManager {
1402
1401
///
1403
1402
/// Param [chatType] The chat type. Only one-to-one chat [ChatType.Chat] and group chat [ChatType.GroupChat] are allowed.
1404
1403
///
1405
-
/// Param [groupId]which is valid only when the chat type is group chat.
1404
+
/// Param [groupId]The group ID. This parameter is valid only when the chat type is group chat.
1406
1405
///
1407
1406
/// **Return** The Reaction list under the specified message ID([EMMessageReaction.userList] is the summary data, which only contains the information of the first three users).
1408
1407
///
@@ -1454,11 +1453,11 @@ class EMChatManager {
1454
1453
}
1455
1454
1456
1455
/// ~english
1457
-
/// Gets the reaction details.
1456
+
/// Gets the Reaction details.
1458
1457
///
1459
1458
/// Param [messageId] The message ID.
1460
1459
///
1461
-
/// Param [reaction] The reaction content.
1460
+
/// Param [reaction] The Reaction content.
1462
1461
///
1463
1462
/// Param [cursor] The cursor position from which to get Reactions.
1464
1463
///
@@ -1512,13 +1511,13 @@ class EMChatManager {
1512
1511
}
1513
1512
1514
1513
/// ~english
1515
-
/// Translate a message.
1514
+
/// Translates a text message.
1516
1515
///
1517
-
/// Param [msg] The message object
1516
+
/// Param [msg] The message object for translation.
1518
1517
///
1519
-
/// Param [languages] The target languages to translate
1518
+
/// Param [languages] The list of target language codes.
1520
1519
///
1521
-
/// **Return** Translated Message
1520
+
/// **Return** The translated message.
1522
1521
///
1523
1522
/// **Throws** A description of the exception. See [EMError].
1524
1523
/// ~end
@@ -1528,7 +1527,7 @@ class EMChatManager {
1528
1527
///
1529
1528
/// Param [msg] 要翻译的文本消息。
1530
1529
///
1531
-
/// Param [languages]目标语言。
1530
+
/// Param [languages]目标语言代码列表。
1532
1531
///
1533
1532
/// **Return** 译文。
1534
1533
///
@@ -1552,9 +1551,9 @@ class EMChatManager {
1552
1551
}
1553
1552
1554
1553
/// ~english
1555
-
/// Fetch all languages what the translate service support
1554
+
/// Gets all languages supported by the translation service.
1556
1555
///
1557
-
/// **Return** Supported languages
1556
+
/// **Return** The supported languages.
1558
1557
///
1559
1558
/// **Throws** A description of the exception. See [EMError].
1560
1559
/// ~end
@@ -1586,7 +1585,7 @@ class EMChatManager {
1586
1585
///
1587
1586
/// The SDK returns the pinned conversations in the reverse chronological order of their pinning.
1588
1587
///
1589
-
/// Param [cursor] The position from which to start getting data. the SDK retrieves conversations from the latest pinned one if no set.
1588
+
/// Param [cursor] The position from which to start getting data. If this parameter is not set, the SDK retrieves conversations from the latest pinned one.
1590
1589
///
1591
1590
/// Param [pageSize] The number of conversations that you expect to get on each page. The value range is [1,50].
1592
1591
///
@@ -1674,9 +1673,11 @@ class EMChatManager {
1674
1673
}
1675
1674
1676
1675
/// ~english
1677
-
/// Modifies a local message or a message at the server side.
1676
+
/// Modifies a message.
1678
1677
///
1679
-
/// You can call this method to only modify a text message in one-to-one chats or group chats, but not in chat rooms.
1678
+
/// After this method is called to modify a message, both the local message and the message on the server are modified.
1679
+
///
1680
+
/// This method can only modify a text message in one-to-one chats or group chats, but not in chat rooms.
1680
1681
///
1681
1682
/// Param [messageId] The ID of the message to modify.
1682
1683
///
@@ -1688,12 +1689,14 @@ class EMChatManager {
1688
1689
/// ~end
1689
1690
///
1690
1691
/// ~chinese
1691
-
/// 修改本地以及服务端的消息内容。
1692
+
/// 修改消息内容。
1692
1693
///
1693
-
/// 只能调用该方法修改单聊和群聊中的文本消息,不能修改聊天室消息。
1694
+
/// 调用该方法修改消息内容后,本地和服务端的消息均会修改。
1694
1695
///
1695
-
/// Param [messageId] 消息实例id。
1696
+
/// 只能调用该方法修改单聊和群聊中的文本消息,不能修改聊天室消息。
1696
1697
///
1698
+
/// Param [messageId] 消息实例 ID。
1699
+
///
1697
1700
/// Param [msgBody] 文本消息体实例 [EMTextMessageBody]。
1698
1701
///
1699
1702
/// **Return** 修改后的消息实例。
@@ -1722,21 +1725,21 @@ class EMChatManager {
1722
1725
}
1723
1726
1724
1727
/// ~english
1725
-
/// fetch combine message detail.
1728
+
/// Gets the details of a combined message.
1726
1729
///
1727
-
/// Param [message] The combine message.
1730
+
/// Param [message] The combined message.
1728
1731
///
1729
-
/// **Return** The combined message list.
1732
+
/// **Return** The list of original messages included in the combined message.
1730
1733
///
1731
1734
/// **Throws** A description of the exception. See [EMError].
0 commit comments