onVisitFile
abstract fun onVisitFile(function: (file: Path, attributes: BasicFileAttributes) -> FileVisitResult)(source)
Overrides the corresponding function of the built FileVisitor with the provided function.
The provided callback is invoked when a file is visited. Depending on the return value of the function:
FileVisitResult.CONTINUE or FileVisitResult.SKIP_SUBTREE - Traversal continues to a sibling entry.
FileVisitResult.SKIP_SIBLINGS - Sibling entries of the file are not visited.
FileVisitResult.TERMINATE - The traversal terminates immediately, and no further entries are visited.
By default, FileVisitor.visitFile of the built file visitor returns FileVisitResult.CONTINUE.