qTbot
0.2.123.6f57966
qTbot is base back end library for your c++ Qt projects.
Toggle main menu visibility
telegramsinglerquest.cpp
Go to the documentation of this file.
1
//#
2
//# Copyright (C) 2023-2026 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
9
#include "
telegramsinglerquest.h
"
10
#include "qvariant.h"
11
12
#include <QString>
13
14
15
namespace
qTbot
{
16
17
TelegramSingleRquest::TelegramSingleRquest
(
const
QString&
request
,
18
const
QMap<QString, QVariant>&
args
) {
19
setRequest
(
request
);
20
setArgs
(
args
);
21
}
22
23
TelegramSingleRquest::TelegramSingleRquest
(
const
QString &
request
) {
24
setRequest
(
request
);
25
}
26
\
27
QString
TelegramSingleRquest::baseAddress
()
const
{
28
return
"https://api.telegram.org"
;
29
}
30
31
iRequest::RequestMethod
TelegramSingleRquest::method
()
const
{
32
return
Get
;
33
}
34
35
}
qTbot::TelegramSingleRquest::method
RequestMethod method() const override
method returns the method of the request.
Definition
telegramsinglerquest.cpp:31
qTbot::TelegramSingleRquest::baseAddress
QString baseAddress() const override
baseAddress This method returns the base domain of the remote server.
Definition
telegramsinglerquest.cpp:27
qTbot::TelegramSingleRquest::TelegramSingleRquest
TelegramSingleRquest(const QString &request, const QMap< QString, QVariant > &args)
TelegramSingleRquest This is the main constructor of the single requests.
Definition
telegramsinglerquest.cpp:17
qTbot::iRequest::RequestMethod
RequestMethod
RequestMethod This is the list of supported request types.
Definition
irequest.h:43
qTbot::iRequest::Get
@ Get
Get general get request, all request data is sent as a url line.
Definition
irequest.h:47
qTbot::iRequest::setRequest
void setRequest(const QString &newRequest)
setRequest sets a custom request command
Definition
irequest.cpp:106
qTbot::iRequest::args
const QMap< QString, QVariant > & args() const
args This method returns the the current list of arguments
Definition
irequest.cpp:30
qTbot::iRequest::request
const QString & request() const
request Returns the current request command.
Definition
irequest.cpp:102
qTbot::iRequest::setArgs
void setArgs(const QMap< QString, QVariant > &newArgs)
setArgs For some requests the list of arguments is possible to build only after the constructor.
Definition
irequest.cpp:38
qTbot
Definition
telegramdeletemessage.cpp:8
telegramsinglerquest.h
src
qTbot
src
private
requests
telegramsinglerquest.cpp
Generated by
1.18.0