Package io.atomix.raft.snapshot.impl
Class SnapshotChunkImpl
java.lang.Object
io.atomix.raft.snapshot.SbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
io.atomix.raft.snapshot.impl.SnapshotChunkImpl
- All Implemented Interfaces:
SnapshotChunk,BufferReader,BufferWriter
public final class SnapshotChunkImpl
extends SbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
implements SnapshotChunk
-
Field Summary
Fields inherited from class io.atomix.raft.snapshot.SbeBufferWriterReader
headerDecoder, headerEncoder -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected SnapshotChunkDecoderprotected SnapshotChunkEncoderlongbyte[]longintintlongvoidreset()toString()voidwrap(org.agrona.DirectBuffer buffer, int offset, int length) voidwrite(org.agrona.MutableDirectBuffer buffer, int offset) Methods inherited from class io.atomix.raft.snapshot.SbeBufferWriterReader
toByteBuffer, toBytes, tryWrap, tryWrap, wrapMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface io.camunda.zeebe.util.buffer.BufferReader
copyFrom
-
Constructor Details
-
SnapshotChunkImpl
public SnapshotChunkImpl() -
SnapshotChunkImpl
-
-
Method Details
-
getBodyEncoder
- Specified by:
getBodyEncoderin classSbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
-
getBodyDecoder
- Specified by:
getBodyDecoderin classSbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
-
reset
public void reset()- Overrides:
resetin classSbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
-
getLength
public int getLength()- Specified by:
getLengthin interfaceBufferWriter- Overrides:
getLengthin classSbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
-
write
public void write(org.agrona.MutableDirectBuffer buffer, int offset) - Specified by:
writein interfaceBufferWriter- Overrides:
writein classSbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
-
wrap
public void wrap(org.agrona.DirectBuffer buffer, int offset, int length) - Specified by:
wrapin interfaceBufferReader- Overrides:
wrapin classSbeBufferWriterReader<SnapshotChunkEncoder,SnapshotChunkDecoder>
-
getSnapshotId
- Specified by:
getSnapshotIdin interfaceSnapshotChunk
-
getTotalCount
public int getTotalCount()- Specified by:
getTotalCountin interfaceSnapshotChunk
-
getChunkName
- Specified by:
getChunkNamein interfaceSnapshotChunk
-
getChecksum
public long getChecksum()- Specified by:
getChecksumin interfaceSnapshotChunk
-
getContent
public byte[] getContent()- Specified by:
getContentin interfaceSnapshotChunk
-
getFileBlockPosition
public long getFileBlockPosition()- Specified by:
getFileBlockPositionin interfaceSnapshotChunk
-
getTotalFileSize
public long getTotalFileSize()- Specified by:
getTotalFileSizein interfaceSnapshotChunk
-
toString
-