pub enum LevelSelection {
All {
count: usize,
},
Sparse(SelectionVector),
}Expand description
Selection state for a single factorization level.
Supports both sparse (for low selectivity) and dense (for high selectivity) representations to optimize memory usage.
Variants§
All
All values at this level are selected.
Sparse(SelectionVector)
Only specific indices are selected (for low selectivity).
Uses SelectionVector which stores indices as u16.
Implementations§
Source§impl LevelSelection
impl LevelSelection
Sourcepub fn from_predicate<F>(count: usize, predicate: F) -> Self
pub fn from_predicate<F>(count: usize, predicate: F) -> Self
Creates a sparse selection from a predicate.
Sourcepub fn selected_count(&self) -> usize
pub fn selected_count(&self) -> usize
Returns the number of selected values.
Sourcepub fn is_selected(&self, physical_idx: usize) -> bool
pub fn is_selected(&self, physical_idx: usize) -> bool
Returns true if a physical index is selected.
Trait Implementations§
Source§impl Clone for LevelSelection
impl Clone for LevelSelection
Source§fn clone(&self) -> LevelSelection
fn clone(&self) -> LevelSelection
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for LevelSelection
impl RefUnwindSafe for LevelSelection
impl Send for LevelSelection
impl Sync for LevelSelection
impl Unpin for LevelSelection
impl UnwindSafe for LevelSelection
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