Package com.vaadin.ui.components.grid
Class Footer.Row.Cell
- java.lang.Object
-
- com.vaadin.ui.components.grid.Footer.Row.Cell
-
- All Implemented Interfaces:
FooterCell
,Serializable
- Enclosing class:
- Footer.Row
public class Footer.Row.Cell extends Object implements FooterCell
A cell in a Grid footer row.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
Cell()
Creates a new footer cell.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected SectionState.CellState
getCellState()
Returns the shared state of this cell.GridStaticCellType
getCellType()
Returns the type of content stored in this cell.String
getColumnId()
Component
getComponent()
Returns the component displayed in this cell.String
getDescription()
Gets the tooltip for the cell.ContentMode
getDescriptionContentMode()
Gets the content mode for the tooltip.String
getHtml()
Returns the HTML content displayed in this cell.StaticSection.StaticRow<?>
getRow()
Gets the row where this cell is.String
getStyleName()
Returns the custom style name for this cell.String
getText()
Returns the textual caption of this cell.protected void
readDesign(org.jsoup.nodes.Element cellElement, DesignContext designContext)
Reads the declarative design from the given table cell element.void
setComponent(Component component)
Sets the component displayed in this cell.void
setDescription(String description)
Sets the tooltip for the cell.void
setDescription(String description, ContentMode descriptionContentMode)
Sets the tooltip for the cell to be shown with the given content mode.void
setDescriptionContentMode(ContentMode descriptionContentMode)
Sets the content mode for the tooltip.void
setHtml(String html)
Sets the HTML content displayed in this cell.void
setStyleName(String styleName)
Sets a custom style name for this cell.void
setText(String text)
Sets the textual caption of this cell.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.vaadin.ui.components.grid.FooterCell
getCellType, getColumnId, getComponent, getDescription, getDescriptionContentMode, getHtml, getStyleName, getText, setComponent, setDescription, setDescription, setDescriptionContentMode, setHtml, setStyleName, setText
-
-
-
-
Method Detail
-
getColumnId
public String getColumnId()
-
getRow
public StaticSection.StaticRow<?> getRow()
Gets the row where this cell is.- Returns:
- row for this cell
-
getCellState
protected SectionState.CellState getCellState()
Returns the shared state of this cell.- Returns:
- the cell state
-
setText
public void setText(String text)
Sets the textual caption of this cell.- Parameters:
text
- a plain text caption, not null
-
getText
public String getText()
Returns the textual caption of this cell.- Returns:
- the plain text caption
-
getHtml
public String getHtml()
Returns the HTML content displayed in this cell.- Returns:
- the html
-
setHtml
public void setHtml(String html)
Sets the HTML content displayed in this cell.- Parameters:
html
- the html to set, not null
-
getComponent
public Component getComponent()
Returns the component displayed in this cell.- Returns:
- the component
-
setComponent
public void setComponent(Component component)
Sets the component displayed in this cell.- Parameters:
component
- the component to set, not null
-
getCellType
public GridStaticCellType getCellType()
Returns the type of content stored in this cell.- Returns:
- cell content type
-
getStyleName
public String getStyleName()
Returns the custom style name for this cell.- Returns:
- the style name or null if no style name has been set
-
setStyleName
public void setStyleName(String styleName)
Sets a custom style name for this cell.- Parameters:
styleName
- the style name to set or null to not use any style name
-
readDesign
protected void readDesign(org.jsoup.nodes.Element cellElement, DesignContext designContext)
Reads the declarative design from the given table cell element.- Parameters:
cellElement
- Element to read design fromdesignContext
- the design context- Since:
- 7.5.0
-
getDescription
public String getDescription()
Gets the tooltip for the cell.The tooltip is shown in the mode returned by
getDescriptionContentMode()
.- Since:
- 8.4
-
setDescription
public void setDescription(String description)
Sets the tooltip for the cell.By default, tooltips are shown as plain text. For HTML tooltips, see
setDescription(String, ContentMode)
orsetDescriptionContentMode(ContentMode)
.- Parameters:
description
- the tooltip to show when hovering the cell- Since:
- 8.4
-
setDescription
public void setDescription(String description, ContentMode descriptionContentMode)
Sets the tooltip for the cell to be shown with the given content mode.- Parameters:
description
- the tooltip to show when hovering the celldescriptionContentMode
- the content mode to use for the tooltip (HTML or plain text)- Since:
- 8.4
- See Also:
ContentMode
-
getDescriptionContentMode
public ContentMode getDescriptionContentMode()
Gets the content mode for the tooltip.- Returns:
- the content mode for the tooltip
- Since:
- 8.4
- See Also:
ContentMode
-
setDescriptionContentMode
public void setDescriptionContentMode(ContentMode descriptionContentMode)
Sets the content mode for the tooltip.- Parameters:
descriptionContentMode
- the content mode for the tooltip- Since:
- 8.4
- See Also:
ContentMode
-
-