pub trait SimpleSpawner<R>:
Debug
+ Send
+ Sync
+ 'static {
type Error: Debug + Send + 'static;
type Future: Future<Output = Result<R, Self::Error>> + Debug + Send + 'static;
// Required methods
fn spawn<F>(&self, task: F) -> Self::Future
where F: Future<Output = R> + Send + 'static;
fn is_done(f: &Self::Future) -> bool;
}Expand description
Task spawner for SimpleResultReceiver.
Required Associated Types§
type Error: Debug + Send + 'static
type Future: Future<Output = Result<R, Self::Error>> + Debug + Send + 'static
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.