| Modifier and Type | Field and Description |
|---|---|
| private final long | |
| private long |
| Access | Constructor and Description |
|---|---|
| public | ChecksumVerifyingInputStream(final Checksum
Checksum implementation. checksum, final InputStream the stream to wrap in, final long the of the stream's content size, final long the expected checksum expectedChecksum)Constructs a new instance. |
| Modifier and Type | Method and Description |
|---|---|
| public long | |
| public int | |
| public int | read(final byte[]
the buffer into which the data is read b, final int the start offset in the destination array off, final int bthe maximum number of bytes read len)Overrides java. |
| private void |
| expected | back to summary |
|---|---|
| private final long expected | |
| remaining | back to summary |
|---|---|
| private long remaining | |
| ChecksumVerifyingInputStream | back to summary |
|---|---|
| public ChecksumVerifyingInputStream(final Checksum checksum, final InputStream in, final long size, final long expectedChecksum) Constructs a new instance.
| |
| getBytesRemaining | back to summary |
|---|---|
| public long getBytesRemaining() Gets the byte count remaining to read.
| |
| read | back to summary |
|---|---|
| public int read() throws IOException Overrides java. Reads a single byte from the stream
| |
| read | back to summary |
|---|---|
| public int read(final byte[] b, final int off, final int len) throws IOException Overrides java. Reads from the stream into a byte array.
| |
| verify | back to summary |
|---|---|
| private void verify() throws IOException | |