File class
This object represents a file ready to be downloaded. The file can be downloaded via the link https://api.telegram.org/file/bot
Constructors
Properties
- fileId → String
-
Unique identifier for this file
final
- fileName → String?
-
Returns the file name of the file.
no setter
- filePath → String?
-
File path. Use https://api.telegram.org/file/bot
final
- fileSize → int?
-
File size, if known
final
- fileUniqueId → String
-
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.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
download(
{String? path, String? token}) → Future< File?> -
This is an advanced method of Televerse. This method downloads the particular file and saves it to the
specified
path
. -
getBytes(
[String? token]) → Future< Uint8List?> -
This is an advanced method in Televerse. This returns
Uint8List?
representing the byte data of the file. -
getDownloadURI(
[String? token]) → Uri - Returns the Uri object of the download URL. This is an shorthand method for:
-
getDownloadUrl(
[String? token]) → String - Returns the download URL for the particular file as String
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Returns the JSON representation of the File object.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited