public class EqualityDeleteWriter<T> extends java.lang.Object implements FileWriter<T,DeleteWriteResult>
Constructor and Description |
---|
EqualityDeleteWriter(FileAppender<T> appender,
FileFormat format,
java.lang.String location,
PartitionSpec spec,
StructLike partition,
EncryptionKeyMetadata keyMetadata,
SortOrder sortOrder,
int... equalityFieldIds) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
delete(T row)
Deprecated.
since 0.13.0, will be removed in 0.14.0; use
write(Object) instead. |
void |
deleteAll(java.lang.Iterable<T> rows)
Deprecated.
since 0.13.0, will be removed in 0.14.0; use
FileWriter.write(Iterable) instead. |
long |
length()
Returns the number of bytes that were currently written by this writer.
|
DeleteWriteResult |
result()
Returns a result that contains information about written
DataFile s or DeleteFile s. |
DeleteFile |
toDeleteFile() |
void |
write(T row)
Writes a row to a predefined spec/partition.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
write
public EqualityDeleteWriter(FileAppender<T> appender, FileFormat format, java.lang.String location, PartitionSpec spec, StructLike partition, EncryptionKeyMetadata keyMetadata, SortOrder sortOrder, int... equalityFieldIds)
public void write(T row)
FileWriter
write
in interface FileWriter<T,DeleteWriteResult>
row
- a data or delete record@Deprecated public void deleteAll(java.lang.Iterable<T> rows)
FileWriter.write(Iterable)
instead.@Deprecated public void delete(T row)
write(Object)
instead.public long length()
FileWriter
length
in interface FileWriter<T,DeleteWriteResult>
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
java.io.IOException
public DeleteFile toDeleteFile()
public DeleteWriteResult result()
FileWriter
DataFile
s or DeleteFile
s.
The result is valid only after the writer is closed.result
in interface FileWriter<T,DeleteWriteResult>