Skip to main content

CanComputeAsync

Trait CanComputeAsync 

Source
pub trait CanComputeAsync<Code, Input> {
    type Output;

    // Required method
    fn compute_async(
        &self,
        _code: PhantomData<Code>,
        input: Input,
    ) -> impl Future<Output = Self::Output>;
}

Required Associated Types§

Required Methods§

Source

fn compute_async( &self, _code: PhantomData<Code>, input: Input, ) -> impl Future<Output = Self::Output>

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<__Context__, Code, Input> CanComputeAsync<Code, Input> for __Context__
where __Context__: AsyncComputer<__Context__, Code, Input>,

Source§

type Output = <__Context__ as AsyncComputer<__Context__, Code, Input>>::Output