pub struct PostsCommentsReactionsResource<'a> { /* private fields */ }Expand description
client.posts().comments().reactions()
Implementations§
Source§impl<'a> PostsCommentsReactionsResource<'a>
impl<'a> PostsCommentsReactionsResource<'a>
Sourcepub fn delete(
&self,
post_id: impl Display,
comment_id: impl Display,
emoji: impl Display,
) -> Result<()>
pub fn delete( &self, post_id: impl Display, comment_id: impl Display, emoji: impl Display, ) -> Result<()>
DELETE /posts/{postId}/comments/{commentId}/reactions/{emoji}
Delete a reaction of the current person for a post comment.
§Example
client.posts().comments().reactions().delete(42, 42, "👍")?;Sourcepub fn list(
&self,
post_id: impl Display,
comment_id: impl Display,
) -> Result<Vec<PostCommentReaction>>
pub fn list( &self, post_id: impl Display, comment_id: impl Display, ) -> Result<Vec<PostCommentReaction>>
GET /posts/{postId}/comments/{commentId}/reactions
Get a list of reactions for a post comment.
§Example
for reaction in client.posts().comments().reactions().list(42, 42)? {
println!("{}", reaction.comment_id);
}Sourcepub fn update(
&self,
post_id: impl Display,
comment_id: impl Display,
body: &PostCommentReactionCreate,
) -> Result<PostCommentReaction>
pub fn update( &self, post_id: impl Display, comment_id: impl Display, body: &PostCommentReactionCreate, ) -> Result<PostCommentReaction>
PUT /posts/{postId}/comments/{commentId}/reactions
Create a new reaction of the current person for a post comment.
§Example
let body = models::PostCommentReactionCreate {
emoji: "👍".into(),
..Default::default()
};
let result = client.posts().comments().reactions().update(42, 42, &body)?;
println!("{}", result.comment_id);Trait Implementations§
Source§impl<'a> Clone for PostsCommentsReactionsResource<'a>
impl<'a> Clone for PostsCommentsReactionsResource<'a>
impl<'a> Copy for PostsCommentsReactionsResource<'a>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for PostsCommentsReactionsResource<'a>
impl<'a> !UnwindSafe for PostsCommentsReactionsResource<'a>
impl<'a> Freeze for PostsCommentsReactionsResource<'a>
impl<'a> Send for PostsCommentsReactionsResource<'a>
impl<'a> Sync for PostsCommentsReactionsResource<'a>
impl<'a> Unpin for PostsCommentsReactionsResource<'a>
impl<'a> UnsafeUnpin for PostsCommentsReactionsResource<'a>
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