public class DownloadTask extends SimpleTask
| Modifier and Type | Field and Description |
|---|---|
static int |
RESULT_DOWNLOAD_ERROR |
static int |
RESULT_NO_ENOUGH_SPACE |
static int |
RESULT_OK |
static int |
RESULT_URL_ERROR |
| Constructor and Description |
|---|
DownloadTask(DownLoadListener listener,
java.lang.String url,
java.lang.String fileName) |
| Modifier and Type | Method and Description |
|---|---|
void |
doInBackground()
A worker will execute this method in a background thread
|
protected void |
onCancel()
When the Task is Cancelled.
|
void |
onFinish(boolean canceled)
will be called after doInBackground();
|
cancel, isCancelled, isDone, post, postDelay, restart, runpublic static final int RESULT_OK
public static final int RESULT_URL_ERROR
public static final int RESULT_DOWNLOAD_ERROR
public static final int RESULT_NO_ENOUGH_SPACE
public DownloadTask(DownLoadListener listener, java.lang.String url, java.lang.String fileName)
public void doInBackground()
SimpleTaskdoInBackground in class SimpleTaskprotected void onCancel()
SimpleTaskonCancel in class SimpleTaskpublic void onFinish(boolean canceled)
SimpleTaskonFinish in class SimpleTask