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

This object represents an audio file to be treated as music by the Telegram clients. More...

#include <Audio.h>

Public Types

typedef std::shared_ptr< AudioPtr
 

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.
 
std::int32_t duration
 Duration of the audio in seconds as defined by sender.
 
std::string performer
 Optional. Performer of the audio as defined by sender or by audio tags.
 
std::string title
 Optional. Title of the audio as defined by sender or by audio tags.
 
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.
 
PhotoSize::Ptr thumbnail
 Optional. Thumbnail of the album cover to which the music file belongs.
 

Detailed Description

This object represents an audio file to be treated as music by the Telegram clients.

Definition at line 17 of file Audio.h.

Member Typedef Documentation

◆ Ptr

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

Definition at line 20 of file Audio.h.

Member Data Documentation

◆ duration

std::int32_t TgBot::Audio::duration

Duration of the audio in seconds as defined by sender.

Definition at line 36 of file Audio.h.

◆ fileId

std::string TgBot::Audio::fileId

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

Definition at line 25 of file Audio.h.

◆ fileName

std::string TgBot::Audio::fileName

Optional. Original filename as defined by sender.

Definition at line 51 of file Audio.h.

◆ fileSize

std::int64_t TgBot::Audio::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 64 of file Audio.h.

◆ fileUniqueId

std::string TgBot::Audio::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 Audio.h.

◆ mimeType

std::string TgBot::Audio::mimeType

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

Definition at line 56 of file Audio.h.

◆ performer

std::string TgBot::Audio::performer

Optional. Performer of the audio as defined by sender or by audio tags.

Definition at line 41 of file Audio.h.

◆ thumbnail

PhotoSize::Ptr TgBot::Audio::thumbnail

Optional. Thumbnail of the album cover to which the music file belongs.

Definition at line 69 of file Audio.h.

◆ title

std::string TgBot::Audio::title

Optional. Title of the audio as defined by sender or by audio tags.

Definition at line 46 of file Audio.h.


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