pub(super) struct DataRequest {
column_chunks: Vec<Option<Arc<ColumnChunkData>>>,
ranges: Vec<Range<u64>>,
page_start_offsets: Option<Vec<Vec<u64>>>,
}Expand description
Contains in-progress state to construct InMemoryRowGroups
See DataRequestBuilder for creating new requests
Fields§
§column_chunks: Vec<Option<Arc<ColumnChunkData>>>Any previously read column chunk data
ranges: Vec<Range<u64>>The ranges of data that are needed next
page_start_offsets: Option<Vec<Vec<u64>>>Optional page start offsets for each requested range. This is used to create the relevant InMemoryRowGroup
Implementations§
Source§impl DataRequest
impl DataRequest
Sourcepub fn needed_ranges(&self, buffers: &PushBuffers) -> Vec<Range<u64>>
pub fn needed_ranges(&self, buffers: &PushBuffers) -> Vec<Range<u64>>
return what ranges are still needed to satisfy this request. Returns an empty vec if all ranges are satisfied
Sourcefn get_chunks(&self, buffers: &PushBuffers) -> Result<Vec<Bytes>, ParquetError>
fn get_chunks(&self, buffers: &PushBuffers) -> Result<Vec<Bytes>, ParquetError>
Returns the chunks from the buffers that satisfy this request
Sourcepub fn try_into_in_memory_row_group<'a>(
self,
row_group_idx: usize,
row_count: usize,
parquet_metadata: &'a ParquetMetaData,
projection: &ProjectionMask,
buffers: &mut PushBuffers,
) -> Result<InMemoryRowGroup<'a>, ParquetError>
pub fn try_into_in_memory_row_group<'a>( self, row_group_idx: usize, row_count: usize, parquet_metadata: &'a ParquetMetaData, projection: &ProjectionMask, buffers: &mut PushBuffers, ) -> Result<InMemoryRowGroup<'a>, ParquetError>
Create a new InMemoryRowGroup, and fill it with provided data
Assumes that all needed data is present in the buffers and clears any explicitly requested ranges
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DataRequest
impl RefUnwindSafe for DataRequest
impl Send for DataRequest
impl Sync for DataRequest
impl Unpin for DataRequest
impl UnwindSafe for DataRequest
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
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