public interface SonicDownloadCallback
| 限定符和类型 | 接口和说明 |
|---|---|
static class |
SonicDownloadCallback.SimpleDownloadCallback
an empty implementation of
SonicDownloadCallback |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
onError(int errorCode)
notify download failed.
|
void |
onFinish()
notify download finish.
|
void |
onProgress(int pro,
int total)
notify the download progress.
|
void |
onStart()
notify the download start.
|
void |
onSuccess(byte[] content,
java.util.Map<java.lang.String,java.util.List<java.lang.String>> rspHeaders)
notify download success.
|
void onStart()
void onProgress(int pro,
int total)
pro - downloaded sizetotal - total sizevoid onSuccess(byte[] content,
java.util.Map<java.lang.String,java.util.List<java.lang.String>> rspHeaders)
content - downloaded content bytesrspHeaders - http response headersvoid onError(int errorCode)
errorCode - error codevoid onFinish()
onSuccess or onError