Class PathOperations
Object
PathOperations
Helper routines for performing operations on
Paths.- Author:
- Owen Feehan
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringconvertToString(Path path) Converts a path to a string, making sure it uses UNIX-style separators.static PathfilePathDifference(Path baseDirectoryPath, Path filePath) Finds the difference between a path and a base.
-
Method Details
-
filePathDifference
public static Path filePathDifference(Path baseDirectoryPath, Path filePath) throws PathDifferenceException Finds the difference between a path and a base.- Parameters:
baseDirectoryPath- path to a base directory.filePath- the path to resolve.- Returns:
- the difference between the paths.
- Throws:
PathDifferenceException- if the canonical file cannot be found.
-
convertToString
Converts a path to a string, making sure it uses UNIX-style separators.- Parameters:
path- the path to convert.- Returns:
- a converted path, with UNIX-style separators.
-