Trait Endpoint

Source
pub trait Endpoint: DynClone {
    type RenderRequestError: Error + Send + Sync + 'static;
    type ParseResponseOutput;
    type ParseResponseError: Error + Send + Sync + 'static;

    // Required methods
    fn render_request(&self) -> Result<Request<Body>, Self::RenderRequestError>;
    fn parse_response(
        &self,
        response: Response<Body>,
    ) -> Result<Self::ParseResponseOutput, Self::ParseResponseError>;
}

Required Associated Types§

Required Methods§

Trait Implementations§

Source§

impl<RenderRequestError, ParseResponseOutput, ParseResponseError> Debug for dyn Endpoint<RenderRequestError = RenderRequestError, ParseResponseOutput = ParseResponseOutput, ParseResponseError = ParseResponseError>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<RenderRequestError, ParseResponseOutput, ParseResponseError> Debug for dyn Endpoint<RenderRequestError = RenderRequestError, ParseResponseOutput = ParseResponseOutput, ParseResponseError = ParseResponseError> + Send + Sync

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Implementors§