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
21
#include <
libmirai/Types/BasicTypes.hpp
>
22
23
24
namespace
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
*/
38
struct
GroupConfig
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
*/
67
struct
GroupAnnouncement
68
{
69
/// 群聊
70
Group
group
;
71
/// 公告内容
72
std::string
content
;
73
/// 公告发送着QQ
74
QQ_t
SenderId
;
75
/// 公告id,唯一标识符
76
std::string
fid
;
77
/// 是否全员已确认
78
bool
AllConfirmed
=
false
;
79
/// 公告确认人数
80
int
ConfirmedCount
= 0;
81
/// 发布时间
82
std::time_t
PublicationTime
= 0;
83
};
84
85
}
// namespace Mirai
86
87
#endif
BasicTypes.hpp
Mirai::QQ_t
QQ号码类型
Definition:
BasicTypes.hpp:71
Mirai
所有mirai相关的对象的命名空间
Definition:
HttpWsAdaptor.hpp:25
Mirai::GroupAnnouncement
群公告
Definition:
GroupSettings.hpp:68
Mirai::GroupAnnouncement::SenderId
QQ_t SenderId
公告发送着QQ
Definition:
GroupSettings.hpp:74
Mirai::GroupAnnouncement::content
std::string content
公告内容
Definition:
GroupSettings.hpp:72
Mirai::GroupAnnouncement::PublicationTime
std::time_t PublicationTime
发布时间
Definition:
GroupSettings.hpp:82
Mirai::GroupAnnouncement::fid
std::string fid
公告id,唯一标识符
Definition:
GroupSettings.hpp:76
Mirai::GroupAnnouncement::ConfirmedCount
int ConfirmedCount
公告确认人数
Definition:
GroupSettings.hpp:80
Mirai::GroupAnnouncement::AllConfirmed
bool AllConfirmed
是否全员已确认
Definition:
GroupSettings.hpp:78
Mirai::GroupAnnouncement::group
Group group
群聊
Definition:
GroupSettings.hpp:70
Mirai::GroupConfig
群设置
Definition:
GroupSettings.hpp:39
Mirai::GroupConfig::AllowConfessTalk
bool AllowConfessTalk
是否允许坦白说
Definition:
GroupSettings.hpp:43
Mirai::GroupConfig::MuteAll
bool MuteAll
是否开启全员禁言
Definition:
GroupSettings.hpp:51
Mirai::GroupConfig::AllowAnonymousChat
bool AllowAnonymousChat
是否允许匿名聊天
Definition:
GroupSettings.hpp:49
Mirai::GroupConfig::name
std::string name
群名
Definition:
GroupSettings.hpp:41
Mirai::GroupConfig::AllowMemberInvite
bool AllowMemberInvite
是否允许邀请入群
Definition:
GroupSettings.hpp:45
Mirai::GroupConfig::AutoApprove
bool AutoApprove
是否自动审批入群申请
Definition:
GroupSettings.hpp:47
Mirai::Group
群聊资料
Definition:
BasicTypes.hpp:333
libmirai
models
libmirai
Types
GroupSettings.hpp
制作者
1.9.4