9#import <Foundation/Foundation.h>
10#import "AgoraChatCommonDefs.h"
11#import "AgoraChatContactManagerDelegate.h"
23#pragma mark - Delegate
33 delegateQueue:(dispatch_queue_t)aQueue;
41- (void)removeDelegate:(
id _Nonnull)aDelegate;
44#pragma mark - Contact Operations
65- (void)getContactsFromServerWithCompletion:(
void (^)(NSArray<NSString *> *_Nullable aList,
AgoraChatError *aError_Nullable ))aCompletionBlock;
77- (NSArray<NSString *> *_Nullable )getContactsFromServerWithError:(
AgoraChatError **_Nullable )pError;
90- (
AgoraChatError *_Nullable )addContact:(NSString *_Nonnull)aUsername
91 message:(NSString *_Nullable )aMessage;
104- (void)addContact:(NSString *_Nonnull)aUsername
105 message:(NSString *_Nullable )aMessage
106 completion:(
void (^_Nullable )(NSString *_Nullable aUsername,
AgoraChatError *_Nullable aError))aCompletionBlock;
119- (
AgoraChatError *_Nullable )deleteContact:(NSString *_Nonnull)aUsername
120 isDeleteConversation:(BOOL)aIsDeleteConversation;
133- (void)deleteContact:(NSString *_Nonnull)aUsername
134 isDeleteConversation:(BOOL)aIsDeleteConversation
135 completion:(
void (^_Nullable )(NSString *_Nullable aUsername,
AgoraChatError *_Nullable aError))aCompletionBlock;
147- (void)approveFriendRequestFromUser:(NSString *_Nonnull)aUsername
148 completion:(
void (^_Nullable )(NSString *_Nullable aUsername,
AgoraChatError *_Nullable aError))aCompletionBlock;
160- (void)declineFriendRequestFromUser:(NSString *_Nonnull)aUsername
161 completion:(
void (^_Nullable )(NSString *aUsername,
AgoraChatError *_Nullable aError))aCompletionBlock;
164#pragma mark - Blacklist Operations
183- (void)getBlackListFromServerWithCompletion:(
void (^_Nullable )(NSArray<NSString *> *_Nullable aList,
AgoraChatError *_Nullable aError))aCompletionBlock;
195- (NSArray<NSString *> *_Nullable )getBlackListFromServerWithError:(
AgoraChatError **_Nullable )pError;
208- (
AgoraChatError *_Nullable )addUserToBlackList:(NSString *_Nonnull)aUsername;
221- (void)addUserToBlackList:(NSString *_Nonnull)aUsername
222 completion:(
void (^_Nullable )(NSString *_Nullable aUsername,
AgoraChatError *_Nullable aError))aCompletionBlock;
234- (
AgoraChatError *_Nullable )removeUserFromBlackList:(NSString *_Nonnull)aUsername;
246- (void)removeUserFromBlackList:(NSString *_Nonnull)aUsername
247 completion:(
void (^_Nullable )(NSString *_Nullable aUsername,
AgoraChatError *_Nullable aError))aCompletionBlock;
259- (
AgoraChatError *_Nullable )acceptInvitationForUsername:(NSString *_Nonnull)aUsername;
276- (
AgoraChatError *_Nullable )declineInvitationForUsername:(NSString *_Nonnull)aUsername;
278#pragma mark - Other platform
292- (NSArray<NSString *> *_Nullable )getSelfIdsOnOtherPlatformWithError:(
AgoraChatError **_Nullable )pError;
304- (void)getSelfIdsOnOtherPlatformWithCompletion:(
void (^_Nullable)(NSArray<NSString *> *_Nullable aList,
AgoraChatError *_Nullable aError))aCompletionBlock;
Definition: AgoraChatError.h:18