|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jurvis.util.JvDefaultFileFetcher
public class JvDefaultFileFetcher
Default JvFileFetcher that uses the standard Java I/O classes.
| Field Summary | |
|---|---|
protected int |
bytes
|
protected JvCachedFile |
cachedFile
|
protected long |
contentLength
|
protected String |
etag
|
protected long |
expires
|
protected long |
fetchStarted
|
protected long |
lastModified
|
protected long |
lastUpdate
|
protected JvDataTransferModel |
transferModel
|
| Constructor Summary | |
|---|---|
JvDefaultFileFetcher(JvCachedFile cachedFile)
Construct a new JvDefaultFileFetcher. |
|
| Method Summary | |
|---|---|
void |
actionPerformed(ActionEvent e)
Method called when the timer fires. |
void |
fetch(File dest,
JvDataTransferModel transferModel)
Fetch the file and notify transferModel of the progress. |
long |
getContentLength()
Return the size of the downloaded file. |
String |
getEtag()
Return the Etag that identifies the file. |
long |
getExpires()
Return the date the cached file should expire. |
long |
getLastModified()
Return the last modified date of the file. |
protected InputStream |
open()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected JvDataTransferModel transferModel
protected JvCachedFile cachedFile
protected long contentLength
protected long lastModified
protected long expires
protected String etag
protected long fetchStarted
protected long lastUpdate
protected int bytes
| Constructor Detail |
|---|
public JvDefaultFileFetcher(JvCachedFile cachedFile)
JvDefaultFileFetcher.
cachedFile - cache entry for the file to be fetched| Method Detail |
|---|
public long getContentLength()
getContentLength in interface JvFileFetcherpublic long getLastModified()
getLastModified in interface JvFileFetcherpublic long getExpires()
getExpires in interface JvFileFetcherpublic String getEtag()
getEtag in interface JvFileFetcher
public void fetch(File dest,
JvDataTransferModel transferModel)
throws IOException
transferModel of the progress.
fetch in interface JvFileFetcherdest - the cache entrytransferModel - object holding status of the transfer; may be null
IOException
protected InputStream open()
throws IOException
IOExceptionpublic void actionPerformed(ActionEvent e)
actionPerformed in interface ActionListener
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||