pub enum ExecutionMode {
Sequential,
Parallel {
threads: Option<usize>,
},
Adaptive,
}Expand description
Represents the execution mode for text processing
Variants§
Sequential
Single-threaded sequential processing
Parallel
Multi-threaded parallel processing with optional thread count
Adaptive
Adaptive mode that automatically selects the best strategy
Implementations§
Source§impl ExecutionMode
impl ExecutionMode
Sourcepub fn determine_thread_count(&self, text_len: usize) -> usize
pub fn determine_thread_count(&self, text_len: usize) -> usize
Determines the actual number of threads to use based on the mode and text size
Trait Implementations§
Source§impl Clone for ExecutionMode
impl Clone for ExecutionMode
Source§fn clone(&self) -> ExecutionMode
fn clone(&self) -> ExecutionMode
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 moreSource§impl Debug for ExecutionMode
impl Debug for ExecutionMode
Source§impl PartialEq for ExecutionMode
impl PartialEq for ExecutionMode
impl Copy for ExecutionMode
impl Eq for ExecutionMode
impl StructuralPartialEq for ExecutionMode
Auto Trait Implementations§
impl Freeze for ExecutionMode
impl RefUnwindSafe for ExecutionMode
impl Send for ExecutionMode
impl Sync for ExecutionMode
impl Unpin for ExecutionMode
impl UnwindSafe for ExecutionMode
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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