tgbot-cpp
Loading...
Searching...
No Matches
TgBot::Document Class Reference

This object represents a general file (as opposed to photos, voice messages and audio files). More...

#include <Document.h>

Public Types

typedef std::shared_ptr< DocumentPtr
 

Public Attributes

std::string fileId
 Identifier for this file, which can be used to download or reuse the file.
 
std::string fileUniqueId
 Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.
 
PhotoSize::Ptr thumb
 Optional. Document thumbnail as defined by sender.
 
std::string fileName
 Optional. Original filename as defined by sender.
 
std::string mimeType
 Optional. MIME type of the file as defined by sender.
 
std::int64_t fileSize
 Optional. File size in bytes.
 

Detailed Description

This object represents a general file (as opposed to photos, voice messages and audio files).

Definition at line 17 of file Document.h.

Member Typedef Documentation

◆ Ptr

typedef std::shared_ptr<Document> TgBot::Document::Ptr

Definition at line 20 of file Document.h.

Member Data Documentation

◆ fileId

std::string TgBot::Document::fileId

Identifier for this file, which can be used to download or reuse the file.

Definition at line 25 of file Document.h.

◆ fileName

std::string TgBot::Document::fileName

Optional. Original filename as defined by sender.

Definition at line 41 of file Document.h.

◆ fileSize

std::int64_t TgBot::Document::fileSize

Optional. File size in bytes.

It can be bigger than 2^31 and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this value.

Definition at line 54 of file Document.h.

◆ fileUniqueId

std::string TgBot::Document::fileUniqueId

Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.

Definition at line 31 of file Document.h.

◆ mimeType

std::string TgBot::Document::mimeType

Optional. MIME type of the file as defined by sender.

Definition at line 46 of file Document.h.

◆ thumb

PhotoSize::Ptr TgBot::Document::thumb

Optional. Document thumbnail as defined by sender.

Definition at line 36 of file Document.h.


The documentation for this class was generated from the following file: