[−][src]Trait brotli::enc::threading::BatchSpawnable
Associated Types
type JoinHandle: Joinable<ReturnValue, BrotliEncoderThreadError>
type FinalJoinHandle: OwnedRetriever<U>
Required methods
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,
alloc: &mut SendAlloc<ReturnValue, ExtraInput, Alloc, Self::JoinHandle>,
index: usize,
num_threads: usize,
f: F
)
&mut self,
handle: &mut Self::FinalJoinHandle,
alloc: &mut SendAlloc<ReturnValue, ExtraInput, Alloc, Self::JoinHandle>,
index: usize,
num_threads: usize,
f: F
)
Implementors
impl<ReturnValue: Send + 'static, ExtraInput: Send + 'static, Alloc: BrotliAlloc + Send + 'static, U: Send + 'static + Sync> BatchSpawnable<ReturnValue, ExtraInput, Alloc, U> for MultiThreadedSpawner where
<Alloc as Allocator<u8>>::AllocatedMemory: Send + 'static,
[src]
<Alloc as Allocator<u8>>::AllocatedMemory: Send + 'static,
type JoinHandle = MultiThreadedJoinable<ReturnValue, BrotliEncoderThreadError>
type FinalJoinHandle = Arc<RwLock<U>>
fn make_spawner(&mut self, input: &mut Owned<U>) -> Self::FinalJoinHandle
[src]
fn spawn<F: Fn(ExtraInput, usize, usize, &U, Alloc) -> ReturnValue + Send + 'static + Copy>(
&mut self,
input: &mut Self::FinalJoinHandle,
work: &mut SendAlloc<ReturnValue, ExtraInput, Alloc, Self::JoinHandle>,
index: usize,
num_threads: usize,
f: F
)
[src]
&mut self,
input: &mut Self::FinalJoinHandle,
work: &mut SendAlloc<ReturnValue, ExtraInput, Alloc, Self::JoinHandle>,
index: usize,
num_threads: usize,
f: F
)
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,
[src]
<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
[src]
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
)
[src]
&mut self,
handle: &mut Self::FinalJoinHandle,
work: &mut SendAlloc<ReturnValue, ExtraInput, Alloc, Self::JoinHandle>,
index: usize,
num_threads: usize,
f: F
)