public abstract class SizeSegmentingOutputWriter extends ItemSegmentingOutputWriter<ByteBuffer>
Constructor and Description |
---|
SizeSegmentingOutputWriter(long segmentSizeLimit) |
Modifier and Type | Method and Description |
---|---|
void |
beginShard()
Will be called once before any calls to write.
|
protected OutputWriter<ByteBuffer> |
createNextWriter(int fileNum) |
protected abstract OutputWriter<ByteBuffer> |
createWriter(int fileNum) |
protected boolean |
shouldSegment(ByteBuffer value) |
void |
write(ByteBuffer value)
Writes a value to the output.
|
allowSliceRetry, estimateMemoryRequirement, getContext, getDelegate, setContext
beginSlice, endShard, endSlice
cleanup, close, open
public SizeSegmentingOutputWriter(long segmentSizeLimit)
public void beginShard() throws IOException
OutputWriter
beginShard
in class ItemSegmentingOutputWriter<ByteBuffer>
IOException
- in the event of failureprotected boolean shouldSegment(ByteBuffer value)
shouldSegment
in class ItemSegmentingOutputWriter<ByteBuffer>
public void write(ByteBuffer value) throws IOException
OutputWriter
write
in class ItemSegmentingOutputWriter<ByteBuffer>
IOException
protected final OutputWriter<ByteBuffer> createNextWriter(int fileNum)
createNextWriter
in class ItemSegmentingOutputWriter<ByteBuffer>
protected abstract OutputWriter<ByteBuffer> createWriter(int fileNum)
Copyright © 2015 Google. All rights reserved.