Package org.godot.utilities.utils
Class IOUtils
- java.lang.Object
-
- org.godot.utilities.utils.IOUtils
-
public final class IOUtils extends Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static @Nullable StringgetExtension(Path location)Get file extensions from pathstatic @Nullable List<Path>walkDirectory(Path location, boolean recursive, Predicate<Path>... filters)Walk directory with filtersstatic @Nullable List<Path>walkDirectory(Path location, Predicate<Path>... filters)Walk directory with filters
-
-
-
Method Detail
-
walkDirectory
@SafeVarargs @Nullable public static @Nullable List<Path> walkDirectory(Path location, boolean recursive, Predicate<Path>... filters) throws IOException
Walk directory with filters- Parameters:
location- Target locationfilters- Custom search filterrecursive- Determine if walk is recursive or not- Returns:
- Return a lis with all filter elements
- Throws:
IOException- if an I/O error is thrown when accessing the starting file.
-
walkDirectory
@SafeVarargs @Nullable public static @Nullable List<Path> walkDirectory(Path location, Predicate<Path>... filters) throws IOException
Walk directory with filters- Parameters:
location- Target locationfilters- Custom search filter- Returns:
- Return a lis with all filter elements
- Throws:
IOException- if an I/O error is thrown when accessing the starting file.
-
-