tgbotxx 1.1.9.2
Telegram Bot C++ Library
Loading...
Searching...
No Matches
tgbotxx::StarAmount Struct Reference

Describes an amount of Telegram Stars. https://core.telegram.org/bots/api#staramount. More...

#include <StarAmount.hpp>

Public Member Functions

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

Public Attributes

std::int64_t amount {}
 Integer amount of Telegram Stars, rounded to 0; can be negative.
 
std::int64_t nanostarAmount {}
 Optional. The number of 1/1000000000 shares of Telegram Stars; from -999999999 to 999999999; can be negative if and only if amount is non-positive.
 

Detailed Description

Describes an amount of Telegram Stars. https://core.telegram.org/bots/api#staramount.

Definition at line 7 of file StarAmount.hpp.

Constructor & Destructor Documentation

◆ StarAmount() [1/2]

tgbotxx::StarAmount::StarAmount ( )
default

◆ StarAmount() [2/2]

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

Definition at line 9 of file StarAmount.hpp.

Member Function Documentation

◆ fromJson()

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

Deserializes this object from JSON.

Definition at line 29 of file StarAmount.hpp.

◆ toJson()

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

Serializes this object to JSON.

Returns
JSON representation of this object

Definition at line 22 of file StarAmount.hpp.

Member Data Documentation

◆ amount

std::int64_t tgbotxx::StarAmount::amount {}

Integer amount of Telegram Stars, rounded to 0; can be negative.

Definition at line 14 of file StarAmount.hpp.

◆ nanostarAmount

std::int64_t tgbotxx::StarAmount::nanostarAmount {}

Optional. The number of 1/1000000000 shares of Telegram Stars; from -999999999 to 999999999; can be negative if and only if amount is non-positive.

Definition at line 18 of file StarAmount.hpp.


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