qTbot
0.89.ee6949a
qTbot is base back end library for your c++ Qt projects.
telegramdocument.cpp
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
#include "
telegramdocument.h
"
9
10
namespace
qTbot
{
11
12
TelegramDocument::TelegramDocument
()
13
{
14
15
}
16
17
TelegramDocument::TelegramDocument
(
const
QJsonObject &jsonObject) :
TelegramFile
(jsonObject) {}
18
19
QString
TelegramDocument::fileName
()
const
{
20
return
rawJson
()[
"file_name"
].toString();
21
}
22
23
QString
TelegramDocument::mimeType
()
const
{
24
return
rawJson
()[
"mime_type"
].toString();
25
}
26
27
}
qTbot::IJsonBasedObject::rawJson
const QJsonObject & rawJson() const
rawJson Telegram use rest api with json objects. So all received messages will be parsed in to jsobje...
Definition
ijsonbasedobject.cpp:21
qTbot::TelegramDocument::mimeType
QString mimeType() const
Returns the MIME type of the document.
Definition
telegramdocument.cpp:23
qTbot::TelegramDocument::TelegramDocument
TelegramDocument()
Definition
telegramdocument.cpp:12
qTbot::TelegramDocument::fileName
QString fileName() const
Returns the file name of the document.
Definition
telegramdocument.cpp:19
qTbot::TelegramFile
The TelegramFile class is base class for all files.
Definition
telegramfile.h:18
qTbot
Definition
telegramdeletemessage.cpp:8
telegramdocument.h
src
qTbot
src
public
qTbot
messages
telegramdocument.cpp
Generated by
1.9.8