Trait rust_box::task_executor::SpawnExt
source · [−]pub trait SpawnExt: Future {
fn spawn<Tx, G>(
self,
exec: &Executor<Tx, G, ()>
) -> Spawner<'_, Self, Tx, G, ()>ⓘNotable traits for Spawner<'_, Item, Tx, G, D>impl<Item, Tx, G, D> Future for Spawner<'_, Item, Tx, G, D>where
Item: 'static + Future + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
<Item as Future>::Output: 'static,
<Item as Future>::Output: Send, type Output = Result<(), Error<Item>>;
where
Self: 'static + Send,
Tx: 'static + Clone + Unpin + Sink<((), Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
Self::Output: 'static,
Self::Output: Send,
{ ... }
fn spawn_with<Tx, G, D>(
self,
exec: &Executor<Tx, G, D>,
name: D
) -> Spawner<'_, Self, Tx, G, D>ⓘNotable traits for Spawner<'_, Item, Tx, G, D>impl<Item, Tx, G, D> Future for Spawner<'_, Item, Tx, G, D>where
Item: 'static + Future + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
<Item as Future>::Output: 'static,
<Item as Future>::Output: Send, type Output = Result<(), Error<Item>>;
where
Self: 'static + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
Self::Output: 'static,
Self::Output: Send,
{ ... }
}Provided Methods
sourcefn spawn<Tx, G>(self, exec: &Executor<Tx, G, ()>) -> Spawner<'_, Self, Tx, G, ()>ⓘNotable traits for Spawner<'_, Item, Tx, G, D>
fn spawn<Tx, G>(self, exec: &Executor<Tx, G, ()>) -> Spawner<'_, Self, Tx, G, ()>ⓘNotable traits for Spawner<'_, Item, Tx, G, D>impl<Item, Tx, G, D> Future for Spawner<'_, Item, Tx, G, D>where
Item: 'static + Future + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
<Item as Future>::Output: 'static,
<Item as Future>::Output: Send, type Output = Result<(), Error<Item>>;where
Self: 'static + Send,
Tx: 'static + Clone + Unpin + Sink<((), Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
Self::Output: 'static,
Self::Output: Send,
Item: 'static + Future + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
<Item as Future>::Output: 'static,
<Item as Future>::Output: Send, type Output = Result<(), Error<Item>>;
sourcefn spawn_with<Tx, G, D>(
fn spawn_with<Tx, G, D>(
self,
exec: &Executor<Tx, G, D>,
name: D
) -> Spawner<'_, Self, Tx, G, D>ⓘNotable traits for Spawner<'_, Item, Tx, G, D>impl<Item, Tx, G, D> Future for Spawner<'_, Item, Tx, G, D>where
Item: 'static + Future + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
<Item as Future>::Output: 'static,
<Item as Future>::Output: Send, type Output = Result<(), Error<Item>>;where
Self: 'static + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
Self::Output: 'static,
Self::Output: Send,
Item: 'static + Future + Send,
Tx: 'static + Clone + Unpin + Sink<(D, Box<dyn Future<Output = ()> + Send + Unpin + 'static, Global>)> + Send + Sync,
G: 'static + Hash + Eq + Clone + Debug + Send + Sync,
<Item as Future>::Output: 'static,
<Item as Future>::Output: Send, type Output = Result<(), Error<Item>>;