public static class DownloadSession.DownloadInfo extends Object
Applications can call DownloadSession.query() to query real-time download information,
including download links, storage paths, downloads size in bytes, and failure causes.
| 构造器 | 说明 |
|---|---|
DownloadInfo() |
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
String |
getDescription() |
Obtains the description of a file to be downloaded.
|
long |
getDownloadedBytes() |
Obtains the real-time downloads size (in bytes).
|
long |
getDownloadId() |
Obtains the ID of a file to be downloaded.
|
String |
getDownloadTitle() |
Obtains the title of a file to be downloaded.
|
long |
getDownloadTotalBytes() |
Obtains the total size of files to be downloaded (in bytes).
|
int |
getFailedReason() |
Obtains a download failure cause, which can be any
DownloadSession.ERROR_* constant. |
String |
getFileName() |
Obtains the name of a file to be downloaded.
|
String |
getFilePath() |
Obtains the String of a stored file.
|
Uri |
getPath() |
Obtains the URI of a stored file.
|
int |
getPausedReason() |
Obtains the reason why a session is paused, which can be any
DownloadSession.PAUSED_* constant. |
int |
getStatus() |
Obtains the download status code, which can be any
DownloadSession.SESSION_* constant. |
Uri |
getTargetUri() |
Obtains the URI of files to be downloaded.
|
String |
getTargetURI() |
Obtains the String of files to be downloaded.
|
String |
getTitle() |
Obtains the title of a file to be downloaded.
|
long |
getTotalBytes() |
Obtains the total size of files to be downloaded (in bytes).
|
String |
toString() |
Converts the download information to character strings.
|
public Uri getPath()
public String getFilePath()
public Uri getTargetUri()
public String getTargetURI()
public int getStatus()
DownloadSession.SESSION_* constant.null if the operation is not allowed.public int getFailedReason()
DownloadSession.ERROR_* constant.public int getPausedReason()
DownloadSession.PAUSED_* constant.public long getDownloadId()
public long getDownloadedBytes()
public long getTotalBytes()
public long getDownloadTotalBytes()
public String getDescription()
public String getFileName()
public String getTitle()
public String getDownloadTitle()