pub trait ContextFutExt<Fut> {
// Required method
fn with_context<'a>(
self,
ctx: impl Into<ContextRef<'a>>,
) -> FutureWithContext<'a, Fut> ⓘ
where Self: Sized;
}
Required Methods§
Sourcefn with_context<'a>(
self,
ctx: impl Into<ContextRef<'a>>,
) -> FutureWithContext<'a, Fut> ⓘwhere
Self: Sized,
fn with_context<'a>(
self,
ctx: impl Into<ContextRef<'a>>,
) -> FutureWithContext<'a, Fut> ⓘwhere
Self: Sized,
Wraps a future with a context, allowing the future to be cancelled when the context is done