public final class BufferedChecksumStreamOutput extends StreamOutput
StreamOutput
so anything written will update the checksumConstructor and Description |
---|
BufferedChecksumStreamOutput(StreamOutput out) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes this stream to further operations.
|
void |
flush()
Forces any buffered output to be written.
|
long |
getChecksum() |
void |
reset() |
void |
resetDigest() |
void |
writeByte(byte b)
Writes a single byte.
|
void |
writeBytes(byte[] b,
int offset,
int length)
Writes an array of bytes.
|
getVersion, position, seek, setVersion, write, write, writeArray, writeBoolean, writeByteArray, writeBytes, writeBytes, writeBytesRef, writeBytesReference, writeDouble, writeDoubleArray, writeEnum, writeException, writeFloat, writeFloatArray, writeGenericValue, writeGeoPoint, writeInt, writeIntArray, writeList, writeLong, writeLongArray, writeMap, writeMap, writeMapOfLists, writeMapWithConsistentOrder, writeNamedWriteable, writeNamedWriteableList, writeOptionalArray, writeOptionalBoolean, writeOptionalBytesReference, writeOptionalDouble, writeOptionalFloat, writeOptionalLong, writeOptionalNamedWriteable, writeOptionalStreamable, writeOptionalString, writeOptionalStringArray, writeOptionalText, writeOptionalTimeZone, writeOptionalVInt, writeOptionalWriteable, writeShort, writeStreamableList, writeString, writeStringArray, writeStringArrayNullable, writeStringList, writeText, writeTimeZone, writeVInt, writeVIntArray, writeVLong, writeVLongArray, writeZLong
public BufferedChecksumStreamOutput(StreamOutput out)
public long getChecksum()
public void writeByte(byte b) throws java.io.IOException
StreamOutput
writeByte
in class StreamOutput
java.io.IOException
public void writeBytes(byte[] b, int offset, int length) throws java.io.IOException
StreamOutput
writeBytes
in class StreamOutput
b
- the bytes to writeoffset
- the offset in the byte arraylength
- the number of bytes to writejava.io.IOException
public void flush() throws java.io.IOException
StreamOutput
flush
in interface java.io.Flushable
flush
in class StreamOutput
java.io.IOException
public void close() throws java.io.IOException
StreamOutput
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class StreamOutput
java.io.IOException
public void reset() throws java.io.IOException
reset
in class StreamOutput
java.io.IOException
public void resetDigest()