pub enum SortPlan {
InMemory,
External {
run_buffer_bytes: usize,
max_fan_in: u32,
},
}Expand description
How a sort will be executed, chosen by crate::SortPlanner.
Variants§
InMemory
Sort entirely in memory — a Vec sort that never opens a file
descriptor. Chosen for small sorts when the budget has headroom.
External
Spill to disk and merge. run_buffer_bytes bounds the in-memory run
before each spill; max_fan_in bounds the number of run files open
at once during the (possibly cascaded) merge, so the process file
descriptor table can never be exhausted.
Implementations§
Source§impl SortPlan
impl SortPlan
Sourcepub fn is_external(&self) -> bool
pub fn is_external(&self) -> bool
Whether this plan spills to disk.
Sourcepub fn is_in_memory(&self) -> bool
pub fn is_in_memory(&self) -> bool
Whether this plan stays entirely in memory.
Trait Implementations§
impl Copy for SortPlan
impl Eq for SortPlan
impl StructuralPartialEq for SortPlan
Auto Trait Implementations§
impl Freeze for SortPlan
impl RefUnwindSafe for SortPlan
impl Send for SortPlan
impl Sync for SortPlan
impl Unpin for SortPlan
impl UnsafeUnpin for SortPlan
impl UnwindSafe for SortPlan
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