public class S3InputStream extends InputStream
S3Object getDataInputStream. The main purpose is to provide a
faster skip method, as the underlying implementation will read and discard bytes until the
number to skip has been reached. This input stream returns 0 when calling read with an
empty buffer.| Modifier and Type | Method and Description |
|---|---|
void |
close() |
int |
read() |
int |
read(byte[] b,
int off,
int len) |
long |
skip(long n)
This method leverages the ability to open a stream from S3 from a given offset.
|
available, mark, markSupported, read, resetpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class InputStreamIOExceptionpublic int read()
throws IOException
read in class InputStreamIOExceptionpublic int read(byte[] b,
int off,
int len)
throws IOException
read in class InputStreamIOExceptionpublic long skip(long n)
throws IOException
skip in class InputStreamn - number of bytes to skipIOException - if an error occurs when requesting from S3Copyright © 2015. All Rights Reserved.