Skip to main content

Destination

Trait Destination 

Source
pub trait Destination: Send + Sync {
    // Required method
    fn send(
        &self,
        request: Request<Bytes>,
    ) -> impl Future<Output = Result<Response<Bytes>, HandlerError>> + Send;
}

Required Methods§

Source

fn send( &self, request: Request<Bytes>, ) -> impl Future<Output = Result<Response<Bytes>, HandlerError>> + Send

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl Destination for &str

Available on crate feature hosting only.
Source§

async fn send( &self, request: Request<Bytes>, ) -> Result<Response<Bytes>, HandlerError>

Source§

impl Destination for Arc<Node>

Source§

async fn send( &self, request: Request<Bytes>, ) -> Result<Response<Bytes>, HandlerError>

Source§

impl Destination for String

Available on crate feature hosting only.
Source§

async fn send( &self, request: Request<Bytes>, ) -> Result<Response<Bytes>, HandlerError>

Source§

impl<D: Destination + ?Sized> Destination for &D

Source§

async fn send( &self, request: Request<Bytes>, ) -> Result<Response<Bytes>, HandlerError>

Implementors§