public abstract class DownloadableVideoItem extends java.util.Observable
限定符和类型 | 类和说明 |
---|---|
static class |
DownloadableVideoItem.DownloadStatus
下载状态 解析hls文件失败时,返回错误 ERROR;下载ts遇到网络问题时或被强关时,返回 暂停状态;
|
限定符和类型 | 字段和说明 |
---|---|
static java.lang.String[] |
ERROR_CODE_DESC |
static int |
ERROR_CODE_INVALID_URL |
static int |
ERROR_CODE_M3U8_DRM_INVALID |
static int |
ERROR_CODE_M3U8_INVALID_FORMAT |
static int |
ERROR_CODE_M3U8_SAVE_FAILED |
static int |
ERROR_CODE_NETWORK_FAILED |
static int |
ERROR_CODE_NO_ERROR |
static int |
ERROR_CODE_SDCARD_UNMOUNTED |
static int |
ERROR_CODE_TS_SAVE_FAILED |
构造器和说明 |
---|
DownloadableVideoItem() |
限定符和类型 | 方法和说明 |
---|---|
int |
getErrorCode()
获取错误码
当DownloadStatus的状态为ERROR时,通过该接口获取错误码
|
java.lang.String |
getFailReason()
获取错误描述
推荐使用getErrorCode接口
|
java.lang.String |
getLocalAbsolutePath()
获取本地文件的全路径名
|
float |
getProgress()
Get the current progress of the download
|
java.lang.String |
getSpeed() |
DownloadableVideoItem.DownloadStatus |
getStatus()
Get current state of the downloader
|
java.lang.String |
getUrl()
Get the URL (in String)
|
public static final java.lang.String[] ERROR_CODE_DESC
public static final int ERROR_CODE_NO_ERROR
public static final int ERROR_CODE_INVALID_URL
public static final int ERROR_CODE_NETWORK_FAILED
public static final int ERROR_CODE_SDCARD_UNMOUNTED
public static final int ERROR_CODE_M3U8_INVALID_FORMAT
public static final int ERROR_CODE_M3U8_SAVE_FAILED
public static final int ERROR_CODE_M3U8_DRM_INVALID
public static final int ERROR_CODE_TS_SAVE_FAILED
public DownloadableVideoItem()
public int getErrorCode()
public java.lang.String getUrl()
public java.lang.String getLocalAbsolutePath()
public float getProgress()
public java.lang.String getSpeed()
public DownloadableVideoItem.DownloadStatus getStatus()
public java.lang.String getFailReason()