|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--netx.jnlp.cache.Resource
Information about a single resource to download. This class tracks the downloading of various resources of a JNLP file to local files. It can be used to download icons, jnlp and extension files, jars, and jardiff files using the version based protocol or any file using the basic download protocol.
Resources can be put into download groups by specifying a part name for the resource. The resource tracker can also be configured to prefetch resources, which are downloaded in the order added to the media tracker.
Field Summary | |
static int |
CONNECT
|
static int |
CONNECTED
|
static int |
CONNECTING
|
static int |
DOWNLOAD
|
static int |
DOWNLOADED
|
static int |
DOWNLOADING
|
static int |
ERROR
|
static int |
STARTED
|
static int |
UNINITIALIZED
status bits |
Method Summary | |
void |
addTracker(ResourceTracker tracker)
Adds the tracker to the list of trackers monitoring this resource. |
void |
changeStatus(int clear,
int add)
Changes the status by clearing the flags in the first parameter and setting the flags in the second. |
boolean |
equals(java.lang.Object other)
|
protected void |
fireDownloadEvent()
Instructs the trackers monitoring this resource to fire a download event. |
java.net.URL |
getLocation()
Returns the remote location of the resource. |
static Resource |
getResource(java.net.URL location,
Version requestVersion)
Return a shared Resource object representing the given location and version. |
boolean |
isSet(int flag)
Returns true if any of the specified flags are set. |
void |
removeTracker(ResourceTracker tracker)
Removes the tracker to the list of trackers monitoring this resource. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int UNINITIALIZED
public static final int CONNECT
public static final int CONNECTING
public static final int CONNECTED
public static final int DOWNLOAD
public static final int DOWNLOADING
public static final int DOWNLOADED
public static final int ERROR
public static final int STARTED
Method Detail |
public static Resource getResource(java.net.URL location, Version requestVersion)
public java.net.URL getLocation()
public boolean isSet(int flag)
public void changeStatus(int clear, int add)
public void removeTracker(ResourceTracker tracker)
public void addTracker(ResourceTracker tracker)
protected void fireDownloadEvent()
public boolean equals(java.lang.Object other)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |