Class GroupOperationsHandler
-
- All Implemented Interfaces:
public class GroupOperationsHandler extends MultiDataHandler
Group operations handler.
Note: Call stop to release resources when done.
- Since:
5.12.0
-
-
Field Summary
-
Constructor Summary
Constructors Constructor Description GroupOperationsHandler(ChannelIdentifier channelIdentifier)Constructor that initializes the group ID.
-
Method Summary
Modifier and Type Method Description voidcreateGroup(GroupInfo groupInfo, List<String> inviteeUserIds)voidcreateGroupExamine(GroupInfo groupInfo, List<String> inviteeUserIds)voidinviteUsersToGroup(@NonNull() List<String> userIds)Invites users to join the group. voidkickGroupMembers(List<String> userIds, LeaveGroupConfig config)Kicks members from the group. voidupdateGroupInfo(@NonNull() GroupInfo groupInfo)Updates the group info. voidupdateGroupInfoExamine(@NonNull() GroupInfo groupInfo)Updates the group info with review. voidsetGroupMemberInfo(String userId, String nickname, String extra)Sets group member info. voidsetGroupMemberInfoExamine(String userId, String nickname, String extra)Sets group member info with review. voidquitGroup(LeaveGroupConfig config)Quits the group. voiddismissGroup()Dismisses the group. voidaddGroupFollows(List<String> userIds)Adds favorited group members. voidremoveGroupFollows(List<String> userIds)Removes favorited group members. voidtransferGroupOwner(String newOwnerId, boolean quitGroup, LeaveGroupConfig config)Transfers group ownership. voidaddGroupManagers(List<String> userIds)Adds group managers. voidremoveGroupManagers(List<String> userIds)Removes group managers. voidjoinGroup()Joins the group. -
Methods inherited from class ai.nexconn.chatui.base.BaseHandler
isAlive -
Methods inherited from class ai.nexconn.chatui.base.MultiDataHandler
addDataChangeListener, notifyDataChange, notifyDataError, notifyDataError, replaceDataChangeListener, stop -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
createGroup
@Deprecated() void createGroup(GroupInfo groupInfo, List<String> inviteeUserIds)
-
createGroupExamine
void createGroupExamine(GroupInfo groupInfo, List<String> inviteeUserIds)
-
inviteUsersToGroup
void inviteUsersToGroup(@NonNull() List<String> userIds)
Invites users to join the group.
- Parameters:
userIds- the list of user IDs
-
kickGroupMembers
void kickGroupMembers(List<String> userIds, LeaveGroupConfig config)
Kicks members from the group.
- Parameters:
userIds- the list of user IDsconfig- the leave group configuration
-
updateGroupInfo
@Deprecated() void updateGroupInfo(@NonNull() GroupInfo groupInfo)
Updates the group info.
- Parameters:
groupInfo- the group info
-
updateGroupInfoExamine
void updateGroupInfoExamine(@NonNull() GroupInfo groupInfo)
Updates the group info with review.
- Parameters:
groupInfo- the group info
-
setGroupMemberInfo
@Deprecated() void setGroupMemberInfo(String userId, String nickname, String extra)
Sets group member info.
- Parameters:
userId- the user IDnickname- the nicknameextra- the extra information
-
setGroupMemberInfoExamine
void setGroupMemberInfoExamine(String userId, String nickname, String extra)
Sets group member info with review.
- Parameters:
userId- the user IDnickname- the nicknameextra- the extra information
-
quitGroup
void quitGroup(LeaveGroupConfig config)
Quits the group.
- Parameters:
config- the leave group configuration
-
dismissGroup
void dismissGroup()
Dismisses the group.
-
addGroupFollows
void addGroupFollows(List<String> userIds)
Adds favorited group members.
- Parameters:
userIds- the list of user IDs- Since:
5.12.2
-
removeGroupFollows
void removeGroupFollows(List<String> userIds)
Removes favorited group members.
- Parameters:
userIds- the list of user IDs- Since:
5.12.2
-
transferGroupOwner
void transferGroupOwner(String newOwnerId, boolean quitGroup, LeaveGroupConfig config)
Transfers group ownership.
- Parameters:
newOwnerId- the new owner's user IDquitGroup- whether to quit the group after transferconfig- the leave group configuration- Since:
5.12.2
-
addGroupManagers
void addGroupManagers(List<String> userIds)
Adds group managers.
- Parameters:
userIds- the list of user IDs- Since:
5.12.2
-
removeGroupManagers
void removeGroupManagers(List<String> userIds)
Removes group managers.
- Parameters:
userIds- the list of user IDs- Since:
5.12.2
-
joinGroup
void joinGroup()
Joins the group.
The join permission determines whether the user can join directly. When the group requires approval, the NC_GROUP_JOIN_GROUP_NEED_MANAGER_ACCEPT status code is returned, indicating the user needs to wait for the owner or manager to approve.
- Since:
5.34.0
-
-
-
-