pub enum ParallelBatchProcessorBuildError {
ZeroThreadCount,
}Expand description
Error returned when building a crate::ParallelBatchProcessor.
use qubit_batch::{
ParallelBatchProcessor,
ParallelBatchProcessorBuildError,
};
let error = match ParallelBatchProcessor::builder(|_item: &i32| {})
.thread_count(0)
.build()
{
Ok(_) => panic!("zero worker count should be rejected"),
Err(error) => error,
};
assert_eq!(error, ParallelBatchProcessorBuildError::ZeroThreadCount);Variants§
ZeroThreadCount
The configured worker-thread count is zero.
Trait Implementations§
Source§impl Clone for ParallelBatchProcessorBuildError
impl Clone for ParallelBatchProcessorBuildError
Source§fn clone(&self) -> ParallelBatchProcessorBuildError
fn clone(&self) -> ParallelBatchProcessorBuildError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Error for ParallelBatchProcessorBuildError
impl Error for ParallelBatchProcessorBuildError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for ParallelBatchProcessorBuildError
impl PartialEq for ParallelBatchProcessorBuildError
Source§fn eq(&self, other: &ParallelBatchProcessorBuildError) -> bool
fn eq(&self, other: &ParallelBatchProcessorBuildError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for ParallelBatchProcessorBuildError
impl Eq for ParallelBatchProcessorBuildError
impl StructuralPartialEq for ParallelBatchProcessorBuildError
Auto Trait Implementations§
impl Freeze for ParallelBatchProcessorBuildError
impl RefUnwindSafe for ParallelBatchProcessorBuildError
impl Send for ParallelBatchProcessorBuildError
impl Sync for ParallelBatchProcessorBuildError
impl Unpin for ParallelBatchProcessorBuildError
impl UnsafeUnpin for ParallelBatchProcessorBuildError
impl UnwindSafe for ParallelBatchProcessorBuildError
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