public class UriFileInitializer extends Object implements FileInitializer
| Constructor and Description |
|---|
UriFileInitializer(BaseHome baseHome) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
download(URI uri,
Path file) |
boolean |
init(URI uri,
Path file,
String fileRef)
Initialize a file resource
|
protected boolean |
isFilePresent(Path... paths)
Test if any of the Paths exist (as files)
|
protected final BaseHome baseHome
public UriFileInitializer(BaseHome baseHome)
public boolean init(URI uri, Path file, String fileRef) throws IOException
FileInitializerinit in interface FileInitializeruri - the remote URI of the resource acting as its sourcefile - the local file resource to initialize. (often in ${jetty.base} directory)fileRef - the simple string reference to the output file, suitable for searching
for the file in other locations (like ${jetty.home} or ${jetty.dir})FileInitializer did nothing.IOException - if there was an attempt to initialize, but an error occurred.protected void download(URI uri, Path file) throws IOException
IOExceptionprotected boolean isFilePresent(Path... paths) throws IOException
paths - the list of paths to checkIOException - if the path points to a non-file, or is not readable.Copyright © 1995–2016 Mort Bay Consulting. All rights reserved.