ActorRequest

Trait ActorRequest 

Source
pub trait ActorRequest<M, R> {
    // Required method
    async fn request(&self, message: M) -> R;
}

Required Methods§

Source

async fn request(&self, message: M) -> R

Attempts to send a message and wait for the response

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.

Implementations on Foreign Types§

Source§

impl<M, R> ActorRequest<M, R> for DynamicSender<'_, Request<M, R>>

Source§

async fn request(&self, message: M) -> R

Source§

impl<M, R, MUT, const N: usize> ActorRequest<M, R> for Sender<'_, MUT, Request<M, R>, N>
where M: 'static, MUT: RawMutex + 'static,

Source§

async fn request(&self, message: M) -> R

Implementors§