Module xyz.ronella.casual.trivial
Package xyz.ronella.trivial.handy
Class PathFinder.PathFinderBuilder
java.lang.Object
xyz.ronella.trivial.handy.PathFinder.PathFinderBuilder
- Enclosing class:
- PathFinder
The only class that can create an instance of PathFinder.
-
Method Summary
Modifier and TypeMethodDescriptionAdds an array of directories where to find first existence of the filename.Adds a list of directories where to find first existence of the filename.build()Build an instance of a PathFinder.setFallbackToClassloader(boolean fallbackToCL) Set this to load the file using classloader if it doesn't exist in any of the paths provided.
-
Method Details
-
build
Build an instance of a PathFinder.- Returns:
- An instance of PathFinder.
-
addPaths
Adds a list of directories where to find first existence of the filename.- Parameters:
dirs- A list of directories.- Returns:
- An instance of PathFinderBuilder.
-
addPaths
Adds an array of directories where to find first existence of the filename.- Parameters:
dirs- A list of directories.- Returns:
- An instance of PathFinderBuilder.
-
setFallbackToClassloader
Set this to load the file using classloader if it doesn't exist in any of the paths provided. This is only useful when using the PathFinder.processInputStream() method.- Parameters:
fallbackToCL- indicates whether to use the classloader as fallback.- Returns:
- An instance of PathFinderBuilder.
-