java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
net.i2p.i2ptunnel.util.GunzipOutputStream.CRC32OutputStream
- All Implemented Interfaces:
Closeable, Flushable, AutoCloseable
- Enclosing class:
GunzipOutputStream
Calculate CRC32 along the way.
Field Summary
Fields inherited from class FilterOutputStream
outConstructor Summary
ConstructorsMethod Summary
All MethodsMethods inherited from class FilterOutputStream
close, flush, writeMethods inherited from class OutputStream
nullOutputStream
Field Details
_crc32
Running CRC of the data written.
Constructor Details
CRC32OutputStream
Wraps a stream, tracking its CRC.- Parameters:
out- the stream to wrap
Method Details
write
- Overrides:
writein classFilterOutputStream- Throws:
IOException
write
- Overrides:
writein classFilterOutputStream- Throws:
IOException
getValue
public long getValue()Returns the CRC of the data written.- Returns:
- the CRC32 value