| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static String | Returns: the path specification, ornull if the name is not validthe basic module name moduleName)Convert a "basic" module name to a relative path specification. |
| public static String | Returns: the canonical paththe relative or absolute possibly non-canonical path path)Canonicalize the given path. |
| pack-priv static <T> Map | deduplicateLists(Map<String, List<T>> allPaths)
Takes a list of maps an returns an immutable representation of the same map, with all duplicate lists coalesced into a single object, and with all lists replaced by immutable array lists that has a backing array that is the correct size for the number of contents. |
| public static String | Returns: the file namethe path name path)Get the file name (last) segment of the given path. |
| public static < the collection type T extends Collection | Returns: thetarget setthe source paths source, PathFilter the filter to apply filter, T the destination for filtered paths target)Filter the paths from |
| public static Set | Returns: the set, ornull if the paths could not be determinedthe class loader to inspect classLoader)Attempt to get a set of all paths defined directly by the given class loader. |
| private static boolean | |
| public static boolean | |
| public static boolean | Returns: true if the child is truly a direct child of parentthe parent path parent, final String the child path child)Determine whether one path is a direct (or immediate) child of another. |
| public static boolean | Returns: true if it is relativethe path name path)Determine whether a path name is relative. |
| public static boolean | Returns: true if it is a separatorthe character to test ch)Determine whether the given character is a |
| public static String | |
| public static String | Returns: the same string with OS-specific separators replaced with/the original string original)Get the given path name with OS-specific separators replaced with the generic |
| PathUtils | back to summary |
|---|---|
| private PathUtils() | |
| basicModuleNameToPath | back to summary |
|---|---|
| public static String basicModuleNameToPath(final String moduleName) Convert a "basic" module name to a relative path specification. | |
| canonicalize | back to summary |
|---|---|
| public static String canonicalize(String path) Canonicalize the given path. Removes all | |
| deduplicateLists | back to summary |
|---|---|
| pack-priv static <T> Map Takes a list of maps an returns an immutable representation of the same map, with all duplicate lists coalesced into a single object, and with all lists replaced by immutable array lists that has a backing array that is the correct size for the number of contents. This can result in a significant memory saving for some use cases | |
| fileNameOfPath | back to summary |
|---|---|
| public static String fileNameOfPath(String path) Get the file name (last) segment of the given path. | |
| filterPaths | back to summary |
|---|---|
| public static <T extends Collection Filter the paths from
| |
| getPathSet | back to summary |
|---|---|
| public static Set Attempt to get a set of all paths defined directly by the given class loader. If the path set cannot be
ascertained,
| |
| isAllowedPunct | back to summary |
|---|---|
| private static boolean isAllowedPunct(final int cp) | |
| isChild | back to summary |
|---|---|
| public static boolean isChild(final String parent, final String child) Determine whether one path is a child of another. | |
| isDirectChild | back to summary |
|---|---|
| public static boolean isDirectChild(final String parent, final String child) Determine whether one path is a direct (or immediate) child of another. | |
| isRelative | back to summary |
|---|---|
| public static boolean isRelative(final String path) Determine whether a path name is relative.
| |
| isSeparator | back to summary |
|---|---|
| public static boolean isSeparator(final char ch) Determine whether the given character is a
| |
| relativize | back to summary |
|---|---|
| public static String relativize(String path) Relativize the given path. Removes any leading | |
| toGenericSeparators | back to summary |
|---|---|
| public static String toGenericSeparators(String original) Get the given path name with OS-specific separators replaced with the generic | |