hickory_proto::runtime

Trait Spawn

Source
pub trait Spawn {
    // Required method
    fn spawn_bg<F>(&mut self, future: F)
       where F: Future<Output = Result<(), ProtoError>> + Send + 'static;
}
Expand description

A type defines the Handle which can spawn future.

Required Methods§

Source

fn spawn_bg<F>(&mut self, future: F)
where F: Future<Output = Result<(), ProtoError>> + Send + 'static,

Spawn a future in the background

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.

Implementors§

Source§

impl Spawn for TokioHandle

Available on crate feature tokio-runtime only.