Package org.apache.lucene.tests.mockfile
Class FilterDirectoryStream
java.lang.Object
org.apache.lucene.tests.mockfile.FilterDirectoryStream
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Iterable<Path>
,DirectoryStream<Path>
A
FilterDirectoryStream
contains another DirectoryStream
, which it uses as its
basic source of data, possibly transforming the data along the way or providing additional
functionality.-
Nested Class Summary
Nested classes/interfaces inherited from interface java.nio.file.DirectoryStream
DirectoryStream.Filter<T extends Object>
-
Field Summary
Modifier and TypeFieldDescriptionprotected final DirectoryStream<Path>
The underlyingDirectoryStream
instance.protected final FileSystem
The underlyingFileSystem
instance. -
Constructor Summary
ConstructorDescriptionFilterDirectoryStream
(DirectoryStream<Path> delegate, FileSystem fileSystem) Construct aFilterDirectoryStream
based on the specified base stream. -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
delegate
The underlyingDirectoryStream
instance. -
fileSystem
The underlyingFileSystem
instance.
-
-
Constructor Details
-
FilterDirectoryStream
Construct aFilterDirectoryStream
based on the specified base stream.Note that base stream is closed if this stream is closed.
- Parameters:
delegate
- specified base stream.
-
-
Method Details
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-
iterator
-