#import <IEMContactManager.h>
Get all the friends from the DB
- Returns
- Contact list<NSString>
Get the blacklist from the DB
- Returns
- Blacklist<NSString>
- (EMError *) acceptInvitationForUsername: |
|
(NSString *) |
aUsername |
|
|
required |
Accept a friend request
Synchronization method will block the current thread
- Parameters
-
aUsername | User who initiated the friend request |
- Returns
- Error
- (EMError *) addContact: |
|
(NSString *) |
aUsername |
message: |
|
(NSString *) |
aMessage |
|
|
| |
|
required |
Add a contact with invitation message
Synchronization method will block the current thread
- Parameters
-
aUsername | The user to add |
aMessage | Invitation message |
- Returns
- Error
- (void) addContact: |
|
(NSString *) |
aUsername |
message: |
|
(NSString *) |
aMessage |
completion: |
|
(void(^)(NSString *aUsername, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Add a contact
- Parameters
-
aUsername | The user to be added |
aMessage | Friend request message |
aCompletionBlock | The callback block of completion |
- (void) addDelegate: |
|
(3_1_0) |
|
|
|
(3_2_2) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMContactManager addDelegate:delegateQueue:] |
|
|
| |
|
required |
Add delegate
- Parameters
-
aDelegate | Delegate |
aQueue | The queue of call delegate method |
- (void) addUserToBlackList: |
|
(NSString *) |
aUsername |
completion: |
|
(void(^)(NSString *aUsername, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Add a user to blacklist
- Parameters
-
aUsername | Block user |
aCompletionBlock | The callback block of completion |
- (EMError *) addUserToBlackList: |
|
(NSString *) |
aUsername |
relationshipBoth: |
|
(BOOL) |
aBoth |
|
|
| |
|
required |
Add a user to blacklist
Synchronization method will block the current thread
- Parameters
-
aUsername | Block user |
aBoth | if aBoth is YES, then hide user and block messages from blocked user; if NO, then hide user from blocked user |
- Returns
- Error
- (void) approveFriendRequestFromUser: |
|
(NSString *) |
aUsername |
completion: |
|
(void(^)(NSString *aUsername, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Apporove a friend request
- Parameters
-
aUsername | User who initiated the friend request |
aCompletionBlock | The callback block of completion |
Agree invitation
- Parameters
-
aUsername | Applicants |
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
- (void) asyncAddContact: |
|
(NSString *) |
aUsername |
message: |
|
(NSString *) |
aMessage |
success: |
|
(void(^)()) |
aSuccessBlock |
failure: |
|
("Use -addContact:message:completion:") |
__deprecated_msg |
|
|
| |
|
required |
Add a contact
- Parameters
-
aUsername | The user to add |
aMessage | Friend invitation message |
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
- (void) asyncAddUserToBlackList: |
|
(NSString *) |
aUsername |
relationshipBoth: |
|
(BOOL) |
aBoth |
success: |
|
(void(^)()) |
aSuccessBlock |
failure: |
|
("Use -addUserToBlackList:completion:") |
__deprecated_msg |
|
|
| |
|
required |
Add user to blacklist
- Parameters
-
aUsername | The user to add |
aBoth | Whether block messages from me to the user which is added to the black list |
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
Decline invitation
- Parameters
-
aUsername | Applicants |
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
- (void) asyncDeleteContact: |
|
(NSString *) |
aUsername |
success: |
|
(void(^)()) |
aSuccessBlock |
failure: |
|
("Use -deleteContact:completion:") |
__deprecated_msg |
|
|
| |
|
required |
Delete friend
- Parameters
-
aUsername | The user to delete |
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
Get the blacklist from the server
- Parameters
-
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
Get all the friends from the server
- Parameters
-
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
Remove user from blacklist
- Parameters
-
aUsername | The user to remove from blacklist |
aSuccessBlock | The callback block of success |
aFailureBlock | The callback block of failure |
- (void) declineFriendRequestFromUser: |
|
(NSString *) |
aUsername |
completion: |
|
(void(^)(NSString *aUsername, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Decline a friend request
- Parameters
-
aUsername | User who initiated the friend request |
aCompletionBlock | The callback block of completion |
- (EMError *) declineInvitationForUsername: |
|
(NSString *) |
aUsername |
|
|
required |
Decline a friend request
Synchronization method will block the current thread
- Parameters
-
aUsername | User who initiated the friend request |
- Returns
- Error
Please use the new method
- (void)declineFriendRequestFromUser:(NSString *)aUsername completion:(void (^)(NSString *aUsername, EMError *aError))aCompletionBlock;
- (EMError *) deleteContact: |
|
("Use -deleteContact:username:isDeleteConversation:") |
__deprecated_msg |
|
|
required |
Delete a contact
Synchronization method will block the current thread
- Parameters
-
aUsername | The user to delete |
- Returns
- Error
- (void) deleteContact: |
|
(NSString *) |
aUsername |
completion: |
|
("Use -deleteContact:username:isDeleteConversation:") |
__deprecated_msg |
|
|
| |
|
required |
Delete a contact
- Parameters
-
aUsername | The user to be deleted |
aCompletionBlock | The callback block of completion |
Delete a contact
Synchronization method will block the current thread
- Parameters
-
aUsername | The user to delete |
aIsDeleteConversation | Delete the conversation or not |
- Returns
- Error
- (void) deleteContact: |
|
(NSString *) |
aUsername |
isDeleteConversation: |
|
(BOOL) |
aIsDeleteConversation |
completion: |
|
(void(^)(NSString *aUsername, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Delete a contact
- Parameters
-
aUsername | The user to be deleted |
aIsDeleteConversation | Delete the conversation or not |
aCompletionBlock | The callback block of completion |
- (NSArray *) getBlackList |
|
|
|
|
required |
Get the blacklist of blocked users
- Returns
- Blacklist<EMGroup>
- (void) getBlackListFromServerWithCompletion: |
|
(void(^)(NSArray *aList, EMError *aError)) |
aCompletionBlock |
|
|
required |
Get the blacklist from the server
- Parameters
-
aCompletionBlock | The callback block of completion |
- (NSArray *) getBlackListFromServerWithError: |
|
(EMError **) |
pError |
|
|
required |
Get the blacklist from the server
Synchronization method will block the current thread
- Parameters
-
- Returns
- Blacklist<NSString>
- (NSArray *) getContacts |
|
|
|
|
required |
Get all contacts
- Returns
- Contact list<EMGroup>
- (void) getContactsFromServerWithCompletion: |
|
(void(^)(NSArray *aList, EMError *aError)) |
aCompletionBlock |
|
|
required |
Get all contacts from the server
- Parameters
-
aCompletionBlock | The callback block of completion |
- (NSArray *) getContactsFromServerWithError: |
|
(EMError **) |
pError |
|
|
required |
Get all the contacts from the server
Synchronization method will block the current thread
- Parameters
-
- Returns
- Contact list<NSString>
- (void) removeDelegate: |
|
(id) |
aDelegate |
|
|
required |
Remove delegate
- Parameters
-
- (EMError *) removeUserFromBlackList: |
|
(NSString *) |
aUsername |
|
|
required |
Remove user out of blacklist
Synchronization method will block the current thread
- Parameters
-
- Returns
- Error
Remove a user from blacklist
- Parameters
-
aUsername | Unblock user |
aCompletionBlock | The callback block of completion |
The documentation for this protocol was generated from the following file: