Module response

Expand description

Types and traits for generating responses.

See [crate::response] for more details.

Modules§

redirect
sse
Server-Sent Events (SSE) response.

Structs§

AppendHeaders
Append headers to a response.
Css
An HTML response.
Csv
Wrapper used to create Csv Http Responses, as well as to extract Csv from Http Request bodies.
DatastarScript
Datastar script ready to be served.
ErrorResponse
An IntoResponse-based error type
Form
Wrapper used to create Form Http Responses, as well as to extract Form from Http Request bodies.
Headers
Use typed headers in a response.
Html
An HTML response.
Json
Wrapper used to create Json Http Responses, as well as to extract Json from Http Request bodies.
Redirect
Utility struct to easily create a redirect response.
ResponseParts
Parts of a response.
Script
An HTML response.
Sse
An SSE response
StaticResponseFactory
Wrapper that can be used to turn an IntoResponse type into something that implements Into<Response>.
TryIntoHeaderError
Error returned if converting a value to a header fails.

Traits§

IntoResponse
Trait for generating responses.
IntoResponseParts
Trait for adding headers and extensions to a response.

Type Aliases§

Result
An IntoResponse-based result type that uses ErrorResponse as the error type.