qTbot 0.89.ee6949a
qTbot is base back end library for your c++ Qt projects.
qTbot::ITelegramBot Class Reference

The ITelegramBot class This is base implementation of the all telegramm bots. More...

#include <itelegrambot.h>

Public Member Functions

 ITelegramBot ()
 
 ~ITelegramBot ()
 
bool login (const QByteArray &token) override
 login This method get bae information of the bot from remote server.
 
bool sendMessage (const QVariant &chatId, const QString &text) override
 sendMessage This method sents text to the selected chat.
 
bool sendLocationRequest (const QVariant &chatId, const QString &text, const QString &buttonText, bool onetimeKeyboard)
 sendLocationRequest This method setn into chat button that will automaticaly sent geo location to bot.
 
bool sendSelfContactRequest (const QVariant &chatId, const QString &text, const QString &buttonText, bool onetimeKeyboard)
 sendSelfContactRequest This method sent into chat button that will automaticaly sent self contact information to bot.
 
bool sendSpecificMessage (const TelegramArgs &args, const qTbot::ExtraJsonObjects &extraObjects={})
 Sends a specific message to a chat.
 
bool sendSpecificMessageWithKeyboard (const TelegramArgs &args, const KeyboardOnMessage &keyboard)
 Sends a specific message with a custom keyboard to a chat. This function sends a specific message to a chat with a custom keyboard. The message can contain text and additional settings to customize its behavior.
 
bool sendSpecificMessageWithKeyboard (const TelegramArgs &args, const QList< QList< QString > > &keyboard, bool onTimeKeyboard=false, bool autoResizeKeyboard=true)
 Sends a specific message with a custom keyboard to a chat.
 
bool deleteMessage (const QVariant &chatId, const QVariant &messageId) override
 deleteMessage This is main method to delete messages.
 
bool editSpecificMessageWithKeyboard (const QVariant &messageId, const TelegramArgs &args, const QList< QList< QString > > &keyboard={}, bool onTimeKeyboard=false, bool autoResizeKeyboard=false)
 Edits a specific message with a custom keyboard in a chat.
 
bool editSpecificMessageWithKeyboard (const QVariant &messageId, const TelegramArgs &args, const KeyboardOnMessage &keyboard={})
 Edits a specific message with a custom keyboard in a chat.
 
bool editMessageKeyboard (const QVariant &messageId, const QVariant &chatId, const KeyboardOnMessage &keyboard={}, const QString &callBackQueryId="")
 Edits a keyboard of message in a chat.
 
bool editSpecificMessage (const QVariant &messageId, const TelegramArgs &args)
 Edits a specific message in a chat.
 
QSharedPointer< iFilegetFile (const QString &fileId, iFile::Type fileType=iFile::Type::Ram) override
 Get a file by its ID.
 
QSharedPointer< QNetworkReplygetFileMeta (const QString &fileId, const QWeakPointer< iFile > &receiver={nullptr})
 getFileMeta This method receive meta information of the file.
 
bool sendFile (const QFileInfo &file, const QVariant &chatId) override
 send file .
 
bool sendFile (const QByteArray &file, const QString &fileName, const QVariant &chatId) override
 sendFile This method setns a file that saved as a bytearray.
 
bool sendFileMessage (const TelegramArgs &args, const QFileInfo &file)
 sendFileMessage This method sents a message with file.
 
bool sendFileMessage (const TelegramArgs &args, const QByteArray &file, const QString &fileName)
 sendFileMessage This method sents a message with file.
 
bool sendPhoto (const TelegramArgs &args, const QFileInfo &photo, const KeyboardOnMessage &keyboard={})
 sendPhoto This method will send image into chat with chatId
 
bool sendPhoto (const TelegramArgs &args, const QByteArray &photo, const QString &fileName, const KeyboardOnMessage &keyboard={})
 sendPhoto This method will send image into chat with chatId
 
bool sendFileById (const QString &fileID, const QVariant &chatId)
 sendFileById This is specific method of the telegram bot. sents file by id.
 
