|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.avalon.repository.util.LoaderUtils
Utility class supporting downloading of resources based on artifact references.
Constructor Summary | |
LoaderUtils()
|
Method Summary | |
static URL |
getResource(Artifact artifact,
String[] repositories,
File root,
boolean timestamping)
Attempts to download and cache a remote artifact trying a set of remote repositories. |
static URL |
getResource(Artifact artifact,
String mime,
String[] repositories,
File root,
boolean timestamping)
Attempts to download and cache a remote artifact trying a set of remote repositories. |
static URL |
getResource(String url,
File destination,
boolean timestamping)
Retrieve a remote file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public LoaderUtils()
Method Detail |
public static URL getResource(Artifact artifact, String[] repositories, File root, boolean timestamping) throws RepositoryException
artifact
- the artifact to retrieve and cacherepositories
- the remote repositories to try to download fromroot
- the root cache directorytimestamping
- whether to check the modified timestamp on the
destinationFile
against the remote source
RepositoryException
public static URL getResource(Artifact artifact, String mime, String[] repositories, File root, boolean timestamping) throws RepositoryException
artifact
- the artifact to retrieve and cachemime
- the mime typerepositories
- the remote repositories to try to download fromroot
- the root cache directorytimestamping
- whether to check the modified timestamp on the
destinationFile
against the remote source
RepositoryException
public static URL getResource(String url, File destination, boolean timestamping) throws Exception
url
- the of the file to retrievedestination
- where to store ittimestamping
- whether to check the modified timestamp on the
destinationFile
against the remote source
Exception
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |