qTbot 0.2.102.bb22a69
qTbot is base back end library for your c++ Qt projects.
telegramargs.h
Go to the documentation of this file.
1//#
2//# Copyright (C) 2023-2024 QuasarApp.
3//# Distributed under the GPLv3 software license, see the accompanying
4//# Everyone is permitted to copy and distribute verbatim copies
5//# of this license document, but changing it is not allowed.
6//#
7
8#ifndef TELEGRAMARGS_H
9#define TELEGRAMARGS_H
10
11#include <QVariant>
12#include "global.h"
13#include "irequest.h"
14
15namespace qTbot {
16
21{
22 TelegramArgs(const QVariant& id,
23 const QString& text = "",
24 unsigned long long replyToMessageId = 0,
25 const QString& parseMode = "html",
26 bool disableWebPagePreview = false,
27 const QString& callBackQueryId = "",
28 const std::function<void(int msgId)>& msgIdCB = {},
29 iRequest::RequestPriority priority = iRequest::RequestPriority::NormalPriority
30 );
31
36 QString text = "";
37
42 QVariant chatId = {};
43
48 QString callBackQueryId = {};
49
54 unsigned long long replyToMessageId = 0;
55
60 QString parseMode = "html";
61
66 bool disableWebPagePreview = false;
67
73 QMap<QString, QVariant> toMap(bool textAsCaption = false) const;
74
78 std::function<void(int msgId)> msgIdCB = {};
79
80 iRequest::RequestPriority requestPriority = iRequest::RequestPriority::NormalPriority;
81};
82
83}
84#endif // TELEGRAMARGS_H
RequestPriority
The RequestPriority enum.
Definition irequest.h:52
#define QTBOT_EXPORT
Definition global.h:18
The TelegramArgs class is base structure for the all tellegram message arguments.