Package io.deephaven.io.streams
Class ByteBufferStreams.Input
java.lang.Object
java.io.InputStream
io.deephaven.io.streams.ByteBufferStreams.Input
- All Implemented Interfaces:
Closeable,DataInput,AutoCloseable
- Enclosing class:
- ByteBufferStreams
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionInput(ByteBuffer buf) Construct a new stream which reads from a byte bufferInput(ByteBuffer buf, ByteBufferStreams.Source source) Construct a new stream which reads from a byte buffer, and has a source for more buffers -
Method Summary
Modifier and TypeMethodDescriptionintvoidclose()voidmark(int readlimit) booleanintread()intread(byte[] b) intread(byte[] b, int off, int len) booleanbytereadByte()charreadChar()doublefloatvoidreadFully(byte[] b) voidreadFully(byte[] b, int off, int len) intreadInt()readLine()longreadLong()shortintintreadUTF()voidreset()voidsetBuffer(ByteBuffer buf) Set the buffer to be used for future read operations.longskip(long n) intskipBytes(int n) Methods inherited from class java.io.InputStream
nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Field Details
-
buf
the buffer from which we read
-
-
Constructor Details
-
Input
Construct a new stream which reads from a byte buffer -
Input
Construct a new stream which reads from a byte buffer, and has a source for more buffers
-
-
Method Details
-
setBuffer
Set the buffer to be used for future read operations. -
read
- Specified by:
readin classInputStream- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
skip
- Overrides:
skipin classInputStream- Throws:
IOException
-
available
- Overrides:
availablein classInputStream- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classInputStream- Throws:
IOException
-
mark
public void mark(int readlimit) - Overrides:
markin classInputStream
-
reset
- Overrides:
resetin classInputStream- Throws:
IOException
-
markSupported
public boolean markSupported()- Overrides:
markSupportedin classInputStream
-
readFully
- Specified by:
readFullyin interfaceDataInput- Throws:
IOException
-
readFully
- Specified by:
readFullyin interfaceDataInput- Throws:
IOException
-
skipBytes
- Specified by:
skipBytesin interfaceDataInput- Throws:
IOException
-
readBoolean
- Specified by:
readBooleanin interfaceDataInput- Throws:
IOException
-
readByte
- Specified by:
readBytein interfaceDataInput- Throws:
IOException
-
readUnsignedByte
- Specified by:
readUnsignedBytein interfaceDataInput- Throws:
IOException
-
readShort
- Specified by:
readShortin interfaceDataInput- Throws:
IOException
-
readUnsignedShort
- Specified by:
readUnsignedShortin interfaceDataInput- Throws:
IOException
-
readChar
- Specified by:
readCharin interfaceDataInput- Throws:
IOException
-
readInt
- Specified by:
readIntin interfaceDataInput- Throws:
IOException
-
readLong
- Specified by:
readLongin interfaceDataInput- Throws:
IOException
-
readFloat
- Specified by:
readFloatin interfaceDataInput- Throws:
IOException
-
readDouble
- Specified by:
readDoublein interfaceDataInput- Throws:
IOException
-
readLine
- Specified by:
readLinein interfaceDataInput- Throws:
IOException
-
readUTF
- Specified by:
readUTFin interfaceDataInput- Throws:
IOException
-