Trait rama::http::layer::traffic_writer::RequestWriter

pub trait RequestWriter:
    Send
    + Sync
    + 'static {
    // Required method
    fn write_request(
        &self,
        req: Request<Body>,
    ) -> impl Future<Output = ()> + Send;
}
Expand description

A trait for writing http requests.

Required Methods§

fn write_request(&self, req: Request<Body>) -> impl Future<Output = ()> + Send

Write the http request.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

§

impl RequestWriter for Sender<Request<Body>>

§

async fn write_request(&self, req: Request<Body>)

§

impl RequestWriter for UnboundedSender<Request<Body>>

§

async fn write_request(&self, req: Request<Body>)

Implementors§

§

impl RequestWriter for BidirectionalWriter<Sender<BidirectionalMessage>>

§

impl RequestWriter for BidirectionalWriter<UnboundedSender<BidirectionalMessage>>

§

impl<F, Fut> RequestWriter for F
where F: Fn(Request<Body>) -> Fut + Send + Sync + 'static, Fut: Future<Output = ()> + Send + 'static,