@InterfaceAudience.Private @InterfaceStability.Unstable public class IFileInputStream extends InputStream
IFileOutputStream.| Modifier and Type | Field and Description |
|---|---|
static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
IFileInputStream(InputStream in,
long len,
org.apache.hadoop.conf.Configuration conf)
Create a checksum input stream that reads
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the input stream.
|
byte[] |
getChecksum() |
long |
getPosition() |
long |
getSize() |
int |
read() |
int |
read(byte[] b,
int off,
int len)
Read bytes from the stream.
|
int |
readWithChecksum(byte[] b,
int off,
int len)
Read bytes from the stream.
|
long |
skip(long n) |
available, mark, markSupported, read, resetpublic IFileInputStream(InputStream in, long len, org.apache.hadoop.conf.Configuration conf)
in - The input stream to be verified for checksum.len - The length of the input stream including checksum bytes.public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class InputStreamIOExceptionpublic long skip(long n)
throws IOException
skip in class InputStreamIOExceptionpublic long getPosition()
public long getSize()
public int read(byte[] b,
int off,
int len)
throws IOException
read in class InputStreamIOExceptionpublic int readWithChecksum(byte[] b,
int off,
int len)
throws IOException
IOExceptionpublic int read()
throws IOException
read in class InputStreamIOExceptionpublic byte[] getChecksum()
Copyright © 2008–2019 Apache Software Foundation. All rights reserved.