Smartsheet.Api.Internal.CommentResourcesImpl.GetComment C# (CSharp) Method

GetComment() private method

private GetComment ( long id ) : Comment
id long
return Smartsheet.Api.Models.Comment
        public virtual Comment GetComment(long id)
        {
            throw new NotSupportedException();
        }

Usage Example

Example #1
0
        public virtual void TestGetComment()
        {
            server.setResponseBody("../../../TestSDK/resources/getComment.json");

            Comment comment = commentResources.GetComment(1234L);

            Assert.AreEqual(3831661625403268L, (long)comment.ID);
            Assert.AreEqual("This text is the body of the first comment", comment.Text);
            Assert.AreEqual("Brett Batie", comment.CreatedBy.Name);
            Assert.AreEqual("*****@*****.**", comment.CreatedBy.Email);

            // Test equals method
            Comment newComment = new Comment();

            newComment.ID = 3831661625403268L;
            Assert.True(comment.GetHashCode() == newComment.GetHashCode());
        }