searchGroups
功能介绍
搜索群资料
- SDK 会搜索群名称包含于关键字列表 keywordList 的所有群并返回群信息列表。关键字列表最多支持5个。
参数详解
返回值
V2TimValueCallback<List<V2TimGroupInfo>>
{
code : int
desc : String
data : List<V2TimGroupInfo>
}
返回值详解
代码示例
V2TimGroupSearchParam param = V2TimGroupSearchParam(
isSearchGroupID: true,
isSearchGroupName: true,
keywordList: []);
V2TimValueCallback<List<V2TimGroupInfo>> searchGroupsRes =
await TencentImSDKPlugin.v2TIMManager
.getGroupManager()
.searchGroups(searchParam: param);
if (searchGroupsRes.code == 0) {
searchGroupsRes.data?.forEach((element) {
element.customInfo;
element.faceUrl;
element.groupAddOpt;
element.groupID;
element.groupName;
element.groupType;
element.introduction;
element.isAllMuted;
element.isSupportTopic;
element.joinTime;
element.lastInfoTime;
element.lastMessageTime;
element.memberCount;
element.notification;
element.onlineCount;
element.owner;
element.recvOpt;
element.role;
});
}