7#ifndef _NIM_SDK_CPP_TEAM_H_
8#define _NIM_SDK_CPP_TEAM_H_
26class NIM_SDK_CPPWRAPPER_DLL_API
Team {
32 typedef std::function<void(
int team_count,
const std::list<nim::TeamInfo>& team_info_list)>
35 typedef std::function<void(
int count,
const std::list<nim::TeamMemberProperty>& all_my_member_info_list)>
38 typedef std::function<void(
const std::string& tid,
int member_count,
const std::list<TeamMemberProperty>& props)>
45 typedef std::function<void(
NIMResCode error_code,
const std::string& tid,
const std::list<TeamMemberProperty>& team_member_propertys)>
48 typedef std::function<void(
NIMResCode,
const std::string&,
const std::map<std::string, std::string>&)>
54 typedef std::function<void(
const std::list<std::string>& success_ids,
const std::list<std::string>& failure_ids)>
57 typedef std::function<void(
const std::string& tid,
58 const std::list<std::string>& success_ids,
59 const std::list<std::string>& failure_ids,
60 const std::list<std::string>& ignored_ids)>
61 TeamMsgAckReadCallback;
62 typedef std::function<void(
NIMResCode error_code,
const std::list<nim::TeamInfo>& team_info_list,
const std::list<std::string>& fail_list)>
71 static void RegTeamEventCb(
const TeamEventCallback& cb,
const std::string& json_extension =
"");
91 static bool CreateTeamAsync(
const TeamInfo& team_info,
92 const std::list<std::string>& ids,
93 const std::string& invitation_postscript,
95 const std::string& json_extension =
"");
116 static bool InviteAsync(
const std::string& tid,
117 const std::list<std::string>& ids,
118 const std::string& invitation_postscript,
120 const std::string& json_extension =
"");
143 static bool InviteAsync2(
const std::string& tid,
144 const std::list<std::string>& ids,
145 const std::string& invitation_postscript,
146 const std::string& invitation_attachment,
148 const std::string& json_extension =
"");
167 static bool KickAsync(
const std::string& tid,
168 const std::list<std::string>& ids,
170 const std::string& json_extension =
"");
182 static bool LeaveAsync(
const std::string& tid,
const TeamEventCallback& cb,
const std::string& json_extension =
"");
194 static bool DismissAsync(
const std::string& tid,
const TeamEventCallback& cb,
const std::string& json_extension =
"");
210 static bool UpdateTeamInfoAsync(
const std::string& tid,
213 const std::string& json_extension =
"");
233 static bool ApplyJoinAsync(
const std::string& tid,
234 const std::string& reason,
236 const std::string& json_extension =
"");
256 static bool PassJoinApplyAsync(
const std::string& tid,
257 const std::string& applicant_id,
259 const std::string& json_extension =
"");
279 static bool RejectJoinApplyAsync(
const std::string& tid,
280 const std::string& applicant_id,
281 const std::string& reason,
283 const std::string& json_extension =
"");
300 static bool AddManagersAsync(
const std::string& tid,
301 const std::list<std::string>& ids,
303 const std::string& json_extension =
"");
320 static bool RemoveManagersAsync(
const std::string& tid,
321 const std::list<std::string>& ids,
323 const std::string& json_extension =
"");
343 static bool TransferTeamAsync(
const std::string& tid,
344 const std::string& new_owner_id,
347 const std::string& json_extension =
"");
391 static bool AcceptInvitationAsync(
const std::string& tid,
392 const std::string& invitor_id,
394 const std::string& json_extension =
"");
413 static bool RejectInvitationAsync(
const std::string& tid,
414 const std::string& invitor_id,
415 const std::string& reason,
417 const std::string& json_extension =
"");
453 static bool QueryTeamMembersAsync(
const std::string& tid,
const QueryTeamMembersCallback& cb,
const std::string& json_extension =
"");
466 static bool QueryTeamMemberAsync(
const std::string& tid,
467 const std::string&
id,
469 const std::string& json_extension =
"");
477 static TeamMemberProperty QueryTeamMemberBlock(
const std::string& tid,
const std::string&
id);
486 static bool QueryTeamInfoAsync(
const std::string& tid,
const QueryTeamInfoCallback& cb,
const std::string& json_extension =
"");
493 static TeamInfo QueryTeamInfoBlock(
const std::string& tid);
504 static bool QueryTeamInfoOnlineAsync(
const std::string& tid,
const TeamEventCallback& cb,
const std::string& json_extension =
"");
512 static bool ParseTeamInfo(
const std::string& json_team_info,
TeamInfo& team_info);
518 static void UnregTeamCb();
538 static bool MuteMemberAsync(
const std::string& tid,
539 const std::string& member_id,
542 const std::string& json_extension =
"");
566 static bool MuteAsync(
const std::string& tid,
bool set_mute,
const TeamEventCallback& cb,
const std::string& json_extension =
"");
581 static void TeamMsgAckRead(
const std::string& tid,
582 const std::list<IMMessage>& msgs,
584 const std::string& json_extension =
"");
599 static void TeamMsgAckReadEx(
const std::string& tid,
600 const std::list<IMMessage>& msgs,
601 const TeamMsgAckReadCallback& cb,
602 const std::string& json_extension =
"");
617 static void TeamMsgQueryUnreadList(
const std::string& tid,
620 const std::string& json_extension =
"");
637 static void TeamMsgQueryUnreadList(
const std::string& tid,
639 const std::list<std::string>& accids,
641 const std::string& json_extension =
"");
662 static bool QueryTeamInfoByKeywordAsync(
const std::string& keyword,
const QueryTeamsInfoCallback& cb,
const std::string& json_extension =
"");
676 static void UpdateTInfoLocal(
const std::list<TeamInfo>& team_infos,
const UpdateTInfoLocalCallback& cb,
const std::string& json_extension =
"");
群组功能;主要包括查询群信息、查询群成员信息、加人、踢人等功能
Definition: nim_cpp_team.h:26
std::function< void(const std::string &tid, int member_count, const std::list< TeamMemberProperty > &props)> QueryTeamMembersCallback
查询指定群组全部成员信息回调模板
Definition: nim_cpp_team.h:40
QueryAllMyTeamsInfoCallback GetTeamInfoBatchSFTransCallback
查询所有群信息回调模板 顺丰专用
Definition: nim_cpp_team.h:53
std::function< void(int team_count, const std::list< std::string > &team_id_list)> QueryAllMyTeamsCallback
查询本人所有群ID回调模板
Definition: nim_cpp_team.h:31
std::function< void(const TeamEvent &team_event)> TeamEventCallback
群组事件通知回调模板
Definition: nim_cpp_team.h:29
std::function< void(const TeamMemberProperty &team_member_property)> QueryTeamMemberCallback
查询指定群成员信息回调模板
Definition: nim_cpp_team.h:42
std::function< void(NIMResCode, const std::string &, const std::map< std::string, std::string > &)> QueryTeamMembersInvitorCallback
查询群成员邀请人accid 列表回调模板
Definition: nim_cpp_team.h:50
std::function< void(const std::list< std::string > &success_ids, const std::list< std::string > &failure_ids)> UpdateTInfoLocalCallback
更新本地缓存回调模板顺丰专用
Definition: nim_cpp_team.h:56
std::function< void(const std::string &tid, const TeamInfo &result)> QueryTeamInfoCallback
查询指定群信息回调模板
Definition: nim_cpp_team.h:44
std::function< void(NIMResCode error_code, const std::list< nim::TeamInfo > &team_info_list, const std::list< std::string > &fail_list)> GetTeamInfoListCallback
查询给定的一组群ID详细信息的回调模板
Definition: nim_cpp_team.h:64
std::function< void(NIMResCode error_code, const std::string &tid, const std::list< TeamMemberProperty > &team_member_propertys)> QueryTeamMembersOnlineCallback
查询群成员信息回调模板
Definition: nim_cpp_team.h:47
std::function< void(int team_count, const std::list< nim::TeamInfo > &team_info_list)> QueryAllMyTeamsInfoCallback
查询本人所有群信息回调模板
Definition: nim_cpp_team.h:34
std::function< void(int count, const std::list< nim::TeamMemberProperty > &all_my_member_info_list)> QueryMyAllMemberInfosCallback
查询本人所有群里我的成员信息回调模板
Definition: nim_cpp_team.h:37
NIMResCode
Definition: nim_chatroom_res_code_def.h:15
Definition: nim_talk_helper.h:281
群组事件通知
Definition: nim_team_helper.h:379
群组信息
Definition: nim_team_helper.h:24
群组成员信息
Definition: nim_team_helper.h:282