Struct q_compress::wrapped::ChunkSpec
source · pub struct ChunkSpec { /* private fields */ }
Expand description
A specification for how many elements there will be in each of a chunk’s data pages.
By default this specifies a single data page containing all the data.
You can also specify exact data page sizes via
.with_page_sizes
.
Data pages must be specified up-front for each chunk for performance
reasons.
Implementations§
source§impl ChunkSpec
impl ChunkSpec
sourcepub fn with_page_sizes(self, sizes: Vec<usize>) -> Self
pub fn with_page_sizes(self, sizes: Vec<usize>) -> Self
Modifies the spec to use the exact data page sizes given. These must sum to the actual number of elements to be compressed.
E.g.
use q_compress::wrapped::ChunkSpec;
let spec = ChunkSpec::default().with_page_sizes(vec![1, 2, 3]);
can only be used if the chunk actually contains 1+2+3=6 numbers.
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for ChunkSpec
impl Send for ChunkSpec
impl Sync for ChunkSpec
impl Unpin for ChunkSpec
impl UnwindSafe for ChunkSpec
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