public class HasherInputStream extends FilterInputStream
InputStream which appends the hash of the data read from it to a Hasher. As
opposed to HashingInputStream, users can wrap an existing Hasher which makes this more flexible when building more complex hashes.in| Constructor and Description |
|---|
HasherInputStream(com.google.common.hash.Hasher hasher,
InputStream in) |
| Modifier and Type | Method and Description |
|---|---|
void |
mark(int readlimit) |
boolean |
markSupported() |
int |
read() |
int |
read(byte[] bytes,
int off,
int len) |
void |
reset() |
available, close, read, skippublic HasherInputStream(com.google.common.hash.Hasher hasher,
InputStream in)
public int read()
throws IOException
read in class FilterInputStreamIOExceptionpublic int read(@Nonnull byte[] bytes, int off, int len) throws IOException
read in class FilterInputStreamIOExceptionpublic boolean markSupported()
markSupported in class FilterInputStreampublic void mark(int readlimit)
mark in class FilterInputStreampublic void reset()
throws IOException
reset in class FilterInputStreamIOException