Top Methods
org.apache.poi.ss.usermodel

public Interface Comment

Known Direct Implementers
org.apache.poi.hssf.usermodel.HSSFComment
Imports
org.apache.poi.ss.util.CellAddress

Method Summary

Modifier and TypeMethod and Description
public CellAddress

Returns:

comment cell address
getAddress
()

Get the address of the cell that this comment is attached to

public String

Returns:

the name of the original author of the comment
getAuthor
()

Name of the original comment author

public ClientAnchor

Returns:

defined position of this anchor in the sheet, can be null
getClientAnchor
()

Return defined position of this anchor in the sheet.

public int

Returns:

the 0-based column of the cell that contains the comment
getColumn
()

Return the column of the cell that contains the comment

public int

Returns:

the 0-based row of the cell that contains the comment
getRow
()

Return the row of the cell that contains the comment

public RichTextString
getString()

Fetches the rich text string of the comment

public boolean

Returns:

true if the comment is visible, false otherwise
isVisible
()

Returns whether this comment is visible.

public void
setAddress(CellAddress addr)

Set the address of the cell that this comment is attached to

public void
setAddress(int row, int col)

Set the address of the cell that this comment is attached to

public void
setAuthor(String
the name of the original author of the comment
author
)

Name of the original comment author

public void
setColumn(int
the 0-based column of the cell that contains the comment
col
)

Set the column of the cell that contains the comment

public void
setRow(int
the 0-based row of the cell that contains the comment
row
)

Set the row of the cell that contains the comment

public void
setString(RichTextString
Sets the rich text string used by this object.
string
)

Sets the rich text string used by this comment.

public void
setVisible(boolean
true if the comment is visible, false otherwise
visible
)

Sets whether this comment is visible.

Method Detail

getAddressback to summary
public CellAddress getAddress()

Get the address of the cell that this comment is attached to

Returns:CellAddress

comment cell address

Since
3.15-beta1
getAuthorback to summary
public String getAuthor()

Name of the original comment author

Returns:String

the name of the original author of the comment

getClientAnchorback to summary
public ClientAnchor getClientAnchor()

Return defined position of this anchor in the sheet. The anchor is the yellow box/balloon that is rendered on top of the sheets when the comment is visible. To associate a comment with a different cell, use setAddress.

Returns:ClientAnchor

defined position of this anchor in the sheet, can be null

getColumnback to summary
public int getColumn()

Return the column of the cell that contains the comment

Returns:int

the 0-based column of the cell that contains the comment

getRowback to summary
public int getRow()

Return the row of the cell that contains the comment

Returns:int

the 0-based row of the cell that contains the comment

getStringback to summary
public RichTextString getString()

Fetches the rich text string of the comment

isVisibleback to summary
public boolean isVisible()

Returns whether this comment is visible.

Returns:boolean

true if the comment is visible, false otherwise

setAddressback to summary
public void setAddress(CellAddress addr)

Set the address of the cell that this comment is attached to

Since
3.15-beta1
setAddressback to summary
public void setAddress(int row, int col)

Set the address of the cell that this comment is attached to

Since
3.15-beta1
setAuthorback to summary
public void setAuthor(String author)

Name of the original comment author

Parameters
author:String

the name of the original author of the comment

setColumnback to summary
public void setColumn(int col)

Set the column of the cell that contains the comment

Parameters
col:int

the 0-based column of the cell that contains the comment

setRowback to summary
public void setRow(int row)

Set the row of the cell that contains the comment

Parameters
row:int

the 0-based row of the cell that contains the comment

setStringback to summary
public void setString(RichTextString string)

Sets the rich text string used by this comment.

Parameters
string:RichTextString

Sets the rich text string used by this object.

setVisibleback to summary
public void setVisible(boolean visible)

Sets whether this comment is visible.

Parameters
visible:boolean

true if the comment is visible, false otherwise