|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.sourceforge.java.util.jobs.Job
net.sourceforge.java.feednread.backend.jobs.DownloadJob
Downloads a web based resource to a File on the local machine.
| Field Summary | |
private URL |
downloadUrl
The Url of the File to download |
private boolean |
podcast
true if the download specifies a podcast;
false otherwise
|
private long |
size
The size of the download in bytes |
private File |
targetDirectory
The target directory to store the downloaded file to |
| Fields inherited from class net.sourceforge.java.util.jobs.Job |
|
| Fields inherited from interface net.sourceforge.java.util.jobs.IJob |
HIGH_PRIORITY, LOW_PRIORITY, NORM_PRIORITY |
| Constructor Summary | |
DownloadJob(URL downloadUrl,
File targetDirectory)
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
|
|
DownloadJob(URL downloadUrl,
File targetDirectory,
boolean podcast)
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
|
|
DownloadJob(URL downloadUrl,
File targetDirectory,
long size)
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
|
|
DownloadJob(URL downloadUrl,
File targetDirectory,
long size,
boolean podcast)
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
|
|
| Method Summary | |
void |
run(IProgressMonitor monitor)
Starts this DownloadJob, i.e. starts the download
process.
|
| Methods inherited from class net.sourceforge.java.util.jobs.Job |
cancel, done, getException, getJobManager, getName, getPriority, getStatus, getThread, isCanceled, join, setException, setJobManager, setName, setPriority, setThread, start, started, statusChanged |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private URL downloadUrl
The Url of the File to download
private File targetDirectory
The target directory to store the downloaded file to
private long size
The size of the download in bytes
private boolean podcast
true if the download specifies a podcast;
false otherwise
| Constructor Detail |
public DownloadJob(URL downloadUrl,
File targetDirectory)
throws IOException
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
downloadUrl - the url of the file to downloadtargetDirectory - the directory to store the downloaded file to
IOException - if the specified targetDirectory
does not a directory, does not exist or is not writeable
public DownloadJob(URL downloadUrl,
File targetDirectory,
long size)
throws IOException
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
downloadUrl - the url of the file to downloadtargetDirectory - the directory to store the downloaded file tosize - the size of the download in bytes
IOException - if the specified targetDirectory
does not a directory, does not exist or is not writeable
public DownloadJob(URL downloadUrl,
File targetDirectory,
boolean podcast)
throws IOException
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
downloadUrl - the url of the file to downloadtargetDirectory - the directory to store the downloaded file topodcast - true if downloadUrl specifies
a podcast; false otherwise
IOException - if the specified targetDirectory
does not a directory, does not exist or is not writeable
public DownloadJob(URL downloadUrl,
File targetDirectory,
long size,
boolean podcast)
throws IOException
Creates a new DownloadJob which requests the
File specified through downloadUrl and stores
it in the directory specified by targetDirectory.
downloadUrl - the url of the file to downloadtargetDirectory - the directory to store the downloaded file tosize - the size of the download in bytespodcast - true if downloadUrl specifies
a podcast; false otherwise
IOException - if the specified targetDirectory
does not a directory, does not exist or is not writeable| Method Detail |
public void run(IProgressMonitor monitor)
throws InvocationTargetException,
InterruptedException
Starts this DownloadJob, i.e. starts the download
process.
monitor - the IProgressMonitor to report the progress
of the download operation to
InvocationTargetException - if an error occured while performing
the download process
InterruptedException - if this DownloadJob was
interrupted by another IJobJob.getException()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||