Open cayhorstmann opened 8 months ago
I think it's supposed to refer to java.util.stream.Stream
.
However, it neither implements Stream
nor InputStream
nor OutputStream
so I assume it's just wrong/a simple mistake instead of a confusing statement.
In https://dev.java/learn/java-io/file-system/listing/, it says:
Remember: The returned DirectoryStream is a stream. If you are not using a try-with-resources statement, do not forget to close the stream in the finally block. The try-with-resources statement takes care of this for you. You can learn more about stream in the Stream section.
What does "...is a stream" mean? A
java.util.stream.Stream
? Ajava.io.InputStream
orjava.io.OutputStream
? It is neither. Maybe the author meant "...is anAutoCloseable
"?