FormatResponse

Trait FormatResponse 

Source
pub trait FormatResponse {
    // Required methods
    fn format_response(http_error: &HttpError) -> Bytes;
    fn content_type() -> Mime;
}
Expand description

Trait for formatting error responses.

Required Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl FormatResponse for Json

Available on crate feature json only.