Skip to main content

HttpRequestBuilder

Trait HttpRequestBuilder 

Source
pub trait HttpRequestBuilder {
    type Response: HttpResponse;
    type RequestError: Error + Send + Sync + Unpin;

    // Required method
    fn send(
        self,
    ) -> impl Future<Output = PullResult<Self::Response, Self::RequestError>> + Send;
}
Expand description

Abstraction over an HTTP request builder that can be sent to produce a response.

Required Associated Types§

Source

type Response: HttpResponse

The response type produced on success.

Source

type RequestError: Error + Send + Sync + Unpin

The error type for a failed send.

Required Methods§

Source

fn send( self, ) -> impl Future<Output = PullResult<Self::Response, Self::RequestError>> + Send

Send the request, producing a response or a retryable error.

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 HttpRequestBuilder for RequestBuilder

Implementors§