pub trait WrapsResponse: Sized {
type Inner;
type Pure: WrapsResponse<Inner = ()>;
const STATUS_CODE: StatusCode;
// Required method
fn into_inner(self) -> Self::Inner;
// Provided method
fn into_set<E>(self) -> ApiResponse<E>
where Self::Inner: IntoResponse,
E: Contains<Self> { ... }
}Required Associated Constants§
Sourceconst STATUS_CODE: StatusCode
const STATUS_CODE: StatusCode
The status code associated with type.
Required Associated Types§
Sourcetype Pure: WrapsResponse<Inner = ()>
type Pure: WrapsResponse<Inner = ()>
The pure type of this status wrapper, without any inner value.
Required Methods§
Sourcefn into_inner(self) -> Self::Inner
fn into_inner(self) -> Self::Inner
Convert this status wrapper into its inner value.
Provided Methods§
Sourcefn into_set<E>(self) -> ApiResponse<E>
fn into_set<E>(self) -> ApiResponse<E>
Convert this status wrapper into an [ApiErrorSet] with the
given inner value type. (into can be used as well)
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".