bool sendLocation (const TelegramArgs &args, float latitude, float longitude, const KeyboardOnMessage &keyboard={})
 sendLocation This method sents locatin to user.
 
bool sendContact (const TelegramArgs &args, const QString &phone, const QString &firstName, const QString &secondName="")
 sendContact This method sents a contact data.
 
unsigned long long id () const
 id This method return bots id number.
 
const QStringusername () const
 username This is bots login
 
int gelLastMessageId (unsigned long long &chatId) const
 gelLastMessageId this method returns last sendet message id.
 
- Public Member Functions inherited from qTbot::IBot
 IBot ()
 
 ~IBot ()
 
virtual void logout ()
 login This method remove login token of bot.
 
const QByteArraytoken () const
 token This is token value for authication on the remote server (bot)
 
const QStringname () const
 name This is name of the bot. usualy it fields will be received from the server after autication.
 
void setName (const QString &newName)
 setName This method sets new value for the IBot::name field.
 
QSharedPointer< iUpdatetakeNextUnreadUpdate ()
 takeNextUnreadUpdate This method take a unread update and mark them as read.
 
QSet< unsigned long longprocessed () const
 processed This method return list of processed mesages.
 
virtual void setProcessed (const QSet< unsigned long long > &newProcessed)
 setProcessed This method sets new list of processed mesages.
 

Protected Member Functions

void setId (unsigned long long newId)
 setId This method sets new value for the ITelegramBot::id property.
 
void setUsername (const QString &newUsername)
 setUsername This method sets new value for the ITelegramBot::username property.
 
QString makeUrl (const QSharedPointer< iRequest > &request) const override
 makeUrl This method prepare a prefix url for http requests.
 
int getFileSizeByUniqueId (const QString &id) const
 getFileSizeByUniqueId This method return size of the file by id
 
QSharedPointer< TelegramFilegetFileInfoByUniqueId (const QString &id) const
 getFileInfoByUniqueId return a local saved meta information about the file.
 
virtual void onRequestError (const QSharedPointer< TelegramUpdateAnswer > &ansverWithError) const
 onRequestError This method invokent when telegram server sent error responce. Default implementation just print error message on the console.
 
void handleIncomeNewUpdate (const QSharedPointer< iUpdate > &) override
 handleIncomeNewUpdate This method just emit the sigReceiveUpdate signal.
 
virtual bool sendMessageRequest (const QSharedPointer< iRequest > &rquest, const std::function< void(int msgId)> &msgIdCB={})
 sendMessageRequest This method invoke when bot will be sent eny messages into chat.
 
- Protected Member Functions inherited from qTbot::IBot
QSharedPointer< QNetworkReplysendRequest (const QSharedPointer< iRequest > &rquest)
 sendRequest This method sent custom requests to the server.
 
void setToken (const QByteArray &newToken)
 setToken This is setter of the IBot::token value.
 
void incomeNewUpdate (const QSharedPointer< iUpdate > &message)
 incomeNewUpdate This method save incomed messages into store.
 
void markUpdateAsProcessed (const QSharedPointer< iUpdate > &message)
 markMessageAsProcessed This method remove message from the not processed messages store.
 
void markUpdateAsUnprocessed (const QSharedPointer< iUpdate > &message)
 markMessageAsUnprocessed This method add the message into a not processed messages store.
 
void markUpdateAsUnprocessed (unsigned long long messageID)
 markMessageAsUnprocessed This method add the message into a not processed messages store.
 
virtual QString defaultFileStorageLocation () const
 defaultFileStorageLocation This method return default file storage location.
 

Additional Inherited Members

- Signals inherited from qTbot::IBot
void sigReceiveUpdate (const QSharedPointer< iUpdate > &)
 sigReceiveUpdate emit when but receive any updates from users.
 
void sigStopRequire ()
 sigStopRequire just custm event for stop bot if tou use services.
 
- Static Protected Member Functions inherited from qTbot::IBot
template<class MessageType , class ... Args>
static QSharedPointer< MessageType > makeMesasge (const QByteArray &data, Args &&...args)
 makeMesasge This is factory method tha can create a messages types.
 
