Struct parquet::column::writer::ColumnWriterImpl[][src]

pub struct ColumnWriterImpl<T: DataType> { /* fields omitted */ }
Expand description

Typed column writer for a primitive column.

Implementations

impl<T: DataType> ColumnWriterImpl<T>[src]

pub fn new(
    descr: ColumnDescPtr,
    props: WriterPropertiesPtr,
    page_writer: Box<dyn PageWriter>
) -> Self
[src]

pub fn write_batch(
    &mut self,
    values: &[T::T],
    def_levels: Option<&[i16]>,
    rep_levels: Option<&[i16]>
) -> Result<usize>
[src]

Writes batch of values, definition levels and repetition levels. Returns number of values processed (written).

If definition and repetition levels are provided, we write fully those levels and select how many values to write (this number will be returned), since number of actual written values may be smaller than provided values.

If only values are provided, then all values are written and the length of of the values buffer is returned.

Definition and/or repetition levels can be omitted, if values are non-nullable and/or non-repeated.

pub fn write_batch_with_statistics(
    &mut self,
    values: &[T::T],
    def_levels: Option<&[i16]>,
    rep_levels: Option<&[i16]>,
    min: &Option<T::T>,
    max: &Option<T::T>,
    nulls_count: Option<u64>,
    distinct_count: Option<u64>
) -> Result<usize>
[src]

Writer may optionally provide pre-calculated statistics for this batch, in which case we do not calculate page level statistics as this will defeat the purpose of speeding up the write process with pre-calculated statistics.

pub fn get_total_bytes_written(&self) -> u64[src]

Returns total number of bytes written by this column writer so far. This value is also returned when column writer is closed.

pub fn get_total_rows_written(&self) -> u64[src]

Returns total number of rows written by this column writer so far. This value is also returned when column writer is closed.

pub fn close(self) -> Result<(u64, u64, ColumnChunkMetaData)>[src]

Finalises writes and closes the column writer. Returns total bytes written, total rows written and column chunk metadata.

pub fn make_typed_statistics(&self, level: Level) -> Statistics[src]

Auto Trait Implementations

impl<T> !RefUnwindSafe for ColumnWriterImpl<T>

impl<T> !Send for ColumnWriterImpl<T>

impl<T> !Sync for ColumnWriterImpl<T>

impl<T> Unpin for ColumnWriterImpl<T> where
    T: Unpin,
    <T as DataType>::T: Unpin

impl<T> !UnwindSafe for ColumnWriterImpl<T>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

pub fn vzip(self) -> V