O - type of values accepted by this outputpublic abstract class ForwardingOutputWriter<O> extends OutputWriter<O>
| Constructor and Description |
|---|
ForwardingOutputWriter() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
allowSliceRetry() |
void |
beginShard()
Will be called once before any calls to write.
|
void |
beginSlice()
Prepares the writer for writing after possibly having gone through
serialization or deserialization.
|
void |
endShard()
Called when no more output will be written to this writer.
|
void |
endSlice()
Prepares the writer for possible serialization.
|
long |
estimateMemoryRequirement()
Returns the estimated memory that will be used by this writer in bytes.
|
ShardContext |
getContext()
Returns the current context, or null if none.
|
protected abstract OutputWriter<?> |
getDelegate() |
void |
setContext(ShardContext context)
Used internally to sets the context to be used for the processing that follows.
|
cleanup, close, open, writeprotected abstract OutputWriter<?> getDelegate()
public void beginShard()
throws IOException
OutputWriterbeginShard in class OutputWriter<O>IOException - in the event of failurepublic void beginSlice()
throws IOException
OutputWriterbeginSlice in class OutputWriter<O>IOException - in the event of failurepublic void endSlice()
throws IOException
OutputWriterendSlice in class OutputWriter<O>IOException - in the event of failurepublic void endShard()
throws IOException
OutputWriterendShard in class OutputWriter<O>IOExceptionpublic long estimateMemoryRequirement()
OutputWriterestimateMemoryRequirement in class OutputWriter<O>public void setContext(ShardContext context)
OutputWritersetContext in class OutputWriter<O>public ShardContext getContext()
OutputWritergetContext in class OutputWriter<O>public boolean allowSliceRetry()
allowSliceRetry in class OutputWriter<O>Copyright © 2015 Google. All rights reserved.