[][src]Trait parquet::column::page::PageWriter

pub trait PageWriter {
    fn write_page(&mut self, page: CompressedPage) -> Result<PageWriteSpec>;
fn write_metadata(&mut self, metadata: &ColumnChunkMetaData) -> Result<()>;
fn close(&mut self) -> Result<()>; }

API for writing pages in a column chunk.

It is reasonable to assume that all pages will be written in the correct order, e.g. dictionary page followed by data pages, or a set of data pages, etc.

Required Methods

Writes a page into the output stream/sink. Returns PageWriteSpec that contains information about written page metrics, including number of bytes, size, number of values, offset, etc.

This method is called for every compressed page we write into underlying buffer, either data page or dictionary page.

Writes column chunk metadata into the output stream/sink.

This method is called once before page writer is closed, normally when writes are finalised in column writer.

Closes resources and flushes underlying sink. Page writer should not be used after this method is called.

Implementors

impl<T: Write + Position> PageWriter for SerializedPageWriter<T>
[src]