public class Download extends AbstractMonitorableTask
Thread.State, Thread.UncaughtExceptionHandlertaskStatuscancellationRequestedMAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY| Constructor and Description |
|---|
Download() |
Download(SimpleTaskStatus taskStatus) |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
acceptableFileSize(File f,
int estimated_size)
URLConnection's method getContentLength() does not give
exact size. |
File |
downloadFile(URL url,
String defaultFileName) |
cancelRequest, getSimpleTaskStatus, getTaskStatus, setTaskNameisCancellationRequestedactiveCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, run, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yieldequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitisCancellationRequestedpublic Download(SimpleTaskStatus taskStatus)
taskName - public Download()
public File downloadFile(URL url, String defaultFileName) throws IOException
IOExceptionpublic static boolean acceptableFileSize(File f, int estimated_size)
URLConnection's method getContentLength() does not give
exact size.