pub trait IntoRequest: Send {
type Discriminant: Send + 'static;
type Response: for<'de> Deserialize<'de> + Send;
// Required method
fn into_request(self) -> (Self::Discriminant, ApiRequest);
}Expand description
Trait for typed api requests
Required Associated Types§
Sourcetype Discriminant: Send + 'static
type Discriminant: Send + 'static
If used in bulk request, the discriminant is used to distinguish the responses. For
endpoints which have no path parameters this will be ().
Sourcetype Response: for<'de> Deserialize<'de> + Send
type Response: for<'de> Deserialize<'de> + Send
The response type which shall be deserialised.
Required Methods§
fn into_request(self) -> (Self::Discriminant, ApiRequest)
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".