[][src]Struct arrow::array::BufferBuilder

pub struct BufferBuilder<T: ArrowPrimitiveType> { /* fields omitted */ }

Builder for creating a Buffer object.

This builder is implemented for primitive types and creates a buffer with a zero-copy build() method.

See trait BufferBuilderTrait for further documentation and examples.

A Buffer is the underlying data structure of Arrow's Arrays.

For all supported types, there are type definitions for the generic version of BufferBuilder<T>, e.g. UInt8BufferBuilder.

Example:

use arrow::array::{UInt8BufferBuilder, BufferBuilderTrait};

let mut builder = UInt8BufferBuilder::new(100);
builder.append_slice(&[42, 43, 44]);
builder.append(45);
let buffer = builder.finish();

assert_eq!(unsafe { buffer.typed_data::<u8>() }, &[42, 43, 44, 45]);

Trait Implementations

impl BufferBuilderTrait<BooleanType> for BufferBuilder<BooleanType>[src]

impl<T: ArrowPrimitiveType> BufferBuilderTrait<T> for BufferBuilder<T>[src]

impl<T: Debug + ArrowPrimitiveType> Debug for BufferBuilder<T>[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for BufferBuilder<T> where
    T: RefUnwindSafe

impl<T> Send for BufferBuilder<T> where
    T: Send

impl<T> Sync for BufferBuilder<T> where
    T: Sync

impl<T> Unpin for BufferBuilder<T> where
    T: Unpin

impl<T> UnwindSafe for BufferBuilder<T> where
    T: UnwindSafe

Blanket Implementations

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

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

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

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

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

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.

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.

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