pub trait IntoResponse {
// Required method
fn into_response(self) -> Response;
}Available on crate feature
server only.Expand description
Convert an object into a Response
Required Methods§
Sourcefn into_response(self) -> Response
fn into_response(self) -> Response
Consume self and convert it into a Response
Implementations on Foreign Types§
Source§impl IntoResponse for Infallible
impl IntoResponse for Infallible
fn into_response(self) -> Response
Source§impl IntoResponse for Error
impl IntoResponse for Error
fn into_response(self) -> Response
Source§impl IntoResponse for StatusCode
impl IntoResponse for StatusCode
fn into_response(self) -> Response
Source§impl IntoResponse for Error
Available on crate feature query only.
impl IntoResponse for Error
Available on crate feature
query only.fn into_response(self) -> Response
Source§impl IntoResponse for Error
Available on crate feature json only.
impl IntoResponse for Error
Available on crate feature
json only.fn into_response(self) -> Response
Source§impl<B> IntoResponse for Response<B>
impl<B> IntoResponse for Response<B>
fn into_response(self) -> Response
Source§impl<H, R> IntoResponse for (H, R)where
H: TryIntoResponseHeaders,
R: IntoResponse,
impl<H, R> IntoResponse for (H, R)where
H: TryIntoResponseHeaders,
R: IntoResponse,
fn into_response(self) -> Response
Source§impl<R, E> IntoResponse for Result<R, E>where
R: IntoResponse,
E: IntoResponse,
impl<R, E> IntoResponse for Result<R, E>where
R: IntoResponse,
E: IntoResponse,
fn into_response(self) -> Response
Source§impl<T> IntoResponse for (StatusCode, T)where
T: IntoResponse,
impl<T> IntoResponse for (StatusCode, T)where
T: IntoResponse,
fn into_response(self) -> Response
Implementors§
impl IntoResponse for ExtractBodyError
impl IntoResponse for GenericRejectionError
impl IntoResponse for PathParamsRejection
impl IntoResponse for WebSocketUpgradeRejectionError
Available on crate feature
ws only.impl IntoResponse for MultipartRejectionError
Available on crate feature
multipart only.impl IntoResponse for FileResponse
impl IntoResponse for Redirect
impl<S, E> IntoResponse for Sse<S>
impl<T> IntoResponse for Form<T>where
T: Serialize,
Available on crate feature
form only.impl<T> IntoResponse for Json<T>where
T: Serialize,
Available on crate feature
json only.