template<class MessageType , class ... Args>
static QSharedPointer< MessageType > makeMesasge (const QJsonObject &data, Args &&...args)
 makeMesasge This is factory method tha can create a messages types.
 

Detailed Description

The ITelegramBot class This is base implementation of the all telegramm bots.

Definition at line 34 of file itelegrambot.h.

Inheritance diagram for qTbot::ITelegramBot:
Inheritance graph
Collaboration diagram for qTbot::ITelegramBot:
Collaboration graph

Constructor & Destructor Documentation

◆ ITelegramBot()

qTbot::ITelegramBot::ITelegramBot ( )

Definition at line 41 of file itelegrambot.cpp.

◆ ~ITelegramBot()

qTbot::ITelegramBot::~ITelegramBot ( )

Definition at line 45 of file itelegrambot.cpp.

Member Function Documentation

◆ deleteMessage()

bool qTbot::ITelegramBot::deleteMessage ( const QVariant chatId,
const QVariant messageId 
)
overridevirtual

deleteMessage This is main method to delete messages.

Parameters
chatIdThis is cahat id wher will be removed message.
messageIdThis is removed message id.
Returns
true if request was be prepared successful

Implements qTbot::IBot.

Definition at line 128 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ editMessageKeyboard()

bool qTbot::ITelegramBot::editMessageKeyboard ( const QVariant messageId,
const QVariant chatId,
const KeyboardOnMessage keyboard = {},
const QString callBackQueryId = "" 
)

Edits a keyboard of message in a chat.

This function allows you to edit a keyboard of specific message.

Parameters
messageIdThe unique identifier of the message to edit.
chatIdThe unique identifier of the chat containing the message.
keyboardA list of maps where each map represents a button with a callback function (optional).
callBackQueryIdThe unique identifier for callback queries triggered by the edited message (optional).
Returns
Returns true if the message was successfully edited, false otherwise.
Note
The keyboard parameter should be a list of maps where each map represents a button. The button's label is the map key, and the associated callback function is the map value (optional).
The callBackQueryId parameter is used to handle callback queries when buttons are pressed (optional).
By default, web page previews for links in the new text are not disabled (optional).

Definition at line 234 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ editSpecificMessage()

bool qTbot::ITelegramBot::editSpecificMessage ( const QVariant messageId,
const TelegramArgs args 
)

Edits a specific message in a chat.

This function allows you to edit a specific message in a chat. You can update the message's text and customize its behavior as needed.

Parameters
messageIdThe unique identifier of the message to edit.
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
Returns
Returns true if the message was successfully edited, false otherwise.
Note
By default, web page previews for links in the new text are not disabled (optional).

Definition at line 252 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ editSpecificMessageWithKeyboard() [1/2]

bool qTbot::ITelegramBot::editSpecificMessageWithKeyboard ( const QVariant messageId,
const TelegramArgs args,
const KeyboardOnMessage keyboard = {} 
)

Edits a specific message with a custom keyboard in a chat.

This function allows you to edit a specific message in a chat with a custom keyboard. You can update the message's text and customize its behavior as needed.

Parameters
messageIdThe unique identifier of the message to edit.
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
keyboardA list of maps where each map represents a button with a callback function (optional).
Returns
Returns true if the message was successfully edited, false otherwise.
Note
By default, web page previews for links in the new text are not disabled (optional).

Definition at line 215 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ editSpecificMessageWithKeyboard() [2/2]

bool qTbot::ITelegramBot::editSpecificMessageWithKeyboard ( const QVariant messageId,
const TelegramArgs args,
const QList< QList< QString > > &  keyboard = {},
bool  onTimeKeyboard = false,
bool  autoResizeKeyboard = false 
)

Edits a specific message with a custom keyboard in a chat.

This function allows you to edit a specific message in a chat with a custom keyboard. You can update the message's text and customize its behavior as needed.

Parameters
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
messageIdThe unique identifier of the message to edit.
keyboardA list of lists containing the new keyboard buttons to display (optional).
onTimeKeyboardSet to true to display the keyboard only once (optional).
autoResizeKeyboardSet to true to automatically resize the keyboard (optional).
Returns
Returns true if the message was successfully edited, false otherwise.
Note
By default, web page previews for links in the new text are not disabled (optional).

