Package org.apache.iceberg.io
Class SeekableInputStream
java.lang.Object
java.io.InputStream
org.apache.iceberg.io.SeekableInputStream
- All Implemented Interfaces:
Closeable
,AutoCloseable
- Direct Known Subclasses:
AesGcmInputStream
,ByteBufferInputStream
SeekableInputStream
is an interface with the methods needed to read data from a file or
Hadoop data stream.
This class is based on Parquet's SeekableInputStream.
-
Constructor Summary
-
Method Summary
Methods inherited from class java.io.InputStream
available, close, mark, markSupported, nullInputStream, read, read, read, readAllBytes, readNBytes, readNBytes, reset, skip, skipNBytes, transferTo
-
Constructor Details
-
SeekableInputStream
public SeekableInputStream()
-
-
Method Details
-
getPos
Return the current position in the InputStream.- Returns:
- current position in bytes from the start of the stream
- Throws:
IOException
- If the underlying stream throws IOException
-
seek
Seek to a new position in the InputStream.- Parameters:
newPos
- the new position to seek to- Throws:
IOException
- If the underlying stream throws IOException
-