public interface DirectoryView extends FileTreeView
FileTreeView.list(Path, int, Filter) method will only
return non-empty results for paths that are children of the root directory, specified by getTypedPath().| Modifier and Type | Method and Description |
|---|---|
int |
getMaxDepth()
Returns the maximum depth of children of subdirectories to include below the path specified by
getTypedPath(). |
java.nio.file.Path |
getPath()
Return the path of the root directory.
|
TypedPath |
getTypedPath()
Return the typed path of the root directory.
|
java.util.List<TypedPath> |
list(int maxDepth,
Filter<? super TypedPath> filter)
List all of the files in the root directory, returning only those files that are accepted by
the provided filter.
|
listjava.nio.file.Path getPath()
TypedPath getTypedPath()
java.util.List<TypedPath> list(int maxDepth, Filter<? super TypedPath> filter) throws java.io.IOException
maxDepth - the maximum depth of subdirectories to queryfilter - include only paths accepted by the filterPath instances accepted by the filter.java.io.IOException - if there is an error listing the directory.int getMaxDepth()
getTypedPath(). For example, when the value is -1, then the
DirectoryView should include only itself. When the value is 0, it should include
all of the subdirectories and files in the path. When the value is 1, it should
include all of the subdirectories and files in the path and all of the subdirectories and files
in the immediate subdirectories of the path, but not the children of these nested
subdirectories. When the value is Integer.MAX_VALUE, all children of the path are
included.