Definition at line 141 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ gelLastMessageId()

int qTbot::ITelegramBot::gelLastMessageId ( unsigned long long chatId) const

gelLastMessageId this method returns last sendet message id.

Parameters
chatIdchat id, when you want to get last message id.
Returns
message id.

Definition at line 635 of file itelegrambot.cpp.

◆ getFile()

QSharedPointer< iFile > qTbot::ITelegramBot::getFile ( const QString fileId,
iFile::Type  fileType = iFile::Type::Ram 
)
overridevirtual

Get a file by its ID.

This function allows you to retrieve a file by its ID.

Parameters
fileIdThe ID of the file to retrieve.
fileTypeThis is a saving way, by Default will be used a iFile::Type::Ram
Returns
Returns true if the file retrieval operation was successfully initiated and false in case of an error.

Implements qTbot::IBot.

Definition at line 287 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ getFileInfoByUniqueId()

QSharedPointer< TelegramFile > qTbot::ITelegramBot::getFileInfoByUniqueId ( const QString id) const
protected

getFileInfoByUniqueId return a local saved meta information about the file.

Parameters
idThis is id of the file.
Returns
shared pointer to the meta information of the file. If information no exists return nullptr;

Definition at line 495 of file itelegrambot.cpp.

Here is the caller graph for this function:

◆ getFileMeta()

QSharedPointer< QNetworkReply > qTbot::ITelegramBot::getFileMeta ( const QString fileId,
const QWeakPointer< iFile > &  receiver = {nullptr} 
)

getFileMeta This method receive meta information of the file.

Parameters
fileIdThis is id of the file.
receiverthis is wrapper of the file. Set to nullptr if you no need to wait a physical file.
Returns
true if the reqests sents successful.

Definition at line 356 of file itelegrambot.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getFileSizeByUniqueId()

int qTbot::ITelegramBot::getFileSizeByUniqueId ( const QString id) const
protected

getFileSizeByUniqueId This method return size of the file by id

Parameters
idThis is id of required file.
Returns
file size - else 0

Definition at line 487 of file itelegrambot.cpp.

◆ handleIncomeNewUpdate()

void qTbot::ITelegramBot::handleIncomeNewUpdate ( const QSharedPointer< iUpdate > &  message)
overrideprotectedvirtual

handleIncomeNewUpdate This method just emit the sigReceiveUpdate signal.

Note
you may override this method for filter the sigReceiveUpdate signal or for handling new updates.

Reimplemented from qTbot::IBot.

Definition at line 505 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ id()

unsigned long long qTbot::ITelegramBot::id ( ) const

id This method return bots id number.

Returns
bots id number.

Definition at line 639 of file itelegrambot.cpp.

◆ login()

bool qTbot::ITelegramBot::login ( const QByteArray token)
overridevirtual

login This method get bae information of the bot from remote server.

Parameters
tokenThis is token value for login
Returns
true if login request sent successful else false.

Implements qTbot::IBot.

Reimplemented in qTbot::TelegramRestBot.

Definition at line 48 of file itelegrambot.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ makeUrl()

QString qTbot::ITelegramBot::makeUrl ( const QSharedPointer< iRequest > &  request) const
overrideprotectedvirtual

makeUrl This method prepare a prefix url for http requests.

Parameters
request- This is request object for that will be prepared url.
Returns
http request prefix

Implements qTbot::IBot.

Definition at line 623 of file itelegrambot.cpp.

◆ onRequestError()

void qTbot::ITelegramBot::onRequestError ( const QSharedPointer< TelegramUpdateAnswer > &  ansverWithError) const
protectedvirtual

onRequestError This method invokent when telegram server sent error responce. Default implementation just print error message on the console.

Parameters
ansverWithError- This is ansver object with error descriptions. and codes errors.

Definition at line 499 of file itelegrambot.cpp.

◆ sendContact()

bool qTbot::ITelegramBot::sendContact ( const TelegramArgs args,
const QString phone,
const QString firstName,
const QString secondName = "" 
)

