Struct arrow::array::GenericListBuilder
source · [−]pub struct GenericListBuilder<OffsetSize: OffsetSizeTrait, T: ArrayBuilder> { /* private fields */ }
Expand description
Array builder for ListArray
Implementations
sourceimpl<OffsetSize: OffsetSizeTrait, T: ArrayBuilder> GenericListBuilder<OffsetSize, T>
impl<OffsetSize: OffsetSizeTrait, T: ArrayBuilder> GenericListBuilder<OffsetSize, T>
sourcepub fn new(values_builder: T) -> Self
pub fn new(values_builder: T) -> Self
Creates a new ListArrayBuilder
from a given values array builder
sourcepub fn with_capacity(values_builder: T, capacity: usize) -> Self
pub fn with_capacity(values_builder: T, capacity: usize) -> Self
Creates a new ListArrayBuilder
from a given values array builder
capacity
is the number of items to pre-allocate space for in this builder
sourceimpl<OffsetSize: OffsetSizeTrait, T: ArrayBuilder> GenericListBuilder<OffsetSize, T> where
T: 'static,
impl<OffsetSize: OffsetSizeTrait, T: ArrayBuilder> GenericListBuilder<OffsetSize, T> where
T: 'static,
sourcepub fn values(&mut self) -> &mut T
pub fn values(&mut self) -> &mut T
Returns the child array builder as a mutable reference.
This mutable reference can be used to append values into the child array builder,
but you must call append
to delimit each distinct list value.
sourcepub fn append(&mut self, is_valid: bool) -> Result<()>
pub fn append(&mut self, is_valid: bool) -> Result<()>
Finish the current variable-length list array slot
sourcepub fn finish(&mut self) -> GenericListArray<OffsetSize>
pub fn finish(&mut self) -> GenericListArray<OffsetSize>
Builds the ListArray
and reset this builder.
Trait Implementations
sourceimpl<OffsetSize: OffsetSizeTrait, T: ArrayBuilder> ArrayBuilder for GenericListBuilder<OffsetSize, T> where
T: 'static,
impl<OffsetSize: OffsetSizeTrait, T: ArrayBuilder> ArrayBuilder for GenericListBuilder<OffsetSize, T> where
T: 'static,
sourcefn as_any_mut(&mut self) -> &mut dyn Any
fn as_any_mut(&mut self) -> &mut dyn Any
Returns the builder as a mutable Any
reference.
sourcefn into_box_any(self: Box<Self>) -> Box<dyn Any>
fn into_box_any(self: Box<Self>) -> Box<dyn Any>
Returns the boxed builder as a box of Any
.
sourceimpl<OffsetSize: Debug + OffsetSizeTrait, T: Debug + ArrayBuilder> Debug for GenericListBuilder<OffsetSize, T>
impl<OffsetSize: Debug + OffsetSizeTrait, T: Debug + ArrayBuilder> Debug for GenericListBuilder<OffsetSize, T>
Auto Trait Implementations
impl<OffsetSize, T> RefUnwindSafe for GenericListBuilder<OffsetSize, T> where
OffsetSize: RefUnwindSafe,
T: RefUnwindSafe,
impl<OffsetSize, T> Send for GenericListBuilder<OffsetSize, T>
impl<OffsetSize, T> Sync for GenericListBuilder<OffsetSize, T> where
T: Sync,
impl<OffsetSize, T> Unpin for GenericListBuilder<OffsetSize, T> where
OffsetSize: Unpin,
T: Unpin,
impl<OffsetSize, T> UnwindSafe for GenericListBuilder<OffsetSize, T> where
OffsetSize: UnwindSafe,
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more