tgbotxx  1.1.6.9
Telegram Bot C++ Library
tgbotxx::VideoNote Struct Reference

This object represents a video message (available in Telegram apps as of v.4.0). https://core.telegram.org/bots/api#videonote. More...

#include <VideoNote.hpp>

Public Member Functions

 VideoNote ()=default
 
 VideoNote (const nl::json &json)
 
nl::json toJson () const
 Serializes this object to JSON. More...
 
void fromJson (const nl::json &json)
 Deserializes this object from JSON. More...
 

Public Attributes

std::string fileId
 Identifier for this file, which can be used to download or reuse the file. More...
 
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. More...
 
std::int32_t length {}
 Video width and height (diameter of the video message) as defined by sender. More...
 
std::int32_t duration {}
 Duration of the video in seconds as defined by sender. More...
 
Ptr< PhotoSizethumbnail
 Optional. Video thumbnail. More...
 
std::int64_t 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. More...
 

Detailed Description

This object represents a video message (available in Telegram apps as of v.4.0). https://core.telegram.org/bots/api#videonote.

Definition at line 8 of file VideoNote.hpp.

Constructor & Destructor Documentation

◆ VideoNote() [1/2]

tgbotxx::VideoNote::VideoNote ( )
default

◆ VideoNote() [2/2]

tgbotxx::VideoNote::VideoNote ( const nl::json &  json)
inlineexplicit

Definition at line 10 of file VideoNote.hpp.

Member Function Documentation

◆ fromJson()

void tgbotxx::VideoNote::fromJson ( const nl::json &  json)
inline

Deserializes this object from JSON.

Definition at line 48 of file VideoNote.hpp.

◆ toJson()

nl::json tgbotxx::VideoNote::toJson ( ) const
inline

Serializes this object to JSON.

Returns
JSON representation of this object

Definition at line 37 of file VideoNote.hpp.

Member Data Documentation

◆ duration

std::int32_t tgbotxx::VideoNote::duration {}

Duration of the video in seconds as defined by sender.

Definition at line 25 of file VideoNote.hpp.

◆ fileId

std::string tgbotxx::VideoNote::fileId

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

Definition at line 15 of file VideoNote.hpp.

◆ fileSize

std::int64_t tgbotxx::VideoNote::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 33 of file VideoNote.hpp.

◆ fileUniqueId

std::string tgbotxx::VideoNote::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 19 of file VideoNote.hpp.

◆ length

std::int32_t tgbotxx::VideoNote::length {}

Video width and height (diameter of the video message) as defined by sender.

Definition at line 22 of file VideoNote.hpp.

◆ thumbnail

Ptr<PhotoSize> tgbotxx::VideoNote::thumbnail

Optional. Video thumbnail.

Definition at line 28 of file VideoNote.hpp.


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