Package com.norconex.commons.lang.io
Class ByteBufferInputStream
- java.lang.Object
-
- java.io.InputStream
-
- com.norconex.commons.lang.io.ByteBufferInputStream
-
- All Implemented Interfaces:
Closeable,AutoCloseable
public class ByteBufferInputStream extends InputStream
Wraps aByteBufferin anInputStream.- Since:
- 1.5
- Author:
- Pascal Essiembre
-
-
Constructor Summary
Constructors Constructor Description ByteBufferInputStream(ByteBuffer buf)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intread()intread(byte[] bytes, int off, int len)-
Methods inherited from class java.io.InputStream
available, close, mark, markSupported, nullInputStream, read, readAllBytes, readNBytes, readNBytes, reset, skip, transferTo
-
-
-
-
Constructor Detail
-
ByteBufferInputStream
public ByteBufferInputStream(ByteBuffer buf)
-
-
Method Detail
-
read
public int read() throws IOException- Specified by:
readin classInputStream- Throws:
IOException
-
read
public int read(byte[] bytes, int off, int len) throws IOException- Overrides:
readin classInputStream- Throws:
IOException
-
-