Package org.xwiki.velocity.tools.nio
Class WrappingDirectoryStream
- java.lang.Object
-
- org.xwiki.velocity.tools.nio.WrappingDirectoryStream
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Iterable<Path>
,DirectoryStream<Path>
public class WrappingDirectoryStream extends Object implements DirectoryStream<Path>
Wrap theDirectoryStream
returned byFiles.newDirectoryStream(java.nio.file.Path)
since the returned class may be private and Velocity tries to call it.See VELOCITY-870
- Since:
- 7.4M2
- Version:
- $Id: 0dbedc2c096df791cfdc8daa4a4f2bed80896822 $
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface java.nio.file.DirectoryStream
DirectoryStream.Filter<T extends Object>
-
-
Constructor Summary
Constructors Constructor Description WrappingDirectoryStream(DirectoryStream<Path> wrappedDirectoryStream)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Iterator<Path>
iterator()
-
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
-
-
-
-
Constructor Detail
-
WrappingDirectoryStream
public WrappingDirectoryStream(DirectoryStream<Path> wrappedDirectoryStream)
- Parameters:
wrappedDirectoryStream
- the instance we're wrapping
-
-
Method Detail
-
close
public void close() throws IOException
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-
-