|
qTbot 0.2.123.6f57966
qTbot is base back end library for your c++ Qt projects.
|
The TelegramUpdateAnswer class This is a base message from the telegram server after an update request. More...
#include <telegramupdateanswer.h>


Public Member Functions | |
| TelegramUpdateAnswer () | |
| TelegramUpdateAnswer default constructor. | |
| bool | isValid () const override |
| isValid returns true if the update is valid else false. | |
| QJsonValue | result () const |
| result This is the result field of the telegram response. | |
| int | errorCode () const |
| errorCode This is the error code (if it exists). | |
| QString | errorDescription () const |
| errorDescription This is the text description of what happened. | |
| QString | from () const override |
| from This virtual function should return the id of the user that sent this update to the bot. | |
| QVariant | chatId () const override |
| chatId This virtual function should return the id of the chat that sent this update to the bot. | |
| unsigned long long | updateId () const override |
| updateId This method returns the numeric id of the update. | |
| Public Member Functions inherited from qTbot::IJsonBasedUpdate | |
| IJsonBasedUpdate () | |
| IJsonBasedUpdate default constructor. | |
| void | setRawData (const QByteArray &newRawData) override |
| setRawData This method sets a new raw data value. | |
| Public Member Functions inherited from qTbot::iUpdate | |
| iUpdate () | |
| iUpdate default constructor. | |
| const QByteArray & | rawData () const |
| rawData returns the raw data of the update. The raw data is the not parsed value from the server. | |
| Public Member Functions inherited from qTbot::IJsonBasedObject | |
| IJsonBasedObject () | |
| IJsonBasedObject default constructor. | |
| IJsonBasedObject (const QJsonObject &newRawJson) | |
| IJsonBasedObject constructs the object from a raw json value. | |
| const QJsonObject & | rawJson () const |
| rawJson Telegram uses a rest api with json objects. So all received messages are parsed into a json object. | |
| virtual void | setRawJson (const QJsonObject &newRawJson) |
| setRawJson This method sets a new raw json data of the object. | |
The TelegramUpdateAnswer class This is a base message from the telegram server after an update request.
Definition at line 20 of file telegramupdateanswer.h.
| qTbot::TelegramUpdateAnswer::TelegramUpdateAnswer | ( | ) |
TelegramUpdateAnswer default constructor.
Definition at line 12 of file telegramupdateanswer.cpp.
|
overridevirtual |
chatId This virtual function should return the id of the chat that sent this update to the bot.
Implements qTbot::iUpdate.
Definition at line 33 of file telegramupdateanswer.cpp.
| int qTbot::TelegramUpdateAnswer::errorCode | ( | ) | const |
errorCode This is the error code (if it exists).
Definition at line 21 of file telegramupdateanswer.cpp.

| QString qTbot::TelegramUpdateAnswer::errorDescription | ( | ) | const |
errorDescription This is the text description of what happened.
Definition at line 25 of file telegramupdateanswer.cpp.

|
overridevirtual |
from This virtual function should return the id of the user that sent this update to the bot.
Implements qTbot::iUpdate.
Definition at line 29 of file telegramupdateanswer.cpp.
|
overridevirtual |
isValid returns true if the update is valid else false.
Reimplemented from qTbot::IJsonBasedUpdate.
Definition at line 41 of file telegramupdateanswer.cpp.

| QJsonValue qTbot::TelegramUpdateAnswer::result | ( | ) | const |
result This is the result field of the telegram response.
Definition at line 17 of file telegramupdateanswer.cpp.

|
overridevirtual |
updateId This method returns the numeric id of the update.
Implements qTbot::iUpdate.
Definition at line 37 of file telegramupdateanswer.cpp.