kTIMConversationMarkTypeUnread
, the unread count at the underlying layer will not change.Attribute | Definition | Description |
conversationIDList | List of conversation IDs | Up to 100 conversations can be marked at a time. |
markType | Mark type | A conversation can be marked as a favorite, unread, collapsed, or hidden. |
enableMark | Mark/Unmark | A conversation can be marked/unmarked. |
32 ≤ n < 64
indicates that n
must be equal to or greater than 32 and less than 64). For example, 0x1LL << 32
indicates "Online on an iPhone".// Mark a conversationTIMResult res = TencentIMSDK.ConvMarkConversation(new List<string> {conv_id}, TIMConversationMarkType.kTIMConversationMarkTypeStar, true, (int code, string desc, List<ConversationOperationResult> results, string user_data)=>{// Async result of the conversation marking});
conv_mark_array
(details) field of the conversation's ConvInfo
will be changed. You can call the SetConvEventCallback
(details) API to listen for conversation change notifications.// Set the conversation listenerTencentIMSDK.SetConvEventCallback((TIMConvEvent conv_event, List<ConvInfo> conv_list, string user_data)=>{// Process the callback logic});
// Get the conversation listConversationListFilter filter = new ConversationListFilter{conversation_list_filter_conv_type: TIMConvType.kTIMConv_C2C,// Conversation typeconversation_list_filter_mark_type: TIMConversationMarkType.kTIMConversationMarkTypeStar,// Conversation mark typeconversation_list_filter_conversation_group: "groupName"// Named of the group whose data is to be pulled};ulong next_seq = 0; // Pulling cursoruint count = 10; // Pulling count// Advanced API for getting the conversation listTIMResult res = TencentIMSDK.ConvGetConversationListByFilter(filter, next_seq, count, (int code, string desc, ConversationListResult result, string user_data)=>{// Async result of the conversation list gettingif (code == 0) {// Pulled successfullybool isFinished = result.conversation_list_result_is_finished; // Whether pulling is completednext_seq = result.conversation_list_result_next_seq; // Cursor for subsequent paged pullingvar conversationList = result.conversation_list_result_conv_list; // List of messages pulled this time// If more conversations need to be pulled, use the returned `nextSeq` to continue pulling until `isFinished` is `true`.}});
Was this page helpful?