@NotThreadSafe public static class Paths.Splitter extends Object
| Modifier and Type | Field and Description |
|---|---|
private int |
fixum |
private String |
memberName |
private String |
parentPath |
private char |
separatorChar |
| Constructor and Description |
|---|
Paths.Splitter(char separatorChar,
boolean keepTrailingSeparator)
Constructs a new splitter.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getMemberName()
Returns the member name.
|
String |
getParentPath()
Returns the parent path name.
|
private static int |
lastIndexNot(String path,
char separatorChar,
int last) |
Paths.Splitter |
split(String path)
Splits the given path name into its parent path name and member name,
recognizing platform specific file system roots.
|
private final char separatorChar
private final int fixum
@CheckForNull private String parentPath
private String memberName
public Paths.Splitter(char separatorChar,
boolean keepTrailingSeparator)
separatorChar - the file name separator character.keepTrailingSeparator - whether or not a parent path name
should have a single trailing separator if present in the
original path name.public Paths.Splitter split(String path)
path - the name of the path which's parent path name and
member name are to be returned.thisprivate static int lastIndexNot(String path, char separatorChar, int last)
@Nullable public String getParentPath()
public String getMemberName()
Copyright © 2005-2011 Schlichtherle IT Services. All Rights Reserved.