sendContact This method sents a contact data.

Parameters
argsbase arguments of message.
firstNameThis is first name of contact.
phoneThis is phone number of contact.
secondNameThis is second name of user.
Returns
true if contact sent successful

Definition at line 474 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendFile() [1/2]

bool qTbot::ITelegramBot::sendFile ( const QByteArray file,
const QString fileName,
const QVariant chatId 
)
overridevirtual

sendFile This method setns a file that saved as a bytearray.

Parameters
fileThis is file source.
fileNameThis is name of file.
chatIdThis is chat of the receivers.
Returns
true if the file will sent successful.

Implements qTbot::IBot.

Definition at line 373 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendFile() [2/2]

bool qTbot::ITelegramBot::sendFile ( const QFileInfo file,
const QVariant chatId 
)
overridevirtual

send file .

Parameters
fileThis is a file that you want to send.
chatIdid of the chat.
Returns
Returns true if the file sents successful.

Implements qTbot::IBot.

Definition at line 369 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendFileById()

bool qTbot::ITelegramBot::sendFileById ( const QString fileID,
const QVariant chatId 
)

sendFileById This is specific method of the telegram bot. sents file by id.

Parameters
fileIDThis is file id.
chatIdchat that should receive a file.
Returns
true if the file sent successful.

Definition at line 446 of file itelegrambot.cpp.

◆ sendFileMessage() [1/2]

bool qTbot::ITelegramBot::sendFileMessage ( const TelegramArgs args,
const QByteArray file,
const QString fileName 
)

sendFileMessage This method sents a message with file.

Parameters
fileThis is data that will be sents as a file with name fileName.
fileNameThis is name of the file.
argsThis is general arguments of the message, include a chatID.
Returns
true if the message sents successful else false

Definition at line 390 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendFileMessage() [2/2]

bool qTbot::ITelegramBot::sendFileMessage ( const TelegramArgs args,
const QFileInfo file 
)

sendFileMessage This method sents a message with file.

Parameters
fileThis is path to sents file.
argsThis is general arguments of the message, include a chatID.
Returns
true if the message sents successful else false

Definition at line 377 of file itelegrambot.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ sendLocation()

bool qTbot::ITelegramBot::sendLocation ( const TelegramArgs args,
float  latitude,
float  longitude,
const KeyboardOnMessage keyboard = {} 
)

sendLocation This method sents locatin to user.

Parameters
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
latitude
longitude
keyboardA list of maps where each map represents a button with a callback function (optional).
Returns
true if locations sent successful else false

Definition at line 456 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendLocationRequest()

bool qTbot::ITelegramBot::sendLocationRequest ( const QVariant chatId,
const QString text,
const QString buttonText,
bool  onetimeKeyboard 
)

sendLocationRequest This method setn into chat button that will automaticaly sent geo location to bot.

Parameters
chatId
textmessage text
buttonTextText on the button
Returns
true if request sents successfull else false.

Definition at line 73 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendMessage()

bool qTbot::ITelegramBot::sendMessage ( const QVariant chatId,
const QString text 
)
overridevirtual

sendMessage This method sents text to the selected chat.

Parameters
chatIdThis is selected chat id
textThis is text that neet to sent.
Returns
true if data sents successful else false.
Note
the specific implementations of this interface can have a different method for sending.

Implements qTbot::IBot.

Definition at line 69 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendMessageRequest()

bool qTbot::ITelegramBot::sendMessageRequest ( const QSharedPointer< iRequest > &  rquest,
const std::function< void(int msgId)> &  msgIdCB = {} 
)
protectedvirtual

sendMessageRequest This method invoke when bot will be sent eny messages into chat.

Parameters
rquestThis is a message request.
msgIdCBcall back function for the get a sent message id
Returns
true if the message sent successful else false.

Definition at line 521 of file itelegrambot.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ sendPhoto() [1/2]

bool qTbot::ITelegramBot::sendPhoto ( const TelegramArgs args,
const QByteArray photo,
const QString fileName,
const KeyboardOnMessage keyboard = {} 
)

