Struct arrow_ipc::writer::FileWriter
source · pub struct FileWriter<W: Write> { /* private fields */ }
Implementations§
source§impl<W: Write> FileWriter<W>
impl<W: Write> FileWriter<W>
sourcepub fn try_new(writer: W, schema: &Schema) -> Result<Self, ArrowError>
pub fn try_new(writer: W, schema: &Schema) -> Result<Self, ArrowError>
Try create a new writer, with the schema written as part of the header
sourcepub fn try_new_with_options(
writer: W,
schema: &Schema,
write_options: IpcWriteOptions
) -> Result<Self, ArrowError>
pub fn try_new_with_options( writer: W, schema: &Schema, write_options: IpcWriteOptions ) -> Result<Self, ArrowError>
Try create a new writer with IpcWriteOptions
sourcepub fn write(&mut self, batch: &RecordBatch) -> Result<(), ArrowError>
pub fn write(&mut self, batch: &RecordBatch) -> Result<(), ArrowError>
Write a record batch to the file
sourcepub fn finish(&mut self) -> Result<(), ArrowError>
pub fn finish(&mut self) -> Result<(), ArrowError>
Write footer and closing tag, then mark the writer as done
sourcepub fn into_inner(self) -> Result<W, ArrowError>
pub fn into_inner(self) -> Result<W, ArrowError>
Unwraps the BufWriter housed in FileWriter.writer, returning the underlying writer
The buffer is flushed and the FileWriter is finished before returning the writer.