Package org.eclipse.jetty.start
Class FileInitializer
java.lang.Object
org.eclipse.jetty.start.FileInitializer
- Direct Known Subclasses:
BaseHomeFileInitializer
,DownloadFileInitializer
,LocalFileInitializer
,TestFileInitializer
Interface for initializing a file resource.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
copyDirectory
(Path source, Path destination) abstract boolean
Initialize a file resourceprotected Path
getDestination
(URI uri, String location) boolean
isApplicable
(URI uri) protected boolean
isFilePresent
(Path... paths) Test if any of the Paths exist (as files)
-
Field Details
-
_scheme
-
_basehome
-
-
Constructor Details
-
FileInitializer
-
-
Method Details
-
isApplicable
-
create
Initialize a file resource- Parameters:
uri
- the URI of the resource acting as its sourcelocation
- the simple string reference to the output file, suitable for searching for the file in other locations (like ${jetty.home} or ${jetty.dir}) *- Returns:
- true if local file system is modified.
- Throws:
IOException
- if there was an attempt to initialize, but an error occurred.
-
check
- Throws:
IOException
-
getDestination
- Throws:
IOException
-
isFilePresent
Test if any of the Paths exist (as files)- Parameters:
paths
- the list of paths to check- Returns:
- true if the path exist (as a file), false if it doesn't exist
- Throws:
IOException
- if the path points to a non-file, or is not readable.
-
copyDirectory
- Throws:
IOException
-