Interface DeltaWriter<T>
-
- All Superinterfaces:
java.lang.AutoCloseable,java.io.Closeable,org.apache.spark.sql.connector.write.DataWriter<T>
public interface DeltaWriter<T> extends org.apache.spark.sql.connector.write.DataWriter<T>A data writer responsible for writing a delta of rows.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voiddelete(T metadata, T id)Passes information for a row that must be deleted.voidinsert(T row)Passes a row to insert.voidupdate(T metadata, T id, T row)Passes information for a row that must be updated together with the updated row.default voidwrite(T row)
-
-
-
Method Detail
-
delete
void delete(T metadata, T id) throws java.io.IOException
Passes information for a row that must be deleted.- Parameters:
metadata- values for metadata columns that were projected but are not part of the row IDid- a row ID to delete- Throws:
java.io.IOException- if the write process encounters an error
-
update
void update(T metadata, T id, T row) throws java.io.IOException
Passes information for a row that must be updated together with the updated row.- Parameters:
metadata- values for metadata columns that were projected but are not part of the row IDid- a row ID to updaterow- a row with updated values- Throws:
java.io.IOException- if the write process encounters an error
-
insert
void insert(T row) throws java.io.IOException
Passes a row to insert.- Parameters:
row- a row to insert- Throws:
java.io.IOException- if the write process encounters an error
-
-