protected static interface AbstractFileBasedConnector.RecordWriter extends AutoCloseable
Records. Implementors are not expected to deal with thread-safety issues,
these are handled by this class.| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes the underlying file being written.
|
void |
flush()
Flushes all pending writes.
|
void |
write(Record record)
Writes the record to the destination file, in a thread-safe manner (i.e., this method is
never called concurrently).
|
void write(@NonNull
Record record)
throws IOException
record - The record to write.IOException - If an I/O error occurs while writing the record or dealing with the file
(open, close, etc.).void flush()
throws IOException
IOException - If an I/O error occurs while flushing.void close()
throws IOException
write(Record) will not be called anymore.close in interface AutoCloseableIOException - If an I/O error occurs while closing.Copyright © 2017–2023 DataStax. All rights reserved.