Inherits Function.
Adds a file from a message to the list of file downloads. Download progress and completion of the download will be notified through updateFile updates. If message database is used, the list of file downloads is persistent across application restarts. The downloading is independent of download using downloadFile, i.e. it continues if downloadFile is canceled or is used to download a part of the file.
Returns object_ptr<File>.
Public Fields | |
int32 | file_id_ |
Identifier of the file to download. | |
int53 | chat_id_ |
Chat identifier of the message with the file. | |
int53 | message_id_ |
Message identifier. | |
int32 | priority_ |
Priority of the download (1-32). The higher the priority, the earlier the file will be downloaded. If the priorities of two files are equal, then the last one for which downloadFile/addFileToDownloads was called will be downloaded first. | |
Public Types | |
using | ReturnType = object_ptr< file > |
Typedef for the type returned by the function. | |
Public Instance Methods | |
addFileToDownloads () | |
addFileToDownloads (int32 file_id_, int53 chat_id_, int53 message_id_, int32 priority_) | |
void | store (TlStorerToString &s, const char *field_name) const final |
![]() | |
virtual void | store (TlStorerUnsafe &s) const |
virtual void | store (TlStorerCalcLength &s) const |
TlObject ()=default | |
TlObject (const TlObject &)=delete | |
TlObject & | operator= (const TlObject &)=delete |
TlObject (TlObject &&)=default | |
TlObject & | operator= (TlObject &&)=default |
virtual | ~TlObject ()=default |
Static Public Attributes | |
static const std::int32_t | ID = 867533751 |
Identifier uniquely determining a type of the object. | |
Default constructor for a function, which adds a file from a message to the list of file downloads. Download progress and completion of the download will be notified through updateFile updates. If message database is used, the list of file downloads is persistent across application restarts. The downloading is independent of download using downloadFile, i.e. it continues if downloadFile is canceled or is used to download a part of the file.
Returns object_ptr<File>.
addFileToDownloads | ( | int32 | file_id_, |
int53 | chat_id_, | ||
int53 | message_id_, | ||
int32 | priority_ | ||
) |
Creates a function, which adds a file from a message to the list of file downloads. Download progress and completion of the download will be notified through updateFile updates. If message database is used, the list of file downloads is persistent across application restarts. The downloading is independent of download using downloadFile, i.e. it continues if downloadFile is canceled or is used to download a part of the file.
Returns object_ptr<File>.
[in] | file_id_ | Identifier of the file to download. |
[in] | chat_id_ | Chat identifier of the message with the file. |
[in] | message_id_ | Message identifier. |
[in] | priority_ | Priority of the download (1-32). The higher the priority, the earlier the file will be downloaded. If the priorities of two files are equal, then the last one for which downloadFile/addFileToDownloads was called will be downloaded first. |
|
finalvirtual |