| Constructor and Description |
|---|
Path()
Constructs an empty path chain.
|
Path(String osPathString)
Constructs a chain of paths from
|
Path(String[] elements)
Constructs a chain of paths from
|
Path(String osPathString,
String pathSep)
Constructs a chain of paths from
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addAll(List<String> pathEls) |
void |
append(Path path) |
void |
append(String element) |
protected void |
normalizeFileSeps() |
File |
resolveFile(String relativeFile) |
String |
toString() |
public Path()
public Path(String osPathString)
osPathStringusing a default platform path separator (i.e. the File.pathSeparator value). All file separators within a path are being normalized to have unix-style endings.
Path(String, String)public Path(String osPathString, String pathSep)
osPathStringusing a specified
pathSeppath separator. All file separators within a path are being normalized to have unix-style endings. Example:
new Path("/my/path1:\my\path2", ":")
will internally keep
/my/path1
/my/path2
public Path(String[] elements)
elementsarray. All file separators within a path are being normalized to have unix-style endings.
public void append(String element)
public void append(Path path)
public File resolveFile(String relativeFile)
relativeFile - the relative file to search for. Always treated as a relative path: /foo.txt == foo.txtprotected void normalizeFileSeps()
Copyright © 2024 OpenClover.org. All rights reserved.