pub type RedditResponse = GenericResponse<RedditTypeResponse>;Expand description
A RedditResponse the type is dynamically decided based on the kind data This is primarily used in Listing that return different type of data
Aliased Type§
pub struct RedditResponse {
pub kind: RedditDataType,
pub data: RedditTypeResponse,
}Fields§
§kind: RedditDataTypeThe kind value from Reddit
data: RedditTypeResponseThe Data that Reddit has responded with
Trait Implementations§
Source§impl<'de> Deserialize<'de> for RedditResponse
impl<'de> Deserialize<'de> for RedditResponse
Source§fn deserialize<D>(deserializer: D) -> Result<RedditResponse, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<RedditResponse, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<RedditTypeResponse> for RedditResponse
impl From<RedditTypeResponse> for RedditResponse
Source§fn from(reddit_type: RedditTypeResponse) -> Self
fn from(reddit_type: RedditTypeResponse) -> Self
Converts to this type from the input type.