#import <IEMGroupManager.h>
IEMGroupManager.h This protocol defines the group operations
- Author
- Hyphenate
- Version
- 3.00
Group operations
Get all groups, will load from DB if not exist in memory
- Returns
- Group list<EMGroup>
Load all groups from DB, will update group list in memory after loading
- Returns
- Group list<EMGroup>
| - ("Use -getGroupsWithoutPushNotification") __deprecated_msg |
|
|
|
|
required |
Get ID list of groups which block push from memory
- Returns
- Group id list<NSString>
| - (void) acceptInvitationFromGroup: |
|
(NSString *) |
aGroupId |
| inviter: |
|
(NSString *) |
aUsername |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Accept a group invitation
- Parameters
-
| groupId | Group id |
| aUsername | Inviter |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) acceptInvitationFromGroup: |
|
(NSString *) |
aGroupId |
| inviter: |
|
(NSString *) |
aUsername |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Accept a group invitation
Synchronization method will block the current thread
- Parameters
-
| groupId | Group id |
| aUsername | Inviter |
| pError | Error |
- Returns
- Joined group instance
| - (EMError *) acceptJoinApplication: |
|
(NSString *) |
aGroupId |
| applicant: |
|
(NSString *) |
aUsername |
|
|
| |
|
required |
Accept a group request, owner‘s authority is required
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| aUsername | The applicant |
- Returns
- Error
| - (void) addAdmin: |
|
(NSString *) |
aAdmin |
| toGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Add group admin, need Owner permissions
- Parameters
-
| aAdmin | Admin |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) addAdmin: |
|
(NSString *) |
aAdmin |
| toGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Add group admin, need Owner permissions
Synchronization method will block the current thread
- Parameters
-
| aAdmin | Admin |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) addDelegate: |
|
(3_1_0) |
|
|
|
(3_2_2) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager addDelegate:delegateQueue:] |
|
|
| |
|
required |
Add delegate
- Parameters
-
| aDelegate | Delegate |
| aQueue | The queue of call delegate method |
| - (void) addMembers: |
|
(NSArray *) |
aUsers |
| toGroup: |
|
(NSString *) |
aGroupId |
| message: |
|
(NSString *) |
aMessage |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Invite User to join a group
- Parameters
-
| aUsers | Invited users |
| aGroupId | Group id |
| aMessage | Welcome message |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) addOccupants: |
|
(NSArray *) |
aOccupants |
| toGroup: |
|
(NSString *) |
aGroupId |
| welcomeMessage: |
|
(NSString *) |
aWelcomeMessage |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Invite User to join a group
Synchronization method will block the current thread
- Parameters
-
| aOccupants | Invited users |
| aGroupId | Group id |
| aWelcomeMessage | Welcome message |
| pError | Error |
- Returns
- Group instance, return nil if fail
| - (EMGroup *) applyJoinPublicGroup: |
|
(NSString *) |
aGroupId |
| message: |
|
(NSString *) |
aMessage |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Request to join a public group, group style should be EMGroupStylePublicJoinNeedApproval
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Public group id |
| aMessage | Request info |
| pError | Error |
- Returns
- Group instance
| - (void) approveJoinGroupRequest: |
|
(NSString *) |
aGroupId |
| sender: |
|
(NSString *) |
aUsername |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Approve a group request, owner‘s authority is required
- Parameters
-
| aGroupId | Group id |
| aUsername | Group request sender |
| aCompletionBlock | The callback block of completion |
| - (void) asyncAcceptInvitationFromGroup: |
|
(NSString *) |
aGroupId |
| inviter: |
|
(NSString *) |
aUsername |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -acceptInvitationFromGroup:inviter:completion") |
__deprecated_msg |
|
|
| |
|
required |
Accept group's invitation
- Parameters
-
| groupId | Group id |
| aUsername | Inviter |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Accept user's application, need owner‘s authority
- Parameters
-
| aGroupId | Group id |
| aUsername | The applicant |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncAddOccupants: |
|
(NSArray *) |
aOccupants |
| toGroup: |
|
(NSString *) |
aGroupId |
| welcomeMessage: |
|
(NSString *) |
aWelcomeMessage |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -addMembers:toGroup:message:completion:") |
__deprecated_msg |
|
|
| |
|
required |
Invite User to join a group
- Parameters
-
| aOccupants | Invited users |
| aGroupId | Group id |
| aWelcomeMessage | Welcome message |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Apply to join a public group, group style should be EMGroupStylePublicJoinNeedApproval
- Parameters
-
| aGroupId | Public group id |
| aMessage | Apply info |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncBlockGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -blockGroup:completion:") |
__deprecated_msg |
|
|
| |
|
required |
Block group’s message, server will blocks the messages of the group to user, owner can't block the group's message
- Parameters
-
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncBlockOccupants: |
|
(NSArray *) |
aOccupants |
| fromGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -blockMembers:fromGroup:completion:") |
__deprecated_msg |
|
|
| |
|
required |
Add users to group’s blacklist, need owner‘s authority
- Parameters
-
| aOccupants | Users to be added |
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncChangeDescription: |
|
(NSString *) |
aDescription |
| forGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -updateDescription:forGroup:completion") |
__deprecated_msg |
|
|
| |
|
required |
Change group’s description, need owner‘s authority
- Parameters
-
| aDescription | New group‘s description |
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncChangeGroupSubject: |
|
(NSString *) |
aSubject |
| forGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -updateGroupSubject:forGroup:completion") |
__deprecated_msg |
|
|
| |
|
required |
Change group’s subject, need owner‘s authority
- Parameters
-
| aSubject | New group‘s subject |
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncCreateGroupWithSubject: |
|
(NSString *) |
aSubject |
| description: |
|
(NSString *) |
aDescription |
| invitees: |
|
(NSArray *) |
aInvitees |
| message: |
|
(NSString *) |
aMessage |
| setting: |
|
(EMGroupOptions *) |
aSetting |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -createGroupWithSubject:description:invitees:message:setting:completion") |
__deprecated_msg |
|
|
| |
|
required |
Create a group
- Parameters
-
| aSubject | Group subject |
| aDescription | Group description |
| aInvitees | Group members, without creater |
| aMessage | Invitation message |
| aSetting | Group options |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Decline a group invitation
- Parameters
-
| aGroupId | Group id |
| aUsername | Inviter |
| aReason | Decline reason |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Decline user's application, need owner‘s authority
- Parameters
-
| aGroupId | Group id |
| aUsername | The applicant |
| aReason | Decline reason |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncDestroyGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -destroyGroup:completion") |
__deprecated_msg |
|
|
| |
|
required |
Destroy a group, need owner‘s authority
- Parameters
-
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Get group‘s blacklist, need owner’s authority
- Parameters
-
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Fetch group info
- Parameters
-
| aGroupId | Group id |
| aIncludeMembersList | Whether get member list |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Get all of user's groups from server, will update group list in memory and DB after success
- Parameters
-
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Get public groups in the specified range from the server
- Parameters
-
| aCursor | Cursor, input nil the first time |
| aPageSize | Expect result count, will return all results if < 0 |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Block / unblock group message‘s push notification
- Parameters
-
| aGroupId | Group id |
| aIgnore | Whether block |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncJoinPublicGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -joinPublicGroup:completion") |
__deprecated_msg |
|
|
| |
|
required |
Join a public group, group style should be EMGroupStylePublicOpenJoin
- Parameters
-
| aGroupId | Public group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncLeaveGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -leaveGroup:completion") |
__deprecated_msg |
|
|
| |
|
required |
Leave a group, owner can't leave the group, can only destroy the group
- Parameters
-
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Remove members from group, need owner‘s authority
- Parameters
-
| aOccupants | Users to be removed |
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Search public group with the id
- Parameters
-
| aGroundId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) asyncUnblockGroup: |
|
(NSString *) |
aGroupId |
| success: |
|
(void(^)(EMGroup *aGroup)) |
aSuccessBlock |
| failure: |
|
("Use -unblockGroup:completion") |
__deprecated_msg |
|
|
| |
|
required |
Unblock group message
- Parameters
-
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
Remove users from group‘s blacklist, need owner‘s authority
- Parameters
-
| aOccupants | Users to be removed |
| aGroupId | Group id |
| aSuccessBlock | The callback block of success |
| aFailureBlock | The callback block of failure |
| - (void) blockGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Block group messages, server blocks the messages from the group, owner can't block the group's messages
- Parameters
-
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) blockGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Block group messages, server will blocks the messages from the group, owner can't block the group's message
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) blockMembers: |
|
(NSArray *) |
aMembers |
| fromGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Add users to group blacklist, owner‘s authority is required
- Parameters
-
| aMembers | Users to be added |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) blockOccupants: |
|
(NSArray *) |
aOccupants |
| fromGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Add users to group blacklist, required owner‘s authority
Synchronization method will block the current thread
- Parameters
-
| aOccupants | Users to be added |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (EMGroup *) changeDescription: |
|
(NSString *) |
aDescription |
| forGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Change group description, owner‘s authority is required
Synchronization method will block the current thread
- Parameters
-
| aDescription | New group description |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group
| - (EMGroup *) changeGroupSubject: |
|
(NSString *) |
aSubject |
| forGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Change group subject, owner‘s authority is required
Synchronization method will block the current thread
- Parameters
-
| aSubject | New group subject |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) createGroupWithSubject: |
|
(NSString *) |
aSubject |
| description: |
|
(NSString *) |
aDescription |
| invitees: |
|
(NSArray *) |
aInvitees |
| message: |
|
(NSString *) |
aMessage |
| setting: |
|
(EMGroupOptions *) |
aSetting |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Create a group
- Parameters
-
| aSubject | Group subject |
| aDescription | Group description |
| aInvitees | Group members, without creater |
| aMessage | Invitation message |
| aSetting | Group options |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) createGroupWithSubject: |
|
(NSString *) |
aSubject |
| description: |
|
(NSString *) |
aDescription |
| invitees: |
|
(NSArray *) |
aInvitees |
| message: |
|
(NSString *) |
aMessage |
| setting: |
|
(EMGroupOptions *) |
aSetting |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Create a group
Synchronization method will block the current thread
- Parameters
-
| aSubject | Group subject |
| aDescription | Group description |
| aInvitees | Group members, without creater |
| aMessage | Invitation message |
| aSetting | Group options |
| pError | Error |
- Returns
- Created group
| - (void) declineGroupInvitation: |
|
(NSString *) |
aGroupId |
| inviter: |
|
(NSString *) |
aInviter |
| reason: |
|
(NSString *) |
aReason |
| completion: |
|
(void(^)(EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Decline a group invitation
- Parameters
-
| aGroupId | Group id |
| aInviter | Inviter |
| aReason | Decline reason |
| aCompletionBlock | The callback block of completion |
| - (EMError *) declineInvitationFromGroup: |
|
(NSString *) |
aGroupId |
| inviter: |
|
(NSString *) |
aUsername |
| reason: |
|
(NSString *) |
aReason |
|
|
| |
|
required |
Decline a group invitation
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| aUsername | Inviter |
| aReason | Decline reason |
- Returns
- Error
| - (EMError *) declineJoinApplication: |
|
(NSString *) |
aGroupId |
| applicant: |
|
(NSString *) |
aUsername |
| reason: |
|
(NSString *) |
aReason |
|
|
| |
|
required |
Decline a group request, owner‘s authority is required
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| aUsername | Group request sender |
| aReason | Decline reason |
- Returns
- Error
| - (void) declineJoinGroupRequest: |
|
(NSString *) |
aGroupId |
| sender: |
|
(NSString *) |
aUsername |
| reason: |
|
(NSString *) |
aReason |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Decline a group request, owner‘s authority is required
- Parameters
-
| aGroupId | Group id |
| aUsername | Group request sender |
| aReason | Decline reason |
| aCompletionBlock | The callback block of completion |
| - (EMError *) destroyGroup: |
|
(NSString *) |
aGroupId |
|
|
required |
Destroy a group, owner‘s authority is required
Synchronization method will block the current thread
- Parameters
-
- Returns
- Error, return nil if success
| - (void) destroyGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager destroyGroup:finishCompletion:] |
|
|
| |
|
required |
Destroy a group, owner‘s authority is required
- Parameters
-
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) destroyGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager destroyGroup:] |
|
|
| |
|
required |
Destroy a group, owner‘s authority is required
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| pError | Error |
- Returns
- Destroyed group, return nil if failed
| - (void) destroyGroup: |
|
(NSString *) |
aGroupId |
| finishCompletion: |
|
(void(^)(EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Destroy a group, owner‘s authority is required
- Parameters
-
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (NSArray *) fetchGroupBansList: |
|
(NSString *) |
aGroupId |
| error: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager getGroupBlacklistFromServerWithId:pageNumber:pageSize:error:] |
|
|
| |
|
required |
Get group‘s blacklist, required owner’s authority
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| pError | Error |
- Returns
- Group blacklist<NSString>
| - (EMGroup *) fetchGroupInfo: |
|
(NSString *) |
aGroupId |
| includeMembersList: |
|
(BOOL) |
aIncludeMembersList |
| error: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager getGroupSpecificationFromServerWithId:error:] |
|
|
| |
|
required |
Fetch group info
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| aIncludeMembersList | Whether to get member list,When YES, returns 200 members |
| pError | Error |
- Returns
- Group instance
| - (void) getGroupBlackListFromServerByID: |
|
(NSString *) |
aGroupId |
| completion: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager getGroupBlacklistFromServerWithId:pageNumber:pageSize:completion:] |
|
|
| |
|
required |
Get group's blacklist, owner’s authority is required
- Parameters
-
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (void) getGroupBlacklistFromServerWithId: |
|
(NSString *) |
aGroupId |
| pageNumber: |
|
(NSInteger) |
aPageNum |
| pageSize: |
|
(NSInteger) |
aPageSize |
| completion: |
|
(void(^)(NSArray *aList, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Get group's blacklist, need owner / admin permissions
- Parameters
-
| aGroupId | Group id |
| aPageNum | Page number |
| aPageSize | Page size |
| aCompletionBlock | The callback block of completion |
| - (NSArray *) getGroupBlacklistFromServerWithId: |
|
(NSString *) |
aGroupId |
| pageNumber: |
|
(NSInteger) |
aPageNum |
| pageSize: |
|
(NSInteger) |
aPageSize |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Get the blacklist of group from the server, need owner / admin permissions
- Parameters
-
| aGroupId | Group id |
| aPageNum | Page number |
| aPageSize | Page size |
| pError | Error |
| - (void) getGroupMemberListFromServerWithId: |
|
(NSString *) |
aGroupId |
| cursor: |
|
(NSString *) |
aCursor |
| pageSize: |
|
(NSInteger) |
aPageSize |
| completion: |
|
(void(^)(EMCursorResult *aResult, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Get the list of group members from the server
- Parameters
-
| aGroupId | Group id |
| aCursor | Cursor, input nil the first time |
| aPageSize | Page size |
| aCompletionBlock | The callback block of completion |
| - (EMCursorResult *) getGroupMemberListFromServerWithId: |
|
(NSString *) |
aGroupId |
| cursor: |
|
(NSString *) |
aCursor |
| pageSize: |
|
(NSInteger) |
aPageSize |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Get the list of group members from the server
- Parameters
-
| aGroupId | Group id |
| aCursor | Cursor, input nil the first time |
| aPageSize | Page size |
| pError | Error |
- Returns
- List and cursor
| - (void) getGroupMuteListFromServerWithId: |
|
(NSString *) |
aGroupId |
| pageNumber: |
|
(NSInteger) |
aPageNum |
| pageSize: |
|
(NSInteger) |
aPageSize |
| completion: |
|
(void(^)(NSArray *aList, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Get the mutes of group from the server
- Parameters
-
| aGroupId | Group id |
| aPageNum | Page number |
| aPageSize | Page size |
| aCompletionBlock | The callback block of completion |
| - (NSArray *) getGroupMuteListFromServerWithId: |
|
(NSString *) |
aGroupId |
| pageNumber: |
|
(NSInteger) |
aPageNum |
| pageSize: |
|
(NSInteger) |
aPageSize |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Get the mutes of group from the server
- Parameters
-
| aGroupId | Group id |
| aPageNum | Page number |
| aPageSize | Page size |
| pError | Error |
| - (void) getGroupSpecificationFromServerByID: |
|
(NSString *) |
aGroupID |
| includeMembersList: |
|
(BOOL) |
aIncludeMembersList |
| completion: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager getGroupSpecificationFromServerWithId:completion:] |
|
|
| |
|
required |
Fetch group specification
- Parameters
-
| aGroupId | Group id |
| aIncludeMembersList | Whether to get member list,When YES, returns 200 members |
| aCompletionBlock | The callback block of completion |
| - (void) getGroupSpecificationFromServerWithId: |
|
(NSString *) |
aGroupID |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Fetch group specification,include ID, name, description,setting, owner, admins
- Parameters
-
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) getGroupSpecificationFromServerWithId: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Fetch group info,include ID, name, description,setting, owner, admins
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (NSArray *) getGroupsWithoutPushNotification: |
|
(EMError **) |
pError |
|
|
required |
Get the list of groups which have disabled Apple Push Notification Service
- Parameters
-
| - (NSArray *) getJoinedGroups |
|
|
|
|
required |
Get all groups
- Returns
- Group list<EMGroup>
| - (void) getJoinedGroupsFromServerWithCompletion: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager getJoinedGroupsFromServerWithPage:pageSize:completion:] |
|
|
| |
|
required |
Get all of user's groups from server
- Parameters
-
| aCompletionBlock | The callback block of completion |
| - (void) getJoinedGroupsFromServerWithPage: |
|
(NSInteger) |
aPageNum |
| pageSize: |
|
(NSInteger) |
aPageSize |
| completion: |
|
(void(^)(NSArray *aList, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Get all the groups from server
- Parameters
-
| aPageNum | Page number |
| aPageSize | Page size |
| aCompletionBlock | The callback block of completion |
| - (NSArray *) getJoinedGroupsFromServerWithPage: |
|
(NSInteger) |
aPageNum |
| pageSize: |
|
(NSInteger) |
aPageSize |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Get pagesize number group from server.
Synchronization method will block the current thread
- Parameters
-
| aPageNum | Page number |
| aPageSize | Page size |
| pError | Error |
- Returns
- Group list<EMGroup>
| - (NSArray *) getMyGroupsFromServerWithError: |
|
(3_1_0) |
|
|
|
(3_3_0) |
|
|
|
("Use -") |
EM_DEPRECATED_IOS[IEMGroupManager getJoinedGroupsFromServerWithPage:pageSize:error:] |
|
|
| |
|
required |
Get all of user's groups from server
Synchronization method will block the current thread
- Parameters
-
- Returns
- Group list<EMGroup>
| - (void) getPublicGroupsFromServerWithCursor: |
|
(NSString *) |
aCursor |
| pageSize: |
|
(NSInteger) |
aPageSize |
| completion: |
|
(void(^)(EMCursorResult *aResult, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Get public groups with the specified range from the server
- Parameters
-
| aCursor | Cursor, input nil the first time |
| aPageSize | Expect result count, return all results if count is less than zero |
| aCompletionBlock | The callback block of completion |
| - (EMCursorResult *) getPublicGroupsFromServerWithCursor: |
|
(NSString *) |
aCursor |
| pageSize: |
|
(NSInteger) |
aPageSize |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Get public groups with the specified range from the server
Synchronization method will block the current thread
- Parameters
-
| aCursor | Cursor, input nil the first time |
| aPageSize | Expect result count, return all results if count is less than zero |
| pError | Error |
- Returns
- The result
| - (EMError *) ignoreGroupPush: |
|
(NSString *) |
aGroupId |
| ignore: |
|
(BOOL) |
aIsIgnore |
|
|
| |
|
required |
Block / unblock group message‘s push notification
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| aIgnore | Whether block |
- Returns
- Error
| - (void) joinPublicGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Join a public group, group style should be EMGroupStylePublicOpenJoin
- Parameters
-
| aGroupId | Public group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) joinPublicGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Join a public group, group style should be EMGroupStylePublicOpenJoin
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Public group id |
| pError | Error |
- Returns
- Joined public group
| - (void) leaveGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Leave a group, owner can't leave the group, can only destroy the group
- Parameters
-
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (void) leaveGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Leave a group, owner can't leave the group, can only destroy the group
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| pError | Error |
| - (void) muteMembers: |
|
(NSArray *) |
aMuteMembers |
| muteMilliseconds: |
|
(NSInteger) |
aMuteMilliseconds |
| fromGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Mute group members, need Owner / Admin permissions
Synchronization method will block the current thread
- Parameters
-
| aMuteMembers | The list of mute, type is <NSString> |
| aMuteMilliseconds | Muted time duration in millisecond |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) muteMembers: |
|
(NSArray *) |
aMuteMembers |
| muteMilliseconds: |
|
(NSInteger) |
aMuteMilliseconds |
| fromGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Mute group members, need Owner / Admin permissions
Synchronization method will block the current thread
- Parameters
-
| aMuteMembers | The list of mute, type is <NSString> |
| aMuteMilliseconds | Muted time duration in millisecond |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) removeAdmin: |
|
(NSString *) |
aAdmin |
| fromGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Remove group admin, need Owner permissions
- Parameters
-
| aAdmin | Admin |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) removeAdmin: |
|
(NSString *) |
aAdmin |
| fromGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Remove group admin, need Owner permissions
Synchronization method will block the current thread
- Parameters
-
| aAdmin | Admin |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) removeDelegate: |
|
(id) |
aDelegate |
|
|
required |
Remove delegate
- Parameters
-
| - (void) removeMembers: |
|
(NSArray *) |
aUsers |
| fromGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Remove members from a group, owner‘s authority is required
- Parameters
-
| aUsers | Users to be removed |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) removeOccupants: |
|
(NSArray *) |
aOccupants |
| fromGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Remove members from a group, required owner‘s authority
Synchronization method will block the current thread
- Parameters
-
| aOccupants | Users to be removed |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) requestToJoinPublicGroup: |
|
(NSString *) |
aGroupId |
| message: |
|
(NSString *) |
aMessage |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Request to join a public group, group style should be EMGroupStylePublicJoinNeedApproval
- Parameters
-
| aGroupId | Public group id |
| aMessage | Apply info |
| aCompletionBlock | The callback block of completion |
| - (void) searchPublicGroupWithId: |
|
(NSString *) |
aGroundId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Search public group with group id
- Parameters
-
| aGroundId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) searchPublicGroupWithId: |
|
(NSString *) |
aGroundId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Search a public group with the id
Synchronization method will block the current thread
- Parameters
-
| aGroundId | Group id |
| pError | Error |
- Returns
- The group with the id
| - (void) unblockGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Unblock group message
- Parameters
-
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) unblockGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Unblock group messages
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) unblockMembers: |
|
(NSArray *) |
aMembers |
| fromGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Remove users out of group blacklist, owner‘s authority is required
- Parameters
-
| aMembers | Users to be removed |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) unblockOccupants: |
|
(NSArray *) |
aOccupants |
| forGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Remove users from group blacklist, required owner‘s authority
Synchronization method will block the current thread
- Parameters
-
| aOccupants | Users to be removed |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) unmuteMembers: |
|
(NSArray *) |
aMembers |
| fromGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Unmute group members, need Owner / Admin permissions
Synchronization method will block the current thread
- Parameters
-
| aMembers | The list of unmute, type is <NSString> |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) unmuteMembers: |
|
(NSArray *) |
aMembers |
| fromGroup: |
|
(NSString *) |
aGroupId |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Unmute group members, need Owner / Admin permissions
Synchronization method will block the current thread
- Parameters
-
| aMembers | The list of unmute, type is <NSString> |
| aGroupId | Group id |
| pError | Error |
- Returns
- Group instance
| - (void) updateDescription: |
|
(NSString *) |
aDescription |
| forGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Change the group description, owner‘s authority is required
- Parameters
-
| aDescription | New group‘s description |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (void) updateGroupOwner: |
|
(NSString *) |
aGroupId |
| newOwner: |
|
(NSString *) |
aNewOwner |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Change group owner, need Owner permissions
- Parameters
-
| aGroupId | Group id |
| aNewOwner | New group owner |
| aCompletionBlock | The callback block of completion |
| - (EMGroup *) updateGroupOwner: |
|
(NSString *) |
aGroupId |
| newOwner: |
|
(NSString *) |
aNewOwner |
| error: |
|
(EMError **) |
pError |
|
|
| |
|
required |
Change group owner, need Owner permissions
Synchronization method will block the current thread
- Parameters
-
| aGroupId | Group id |
| aNewOwner | New group owner |
| pError | Error |
- Returns
- Group instance
| - (void) updateGroupSubject: |
|
(NSString *) |
aSubject |
| forGroup: |
|
(NSString *) |
aGroupId |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Change the group subject, owner‘s authority is required
- Parameters
-
| aSubject | New group‘s subject |
| aGroupId | Group id |
| aCompletionBlock | The callback block of completion |
| - (void) updatePushServiceForGroup: |
|
(NSString *) |
aGroupID |
| isPushEnabled: |
|
(BOOL) |
aIsEnable |
| completion: |
|
(void(^)(EMGroup *aGroup, EMError *aError)) |
aCompletionBlock |
|
|
| |
|
required |
Block / unblock group message‘s push notification
- Parameters
-
| aGroupId | Group id |
| aIsEnable | Whether enable |
| aCompletionBlock | The callback block of completion |
The documentation for this protocol was generated from the following file: