Interface DiscussionResources


  • public interface DiscussionResources

    This interface provides methods to access Discussion resources.

    Thread Safety: Implementation of this interface must be thread safe.

    • Method Detail

      • addDiscussionComment

        Comment addDiscussionComment​(long id,
                                     Comment comment)
                              throws SmartsheetException

        Add a comment to a discussion.

        It mirrors to the following Smartsheet REST API method: POST /discussion/{discussionId}/comments

        Parameters:
        id - the discussion id
        comment - the comment to add
        Returns:
        the created comment
        Throws:
        java.lang.IllegalArgumentException - if any argument is null or empty string
        InvalidRequestException - if there is any problem with the REST API request
        AuthorizationException - if there is any problem with the REST API authorization (access token)
        ResourceNotFoundException - if the resource cannot be found
        ServiceUnavailableException - if the REST API service is not available (possibly due to rate limiting)
        SmartsheetException - if there is any other error during the operation
      • attachments

        @Deprecated(since="2.0.0",
                    forRemoval=true)
        AssociatedAttachmentResources attachments()
        Deprecated, for removal: This API element is subject to removal in a future version.
        As of release 2.0. Please use the corresponding method in the [Row/Sheet/etc]AttachmentResources classes
        Returns:
        associated resources
      • comments

        DiscussionCommentResources comments()

        Represents the DiscussionCommentResources.

        It will be initialized in constructor and will not change afterwards.

        Returns:
        comments object