CommentCollection

CommentCollection class

Encapsulates a collection of Comment objects.

Methods

NameDescription
add(row, column)Adds a comment to the collection.
add(cellName)Adds a comment to the collection.
add()Reserved for internal use.
addThreadedComment(row, column, text, author)Adds a threaded comment.
addThreadedComment(cellName, text, author)Adds a threaded comment.
clear()Removes all comments;
contains()Reserved for internal use.
get(index)Gets the Comment element at the specified index.
get(cellName)Gets the Comment element at the specified cell.
get(row, column)Gets the Comment element at the specified row index and column index.
get()Reserved for internal use.
getCount()
getThreadedComments(row, column)Gets the threaded comments by row and column index.
getThreadedComments(cellName)Gets the threaded comments by cell name.
indexOf()Reserved for internal use.
iterator()
removeAt(cellName)Removes the comment of the specific cell.
removeAt(row, column)Removes the comment of the specific cell.
removeAt()

add(row, column)

Adds a comment to the collection.

ParameterTypeDescription
rowNumberCell row index.
columnNumberCell column index.

Returns: Number — Number Comment object index.

add(cellName)

Adds a comment to the collection.

ParameterTypeDescription
cellNameStringCell name.

Returns: Number — Number Comment object index.

add()

Reserved for internal use.

addThreadedComment(row, column, text, author)

Adds a threaded comment.

ParameterTypeDescription
rowNumberCell row index.
columnNumberCell column index.
textStringThe text of the comment
authorThreadedCommentAuthorThe user of this threaded comment.

Returns: Number — Number ThreadedComment object index.

addThreadedComment(cellName, text, author)

Adds a threaded comment.

ParameterTypeDescription
cellNameStringThe name of the cell.
textStringThe text of the comment
authorThreadedCommentAuthorThe user of this threaded comment.

Returns: Number — Number ThreadedComment object index.

clear()

Removes all comments;

contains()

Reserved for internal use.

get(index)

Gets the Comment element at the specified index.

ParameterTypeDescription
indexNumberThe zero based index of the element.

Returns: Comment — Comment The element at the specified index.

get(cellName)

Gets the Comment element at the specified cell.

ParameterTypeDescription
cellNameStringCell name.

Returns: Comment — Comment The element at the specified cell.

get(row, column)

Gets the Comment element at the specified row index and column index.

ParameterTypeDescription
rowNumberRow index.
columnNumberColumn index.

Returns: Comment — Comment The element at the specified cell.

get()

Reserved for internal use.

getCount()

getThreadedComments(row, column)

Gets the threaded comments by row and column index.

ParameterTypeDescription
rowNumberThe row index.
columnNumberThe column index.

Returns: ThreadedCommentCollection — ThreadedCommentCollection

getThreadedComments(cellName)

Gets the threaded comments by cell name.

ParameterTypeDescription
cellNameStringThe name of the cell.

Returns: ThreadedCommentCollection — ThreadedCommentCollection

indexOf()

Reserved for internal use.

iterator()

removeAt(cellName)

Removes the comment of the specific cell.

ParameterTypeDescription
cellNameStringThe name of cell which contains a comment.

removeAt(row, column)

Removes the comment of the specific cell.

ParameterTypeDescription
rowNumberThe row index.
columnNumberthe column index.

removeAt()