pub struct CommentsServiceAsyncClient<T>(/* private fields */);
Expand description
Comments service manages conversations about resources.
Implementations§
Source§impl<T> CommentsServiceAsyncClient<T>where
T: AsyncClient,
impl<T> CommentsServiceAsyncClient<T>where
T: AsyncClient,
Sourcepub async fn get_conversation(
&self,
auth_: &BearerToken,
resource_type: &ResourceType,
resource_rid: &ResourceIdentifier,
) -> Result<Conversation, Error>
pub async fn get_conversation( &self, auth_: &BearerToken, resource_type: &ResourceType, resource_rid: &ResourceIdentifier, ) -> Result<Conversation, Error>
A conversation is a fully resolved comment tree. It includes all comments for the given resource and all the nested comments/replies to those comments.
Sourcepub async fn get_conversation_count(
&self,
auth_: &BearerToken,
resource_type: &ResourceType,
resource_rid: &ResourceIdentifier,
include_deleted: Option<bool>,
) -> Result<i32, Error>
pub async fn get_conversation_count( &self, auth_: &BearerToken, resource_type: &ResourceType, resource_rid: &ResourceIdentifier, include_deleted: Option<bool>, ) -> Result<i32, Error>
Returns the number of comments in a conversation.
Sourcepub async fn get_comment(
&self,
auth_: &BearerToken,
comment_rid: &CommentRid,
) -> Result<Comment, Error>
pub async fn get_comment( &self, auth_: &BearerToken, comment_rid: &CommentRid, ) -> Result<Comment, Error>
Get a comment identified by its RID
Sourcepub async fn create_comment(
&self,
auth_: &BearerToken,
request: &CreateCommentRequest,
) -> Result<Comment, Error>
pub async fn create_comment( &self, auth_: &BearerToken, request: &CreateCommentRequest, ) -> Result<Comment, Error>
Create a comment on a resource
Sourcepub async fn edit_comment(
&self,
auth_: &BearerToken,
comment_rid: &CommentRid,
request: &EditCommentRequest,
) -> Result<Comment, Error>
pub async fn edit_comment( &self, auth_: &BearerToken, comment_rid: &CommentRid, request: &EditCommentRequest, ) -> Result<Comment, Error>
Edit an existing comment
Sourcepub async fn delete_comment(
&self,
auth_: &BearerToken,
comment_rid: &CommentRid,
) -> Result<Comment, Error>
pub async fn delete_comment( &self, auth_: &BearerToken, comment_rid: &CommentRid, ) -> Result<Comment, Error>
Delete an existing comment
Sourcepub async fn pin_comment(
&self,
auth_: &BearerToken,
comment_rid: &CommentRid,
) -> Result<Comment, Error>
pub async fn pin_comment( &self, auth_: &BearerToken, comment_rid: &CommentRid, ) -> Result<Comment, Error>
Pin a comment to the top of the conversation
Sourcepub async fn unpin_comment(
&self,
auth_: &BearerToken,
comment_rid: &CommentRid,
) -> Result<Comment, Error>
pub async fn unpin_comment( &self, auth_: &BearerToken, comment_rid: &CommentRid, ) -> Result<Comment, Error>
Unpin a comment from the top of the conversation
Sourcepub async fn add_reaction(
&self,
auth_: &BearerToken,
comment_rid: &CommentRid,
type_: &ReactionType,
) -> Result<Comment, Error>
pub async fn add_reaction( &self, auth_: &BearerToken, comment_rid: &CommentRid, type_: &ReactionType, ) -> Result<Comment, Error>
Create a reaction on a comment
Sourcepub async fn remove_reaction(
&self,
auth_: &BearerToken,
comment_rid: &CommentRid,
type_: &ReactionType,
) -> Result<Comment, Error>
pub async fn remove_reaction( &self, auth_: &BearerToken, comment_rid: &CommentRid, type_: &ReactionType, ) -> Result<Comment, Error>
Create a reaction on a comment
Trait Implementations§
Source§impl<T> AsyncService<T> for CommentsServiceAsyncClient<T>where
T: AsyncClient,
impl<T> AsyncService<T> for CommentsServiceAsyncClient<T>where
T: AsyncClient,
Source§impl<T: Clone> Clone for CommentsServiceAsyncClient<T>
impl<T: Clone> Clone for CommentsServiceAsyncClient<T>
Source§fn clone(&self) -> CommentsServiceAsyncClient<T>
fn clone(&self) -> CommentsServiceAsyncClient<T>
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 moreAuto Trait Implementations§
impl<T> Freeze for CommentsServiceAsyncClient<T>where
T: Freeze,
impl<T> RefUnwindSafe for CommentsServiceAsyncClient<T>where
T: RefUnwindSafe,
impl<T> Send for CommentsServiceAsyncClient<T>where
T: Send,
impl<T> Sync for CommentsServiceAsyncClient<T>where
T: Sync,
impl<T> Unpin for CommentsServiceAsyncClient<T>where
T: Unpin,
impl<T> UnwindSafe for CommentsServiceAsyncClient<T>where
T: UnwindSafe,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request