Struct brotli::enc::singlethreading::SingleThreadedSpawner
source · [−]pub struct SingleThreadedSpawner {}
Trait Implementations
sourceimpl<ReturnValue: Send + 'static, ExtraInput: Send + 'static, Alloc: BrotliAlloc + Send + 'static, U: Send + 'static + Sync> BatchSpawnable<ReturnValue, ExtraInput, Alloc, U> for SingleThreadedSpawner where
<Alloc as Allocator<u8>>::AllocatedMemory: Send + 'static,
impl<ReturnValue: Send + 'static, ExtraInput: Send + 'static, Alloc: BrotliAlloc + Send + 'static, U: Send + 'static + Sync> BatchSpawnable<ReturnValue, ExtraInput, Alloc, U> for SingleThreadedSpawner where
<Alloc as Allocator<u8>>::AllocatedMemory: Send + 'static,
type JoinHandle = SingleThreadedJoinable<ReturnValue, BrotliEncoderThreadError>
type FinalJoinHandle = SingleThreadedOwnedRetriever<U>
fn make_spawner(&mut self, input: &mut Owned<U>) -> Self::FinalJoinHandle
fn spawn<F: Fn(ExtraInput, usize, usize, &U, Alloc) -> ReturnValue + Send + 'static + Copy>(
&mut self,
handle: &mut Self::FinalJoinHandle,
work: &mut SendAlloc<ReturnValue, ExtraInput, Alloc, Self::JoinHandle>,
index: usize,
num_threads: usize,
f: F
)
sourceimpl<ReturnValue: Send + 'static, ExtraInput: Send + 'static, Alloc: BrotliAlloc + Send + 'static, U: Send + 'static + Sync> BatchSpawnableLite<ReturnValue, ExtraInput, Alloc, U> for SingleThreadedSpawner where
<Alloc as Allocator<u8>>::AllocatedMemory: Send + 'static,
impl<ReturnValue: Send + 'static, ExtraInput: Send + 'static, Alloc: BrotliAlloc + Send + 'static, U: Send + 'static + Sync> BatchSpawnableLite<ReturnValue, ExtraInput, Alloc, U> for SingleThreadedSpawner where
<Alloc as Allocator<u8>>::AllocatedMemory: Send + 'static,
type JoinHandle = <SingleThreadedSpawner as BatchSpawnable<ReturnValue, ExtraInput, Alloc, U>>::JoinHandle
type FinalJoinHandle = <SingleThreadedSpawner as BatchSpawnable<ReturnValue, ExtraInput, Alloc, U>>::FinalJoinHandle
fn make_spawner(&mut self, input: &mut Owned<U>) -> Self::FinalJoinHandle
fn spawn(
&mut self,
handle: &mut Self::FinalJoinHandle,
alloc_per_thread: &mut SendAlloc<ReturnValue, ExtraInput, Alloc, Self::JoinHandle>,
index: usize,
num_threads: usize,
f: fn(_: ExtraInput, _: usize, _: usize, _: &U, _: Alloc) -> ReturnValue
)
sourceimpl Default for SingleThreadedSpawner
impl Default for SingleThreadedSpawner
sourcefn default() -> SingleThreadedSpawner
fn default() -> SingleThreadedSpawner
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl RefUnwindSafe for SingleThreadedSpawner
impl Send for SingleThreadedSpawner
impl Sync for SingleThreadedSpawner
impl Unpin for SingleThreadedSpawner
impl UnwindSafe for SingleThreadedSpawner
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more