Trait parquet::column::page::PageWriter
source · pub trait PageWriter: Send {
// Required methods
fn write_page(&mut self, page: CompressedPage) -> Result<PageWriteSpec>;
fn close(&mut self) -> Result<()>;
}
Expand description
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§
sourcefn write_page(&mut self, page: CompressedPage) -> Result<PageWriteSpec>
fn write_page(&mut self, page: CompressedPage) -> Result<PageWriteSpec>
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.