sendPhoto This method will send image into chat with chatId

Parameters
photothis is photo data.
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
fileNameThis is dispalyed name of photo.
keyboardA list of maps where each map represents a button with a callback function (optional).
Returns
true if photo will snt successful

Definition at line 421 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendPhoto() [2/2]

bool qTbot::ITelegramBot::sendPhoto ( const TelegramArgs args,
const QFileInfo photo,
const KeyboardOnMessage keyboard = {} 
)

sendPhoto This method will send image into chat with chatId

Parameters
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
photothis is photo path.
keyboardA list of maps where each map represents a button with a callback function (optional).
Returns
true if photo will snt successful

Definition at line 405 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendSelfContactRequest()

bool qTbot::ITelegramBot::sendSelfContactRequest ( const QVariant chatId,
const QString text,
const QString buttonText,
bool  onetimeKeyboard 
)

sendSelfContactRequest This method sent into chat button that will automaticaly sent self contact information to bot.

Parameters
chatId
textmessage text
buttonTextText on the button
Returns
true if request sents successfull else false.

Definition at line 91 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendSpecificMessage()

bool qTbot::ITelegramBot::sendSpecificMessage ( const TelegramArgs args,
const qTbot::ExtraJsonObjects extraObjects = {} 
)

Sends a specific message to a chat.

This function sends a specific message to a chat. You can include text and additional objects as needed to customize the message's content and behavior.

Parameters
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
extraObjectsA map containing additional objects associated with the message (optional).
Returns
Returns true if the message was sent successfully, false otherwise.
Note
The extraObjects parameter is a map where each key represents the object's name, and the associated value is a shared pointer to a JSON object (optional).

Definition at line 108 of file itelegrambot.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ sendSpecificMessageWithKeyboard() [1/2]

bool qTbot::ITelegramBot::sendSpecificMessageWithKeyboard ( const TelegramArgs args,
const KeyboardOnMessage keyboard 
)

Sends a specific message with a custom keyboard to a chat. This function sends a specific message to a chat with a custom keyboard. The message can contain text and additional settings to customize its behavior.

Parameters
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
keyboardA list of maps where each map represents a button with a callback function.
Returns
Returns true if the message was sent successfully, false otherwise.
Note
The keyboard parameter should be a list of maps where each map represents a button. The button's label is the map key, and the associated callback function is the map value.

Definition at line 123 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ sendSpecificMessageWithKeyboard() [2/2]

bool qTbot::ITelegramBot::sendSpecificMessageWithKeyboard ( const TelegramArgs args,
const QList< QList< QString > > &  keyboard,
bool  onTimeKeyboard = false,
bool  autoResizeKeyboard = true 
)

Sends a specific message with a custom keyboard to a chat.

This function sends a specific message to a chat with a custom keyboard. The message can contain text and additional settings to customize its behavior.

Parameters
args- This is structure with general arguments of the tellegram message. Use This structure for sets target and another arguments.
keyboardA list of lists containing the keyboard buttons to display.
onTimeKeyboardSet to true to display the keyboard only once.
autoResizeKeyboardSet to true to automatically resize the keyboard.
Returns
Returns true if the message was sent successfully, false otherwise.
Note
By default, web page previews for links in the message are not disabled.

Definition at line 272 of file itelegrambot.cpp.

Here is the call graph for this function:

◆ setId()

void qTbot::ITelegramBot::setId ( unsigned long long  newId)
protected

setId This method sets new value for the ITelegramBot::id property.

Parameters
newIdthis is new value of the ITelegramBot::id property.

Definition at line 627 of file itelegrambot.cpp.

◆ setUsername()

void qTbot::ITelegramBot::setUsername ( const QString newUsername)
protected

setUsername This method sets new value for the ITelegramBot::username property.

Parameters
newUsernamethis is new value of the ITelegramBot::username property.

Definition at line 619 of file itelegrambot.cpp.

◆ username()

const QString & qTbot::ITelegramBot::username ( ) const

username This is bots login

Returns
bots login.

Definition at line 631 of file itelegrambot.cpp.


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