public abstract class PartitionedWriter<T> extends BaseTaskWriter<T>
BaseTaskWriter.BaseEqualityDeltaWriter, BaseTaskWriter.RollingEqDeleteWriter, BaseTaskWriter.RollingFileWriter
Modifier | Constructor and Description |
---|---|
protected |
PartitionedWriter(PartitionSpec spec,
FileFormat format,
FileAppenderFactory<T> appenderFactory,
OutputFileFactory fileFactory,
FileIO io,
long targetFileSize) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
protected abstract PartitionKey |
partition(T row)
Create a PartitionKey from the values in row.
|
void |
write(T row)
Write the row into the data files.
|
abort, complete, spec
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
dataFiles
protected PartitionedWriter(PartitionSpec spec, FileFormat format, FileAppenderFactory<T> appenderFactory, OutputFileFactory fileFactory, FileIO io, long targetFileSize)
protected abstract PartitionKey partition(T row)
Any PartitionKey returned by this method can be reused by the implementation.
row
- a data rowpublic void write(T row) throws java.io.IOException
TaskWriter
java.io.IOException
public void close() throws java.io.IOException
java.io.IOException