HyphenateChatSDK 3.9.9.1
IEMThreadManager.h
1//
2// IEMThreadManager.h
3// HyphenateChat
4//
5// Created by 朱继超 on 2022/3/1.
6// Copyright © 2022 easemob.com. All rights reserved.
7//
8
9#import <Foundation/Foundation.h>
10#import "EMThreadManagerDelegate.h"
11#import "EMChatThread.h"
12#import "EMCursorResult.h"
13@class EMChatMessage;
14NS_ASSUME_NONNULL_BEGIN
15@protocol IEMThreadManager <NSObject>
16@required
17
18#pragma mark - Delegate
19
33- (void)addDelegate:(id<EMThreadManagerDelegate>)aDelegate
34 delegateQueue:(_Nullable dispatch_queue_t)aQueue;
35
47- (void)removeDelegate:(id<EMThreadManagerDelegate>)aDelegate;
48
49
50#pragma mark - Get Thread
62- (void)getChatThreadFromSever:(NSString *)threadId completion:(void (^)(EMChatThread *_Nullable thread, EMError * _Nullable aError))aCompletionBlock;
76- (void)getJoinedChatThreadsFromServerWithCursor:(NSString *)aCursor
77 pageSize:(NSInteger)aPageSize
78 completion:(void (^)(EMCursorResult<EMChatThread*>* _Nullable result, EMError * _Nullable aError))aCompletionBlock;
94- (void)getChatThreadsFromServerWithParentId:(NSString *)parentId cursor:(nullable NSString *)aCursor pageSize:(NSInteger)aPageSize completion:(void (^)(EMCursorResult<EMChatThread*> * _Nullable result, EMError * _Nullable aError))aCompletionBlock;
110- (void)getJoinedChatThreadsFromServerWithParentId:(NSString *)parentId cursor:(NSString *)aCursor pageSize:(NSInteger)aPageSize completion:(void (^)(EMCursorResult<EMChatThread*> * _Nullable result, EMError * _Nullable aError))aCompletionBlock;
126- (void)getChatThreadMemberListFromServerWithId:(NSString *)threadId cursor:(NSString *)aCursor pageSize:(NSInteger)pageSize completion:(void (^)(EMCursorResult<NSString*> * _Nullable aResult, EMError * _Nullable aError))aCompletionBlock;
127
139- (void)getLastMessageFromSeverWithChatThreads:(NSArray <NSString *>*)threadIds completion:(void (^)(NSDictionary<NSString*,EMChatMessage*>* _Nullable messageMap, EMError * _Nullable aError))aCompletionBlock;
153- (void)removeMemberFromChatThread:(NSString *)aUser
154 threadId:(NSString *)athreadId
155 completion:(void (^)(EMError * _Nullable aError))aCompletionBlock;
169- (void)updateChatThreadName:(NSString *)name
170 threadId:(NSString *)athreadId
171 completion:(void (^)(EMError * _Nullable aError))aCompletionBlock;
187- (void)createChatThread:(NSString *)threadName messageId:(NSString *)messageId parentId:(NSString *)parentId completion:(void (^)(EMChatThread *_Nullable thread,EMError * _Nullable aError))aCompletionBlock;
199- (void)joinChatThread:(NSString *)threadId completion:(void (^)(EMChatThread *_Nullable thread,EMError * _Nullable aError))aCompletionBlock;
200
212- (void)leaveChatThread:(NSString *)athreadId completion:(void (^)(EMError * _Nullable aError))aCompletionBlock;
213
225- (void)destroyChatThread:(NSString *)athreadId completion:(void (^)(EMError * _Nullable aError))aCompletionBlock;
226
227@end
228NS_ASSUME_NONNULL_END
Definition: EMChatMessage.h:82
Definition: EMChatThread.h:22
Definition: EMCursorResult.h:27
Definition: EMError.h:27
Definition: EMThreadManagerDelegate.h:14
Definition: IEMThreadManager.h:15