cpp-mirai-client  v2.6.1
cpp client for mirai-api-http
GroupSettings.hpp
浏览该文件的文档.
1// Copyright (C) 2022 Numendacil and contributors
2//
3// This program is free software: you can redistribute it and/or modify
4// it under the terms of the GNU Affero General Public License as
5// published by the Free Software Foundation, either version 3 of the
6// License, or (at your option) any later version.
7//
8// This program is distributed in the hope that it will be useful,
9// but WITHOUT ANY WARRANTY; without even the implied warranty of
10// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11// GNU Affero General Public License for more details.
12//
13// You should have received a copy of the GNU Affero General Public License
14// along with this program. If not, see <http://www.gnu.org/licenses/>.
15
16#ifndef MIRAI_TYPES_GROUP_SETTINGS_HPP_
17#define MIRAI_TYPES_GROUP_SETTINGS_HPP_
18#include <ctime>
19#include <string>
20
22
23
24namespace Mirai
25{
26
27/**
28 * @brief 群设置
29 *
30 * Member Variable | Default Value
31 * --------------- | -------------
32 * `GroupConfig::name` | `""`
33 * `GroupConfig::AllowConfessTalk` | `false`
34 * `GroupConfig::AllowMemberInvite` | `false`
35 * `GroupConfig::AutoApprove` | `false`
36 * `GroupConfig::AllowAnonymousChat` | `false`
37 */
39{
40 /// 群名
41 std::string name;
42 /// 是否允许坦白说
43 bool AllowConfessTalk = false;
44 /// 是否允许邀请入群
45 bool AllowMemberInvite = false;
46 /// 是否自动审批入群申请
47 bool AutoApprove = false;
48 /// 是否允许匿名聊天
49 bool AllowAnonymousChat = false;
50 /// 是否开启全员禁言
51 bool MuteAll = false;
52};
53
54/**
55 * @brief 群公告
56 *
57 * Member Variable | Default Value
58 * --------------- | -------------
59 * `GroupAnnouncement::group` | `Group{}`
60 * `GroupAnnouncement::content` | `""`
61 * `GroupAnnouncement::SenderId` | `0_qq`
62 * `GroupAnnouncement::fid` | `""`
63 * `GroupAnnouncement::AllConfirmed` | `false`
64 * `GroupAnnouncement::ConfirmedCount` | `0`
65 * `GroupAnnouncement::PublicationTime` | `0`
66 */
68{
69 /// 群聊
71 /// 公告内容
72 std::string content;
73 /// 公告发送着QQ
75 /// 公告id,唯一标识符
76 std::string fid;
77 /// 是否全员已确认
78 bool AllConfirmed = false;
79 /// 公告确认人数
81 /// 发布时间
82 std::time_t PublicationTime = 0;
83};
84
85} // namespace Mirai
86
87#endif
QQ号码类型
Definition: BasicTypes.hpp:71
所有mirai相关的对象的命名空间
QQ_t SenderId
公告发送着QQ
std::string content
公告内容
std::time_t PublicationTime
发布时间
std::string fid
公告id,唯一标识符
int ConfirmedCount
公告确认人数
bool AllConfirmed
是否全员已确认
bool AllowConfessTalk
是否允许坦白说
bool MuteAll
是否开启全员禁言
bool AllowAnonymousChat
是否允许匿名聊天
std::string name
群名
bool AllowMemberInvite
是否允许邀请入群
bool AutoApprove
是否自动审批入群申请
群聊资料
Definition: BasicTypes.hpp:333