Package org.h2.store
Class DataReader
java.lang.Object
java.io.Reader
org.h2.store.DataReader
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Readable
This class is backed by an input stream and supports reading values and
variable size data.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static class
Constructing such an EOF exception is fast, because the stack trace is not filled in. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.io.Reader
mark, markSupported, nullReader, read, read, read, ready, reset, skip, transferTo
-
Field Details
-
in
-
-
Constructor Details
-
DataReader
Create a new data reader.- Parameters:
in
- the input stream
-
-
Method Details
-
readByte
Read a byte.- Returns:
- the byte
- Throws:
IOException
- on failure
-
readVarInt
Read a variable size integer.- Returns:
- the value
- Throws:
IOException
- on failure
-
readChar
Read one character from the input stream.- Returns:
- the character
- Throws:
IOException
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in classReader
- Throws:
IOException
-
read
- Specified by:
read
in classReader
- Throws:
IOException
-