Package org.apache.parquet.cli.util
Class SeekableFSDataInputStream
- java.lang.Object
-
- java.io.InputStream
-
- org.apache.parquet.cli.util.SeekableFSDataInputStream
-
- All Implemented Interfaces:
Closeable,AutoCloseable,org.apache.avro.file.SeekableInput
public class SeekableFSDataInputStream extends InputStream implements org.apache.avro.file.SeekableInput
A wrapper for FSDataInputStream that implements Avro's SeekableInput.
-
-
Constructor Summary
Constructors Constructor Description SeekableFSDataInputStream(org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path file)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()longlength()intread()intread(byte[] b)intread(byte[] b, int off, int len)voidseek(long p)longtell()-
Methods inherited from class java.io.InputStream
available, mark, markSupported, nullInputStream, readAllBytes, readNBytes, readNBytes, reset, skip, transferTo
-
-
-
-
Constructor Detail
-
SeekableFSDataInputStream
public SeekableFSDataInputStream(org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path file) throws IOException- Throws:
IOException
-
-
Method Detail
-
seek
public void seek(long p) throws IOException- Specified by:
seekin interfaceorg.apache.avro.file.SeekableInput- Throws:
IOException
-
tell
public long tell() throws IOException- Specified by:
tellin interfaceorg.apache.avro.file.SeekableInput- Throws:
IOException
-
length
public long length() throws IOException- Specified by:
lengthin interfaceorg.apache.avro.file.SeekableInput- Throws:
IOException
-
read
public int read(byte[] b) throws IOException- Overrides:
readin classInputStream- Throws:
IOException
-
read
public int read() throws IOException- Specified by:
readin classInputStream- Throws:
IOException
-
read
public int read(byte[] b, int off, int len) throws IOException- Specified by:
readin interfaceorg.apache.avro.file.SeekableInput- Overrides:
readin classInputStream- Throws:
IOException
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classInputStream- Throws:
IOException
-
-