HyphenateChatSDK 4.2.3
IEMChatroomManager.h
15#import <Foundation/Foundation.h>
16
17#import "EMCommonDefs.h"
18#import "EMChatroomManagerDelegate.h"
19#import "EMChatroomOptions.h"
20#import "EMChatroom.h"
21#import "EMPageResult.h"
22
23#import "EMCursorResult.h"
24
25@class EMError;
26
34@protocol IEMChatroomManager <NSObject>
35
36@required
37
38#pragma mark - Delegate
39
53- (void)addDelegate:(id<EMChatroomManagerDelegate> _Nonnull)aDelegate
54 delegateQueue:(dispatch_queue_t _Nullable)aQueue;
55
67- (void)removeDelegate:(id<EMChatroomManagerDelegate> _Nonnull)aDelegate;
68
69#pragma mark - Fetch Chatrooms
70
94- (EMPageResult<EMChatroom*> *_Nullable)getChatroomsFromServerWithPage:(NSInteger)aPageNum
95 pageSize:(NSInteger)aPageSize
96 error:(EMError **_Nullable)pError;
97
119- (void)getChatroomsFromServerWithPage:(NSInteger)aPageNum
120 pageSize:(NSInteger)aPageSize
121 completion:(void (^_Nullable)(EMPageResult<EMChatroom*> *_Nullable aResult, EMError *_Nullable aError))aCompletionBlock;
122
123#pragma mark - Edit Chatroom
124
146- (EMChatroom *)joinChatroom:(NSString * _Nonnull)aChatroomId
147 error:(EMError ** _Nullable)pError;
148
168- (void)joinChatroom:(NSString *_Nonnull)aChatroomId
169 completion:(void (^_Nullable)(EMChatroom *_Nullable aChatroom, EMError *_Nullable aError))aCompletionBlock;
170
197- (void)joinChatroom:(NSString *_Nonnull)aChatroomId
198 ext:(NSString* _Nullable)ext
199 leaveOtherRooms:(BOOL)leaveOtherRooms
200 completion:(void (^_Nullable)(EMChatroom *_Nullable aChatroom, EMError *_Nullable aError))aCompletionBlock;
201
202
222- (void)leaveChatroom:(NSString *_Nonnull)aChatroomId
223 error:(EMError **_Nullable)pError;
224
244- (void)leaveChatroom:(NSString *_Nonnull)aChatroomId
245 completion:(void (^_Nullable)(EMError *_Nullable aError))aCompletionBlock;
246
247#pragma mark - Fetch
248
270- (EMChatroom *_Nullable)getChatroomSpecificationFromServerWithId:(NSString *_Nonnull)aChatroomId
271 error:(EMError *_Nullable*)pError;
272
291- (void)getChatroomSpecificationFromServerWithId:(NSString *_Nonnull)aChatroomId
292 completion:(void (^_Nullable)(EMChatroom *_Nullable aChatroom, EMError *_Nullable aError))aCompletionBlock;
293
320- (EMCursorResult<NSString*> *_Nullable)getChatroomMemberListFromServerWithId:(NSString *_Nonnull)aChatroomId
321 cursor:(NSString *_Nullable)aCursor
322 pageSize:(NSInteger)aPageSize
323 error:(EMError **_Nullable)pError;
324
348- (void)getChatroomMemberListFromServerWithId:(NSString *_Nonnull)aChatroomId
349 cursor:(NSString *_Nullable)aCursor
350 pageSize:(NSInteger)aPageSize
351 completion:(void (^_Nullable)(EMCursorResult<NSString*> *_Nullable aResult, EMError *_Nullable aError))aCompletionBlock;
352
374- (NSString *_Nullable)getChatroomAnnouncementWithId:(NSString *_Nonnull)aChatroomId
375 error:(EMError **_Nullable )pError;
376
395- (void)getChatroomAnnouncementWithId:(NSString *_Nonnull)aChatroomId
396 completion:(void (^_Nullable)(NSString *_Nullable aAnnouncement, EMError *_Nullable aError))aCompletionBlock;
397
398@end
Definition: EMChatroom.h:42
Definition: EMCursorResult.h:27
Definition: EMError.h:27
Definition: EMPageResult.h:24
Definition: EMChatroomManagerDelegate.h:41
Definition: IEMChatroomManager.h:34