pub struct ByteGroupValueBuilder<O>where
O: OffsetSizeTrait,{
output_type: OutputType,
buffer: BufferBuilder<u8>,
offsets: Vec<O>,
nulls: MaybeNullBufferBuilder,
max_buffer_size: usize,
}Expand description
An implementation of GroupColumn for binary and utf8 types.
Stores a collection of binary or utf8 group values in a single buffer in a way that allows:
- Efficient comparison of incoming rows to existing rows
- Efficient construction of the final output array
Fields§
§output_type: OutputType§buffer: BufferBuilder<u8>§offsets: Vec<O>Offsets into buffer for each distinct value. These offsets as used
directly to create the final GenericBinaryArray. The ith string is
stored in the range offsets[i]..offsets[i+1] in buffer. Null values
are stored as a zero length string.
nulls: MaybeNullBufferBuilderNulls
max_buffer_size: usizeThe maximum size of the buffer for 0
Implementations§
Source§impl<O> ByteGroupValueBuilder<O>where
O: OffsetSizeTrait,
impl<O> ByteGroupValueBuilder<O>where
O: OffsetSizeTrait,
pub fn new(output_type: OutputType) -> Self
fn equal_to_inner<B>(
&self,
lhs_row: usize,
array: &ArrayRef,
rhs_row: usize,
) -> boolwhere
B: ByteArrayType,
fn append_val_inner<B>(&mut self, array: &ArrayRef, row: usize) -> Result<()>where
B: ByteArrayType,
fn vectorized_equal_to_inner<B>(
&self,
lhs_rows: &[usize],
array: &ArrayRef,
rhs_rows: &[usize],
equal_to_results: &mut [bool],
)where
B: ByteArrayType,
fn vectorized_append_inner<B>(
&mut self,
array: &ArrayRef,
rows: &[usize],
) -> Result<()>where
B: ByteArrayType,
fn do_equal_to_inner<B>(
&self,
lhs_row: usize,
array: &GenericByteArray<B>,
rhs_row: usize,
) -> boolwhere
B: ByteArrayType,
fn do_append_val_inner<B>(
&mut self,
array: &GenericByteArray<B>,
row: usize,
) -> Result<()>where
B: ByteArrayType,
Trait Implementations§
Source§impl<O> GroupColumn for ByteGroupValueBuilder<O>where
O: OffsetSizeTrait,
impl<O> GroupColumn for ByteGroupValueBuilder<O>where
O: OffsetSizeTrait,
Source§fn equal_to(&self, lhs_row: usize, column: &ArrayRef, rhs_row: usize) -> bool
fn equal_to(&self, lhs_row: usize, column: &ArrayRef, rhs_row: usize) -> bool
Returns equal if the row stored in this builder at
lhs_row is equal to
the row in array at rhs_row Read moreSource§fn append_val(&mut self, column: &ArrayRef, row: usize) -> Result<()>
fn append_val(&mut self, column: &ArrayRef, row: usize) -> Result<()>
Appends the row at
row in array to this builderSource§fn vectorized_equal_to(
&self,
lhs_rows: &[usize],
array: &ArrayRef,
rhs_rows: &[usize],
equal_to_results: &mut [bool],
)
fn vectorized_equal_to( &self, lhs_rows: &[usize], array: &ArrayRef, rhs_rows: &[usize], equal_to_results: &mut [bool], )
The vectorized version equal to Read more
Source§fn vectorized_append(&mut self, column: &ArrayRef, rows: &[usize]) -> Result<()>
fn vectorized_append(&mut self, column: &ArrayRef, rows: &[usize]) -> Result<()>
The vectorized version
append_valSource§fn size(&self) -> usize
fn size(&self) -> usize
Returns the number of bytes used by this
GroupColumnAuto Trait Implementations§
impl<O> Freeze for ByteGroupValueBuilder<O>
impl<O> RefUnwindSafe for ByteGroupValueBuilder<O>where
O: RefUnwindSafe,
impl<O> Send for ByteGroupValueBuilder<O>
impl<O> Sync for ByteGroupValueBuilder<O>
impl<O> Unpin for ByteGroupValueBuilder<O>where
O: Unpin,
impl<O> UnwindSafe for ByteGroupValueBuilder<O>where
O: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more