Package org.apache.trevni
Class InputBytes
java.lang.Object
java.io.InputStream
java.io.ByteArrayInputStream
org.apache.trevni.InputBytes
- All Implemented Interfaces:
Closeable,AutoCloseable,Input
An
Input backed with data in a byte array.-
Field Summary
Fields inherited from class java.io.ByteArrayInputStream
buf, count, mark, pos -
Constructor Summary
ConstructorsConstructorDescriptionInputBytes(byte[] data) Construct for the given bytes.InputBytes(ByteBuffer data) Construct for the given bytes. -
Method Summary
Methods inherited from class java.io.ByteArrayInputStream
available, close, mark, markSupported, read, read, readAllBytes, readNBytes, reset, skip, transferToMethods inherited from class java.io.InputStream
nullInputStream, read, readNBytes
-
Constructor Details
-
InputBytes
public InputBytes(byte[] data) Construct for the given bytes. -
InputBytes
Construct for the given bytes.
-
-
Method Details
-
length
Description copied from interface:InputReturn the total length of the input.- Specified by:
lengthin interfaceInput- Throws:
IOException
-
read
Description copied from interface:InputPositioned read.- Specified by:
readin interfaceInput- Throws:
IOException
-