public class PathContentProvider extends Object implements ContentProvider
ContentProvider for files using JDK 7's java.nio.file APIs.
It is possible to specify, at the constructor, a buffer size used to read content from the
stream, by default 4096 bytes.| Constructor and Description |
|---|
PathContentProvider(Path filePath) |
PathContentProvider(Path filePath,
int bufferSize) |
| Modifier and Type | Method and Description |
|---|---|
long |
getLength() |
Iterator<ByteBuffer> |
iterator() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorpublic PathContentProvider(Path filePath) throws IOException
IOExceptionpublic PathContentProvider(Path filePath, int bufferSize) throws IOException
IOExceptionpublic long getLength()
getLength in interface ContentProviderpublic Iterator<ByteBuffer> iterator()
iterator in interface Iterable<ByteBuffer>Copyright © 1995-2023 Mort Bay Consulting. All Rights Reserved.