Package org.drinkless.tdlib
Class TdApi.LocalFile
- java.lang.Object
-
- org.drinkless.tdlib.TdApi.Object
-
- org.drinkless.tdlib.TdApi.LocalFile
-
- Enclosing class:
- TdApi
public static class TdApi.LocalFile extends TdApi.Object
Represents a local file.
-
-
Field Summary
Fields Modifier and Type Field Description booleancanBeDeletedTrue, if the file can be deleted.booleancanBeDownloadedTrue, if it is possible to download or generate the file.static intCONSTRUCTORIdentifier uniquely determining type of the object.intdownloadedPrefixSizeIf isDownloadingCompleted is false, then only some prefix of the file starting from downloadOffset is ready to be read.intdownloadedSizeTotal downloaded file size, in bytes.intdownloadOffsetDownload will be started from this offset.booleanisDownloadingActiveTrue, if the file is currently being downloaded (or a local copy is being generated by some other means).booleanisDownloadingCompletedTrue, if the local copy is fully available.StringpathLocal path to the locally available file part; may be empty.
-
Constructor Summary
Constructors Constructor Description LocalFile()Represents a local file.LocalFile(String path, boolean canBeDownloaded, boolean canBeDeleted, boolean isDownloadingActive, boolean isDownloadingCompleted, int downloadOffset, int downloadedPrefixSize, int downloadedSize)Represents a local file.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetConstructor()-
Methods inherited from class org.drinkless.tdlib.TdApi.Object
toString
-
-
-
-
Field Detail
-
path
public String path
Local path to the locally available file part; may be empty.
-
canBeDownloaded
public boolean canBeDownloaded
True, if it is possible to download or generate the file.
-
canBeDeleted
public boolean canBeDeleted
True, if the file can be deleted.
-
isDownloadingActive
public boolean isDownloadingActive
True, if the file is currently being downloaded (or a local copy is being generated by some other means).
-
isDownloadingCompleted
public boolean isDownloadingCompleted
True, if the local copy is fully available.
-
downloadOffset
public int downloadOffset
Download will be started from this offset. downloadedPrefixSize is calculated from this offset.
-
downloadedPrefixSize
public int downloadedPrefixSize
If isDownloadingCompleted is false, then only some prefix of the file starting from downloadOffset is ready to be read. downloadedPrefixSize is the size of that prefix in bytes.
-
downloadedSize
public int downloadedSize
Total downloaded file size, in bytes. Can be used only for calculating download progress. The actual file size may be bigger, and some parts of it may contain garbage.
-
CONSTRUCTOR
public static final int CONSTRUCTOR
Identifier uniquely determining type of the object.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
LocalFile
public LocalFile()
Represents a local file.
-
LocalFile
public LocalFile(String path, boolean canBeDownloaded, boolean canBeDeleted, boolean isDownloadingActive, boolean isDownloadingCompleted, int downloadOffset, int downloadedPrefixSize, int downloadedSize)
Represents a local file.- Parameters:
path- Local path to the locally available file part; may be empty.canBeDownloaded- True, if it is possible to download or generate the file.canBeDeleted- True, if the file can be deleted.isDownloadingActive- True, if the file is currently being downloaded (or a local copy is being generated by some other means).isDownloadingCompleted- True, if the local copy is fully available.downloadOffset- Download will be started from this offset. downloadedPrefixSize is calculated from this offset.downloadedPrefixSize- If isDownloadingCompleted is false, then only some prefix of the file starting from downloadOffset is ready to be read. downloadedPrefixSize is the size of that prefix in bytes.downloadedSize- Total downloaded file size, in bytes. Can be used only for calculating download progress. The actual file size may be bigger, and some parts of it may contain garbage.
-
-
Method Detail
-
getConstructor
public int getConstructor()
- Specified by:
getConstructorin classTdApi.Object- Returns:
- this.CONSTRUCTOR
-
-