pub struct FollowingObject {
pub following: Follow,
}Expand description
§Example
use twitter_archive::structs::following::FollowingObject;
let json = r#"{
"following": {
"accountId": "1111111111111111111",
"userLink": "https://twitter.com/intent/user?user_id=1111111111111111111"
}
}"#;
let data: FollowingObject = serde_json::from_str(&json).unwrap();
// De-serialized properties
assert_eq!(data.following.account_id, "1111111111111111111");
assert_eq!(data.following.user_link, "https://twitter.com/intent/user?user_id=1111111111111111111");
// Re-serialize is equivalent to original data
assert_eq!(serde_json::to_string_pretty(&data).unwrap(), json);Fields§
§following: Follow§Example JSON data
{
"following": {
"accountId": "1111111111111111111",
"userLink": "https://twitter.com/intent/user?user_id=1111111111111111111"
}
}Trait Implementations§
Source§impl Clone for FollowingObject
impl Clone for FollowingObject
Source§fn clone(&self) -> FollowingObject
fn clone(&self) -> FollowingObject
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FollowingObject
impl Debug for FollowingObject
Source§impl<'de> Deserialize<'de> for FollowingObject
impl<'de> Deserialize<'de> for FollowingObject
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for FollowingObject
impl Display for FollowingObject
Auto Trait Implementations§
impl Freeze for FollowingObject
impl RefUnwindSafe for FollowingObject
impl Send for FollowingObject
impl Sync for FollowingObject
impl Unpin for FollowingObject
impl UnwindSafe for FollowingObject
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more