com.vaadin.ui.components.grid.
Interface HeaderCell
-
All Superinterfaces:
All Known Implementing Classes:
public interface HeaderCell extends Serializable
An individual cell on a Grid header row.
Since:
8.0
Author:
Vaadin Ltd
-
-
Method Summary
All Methods Modifier and Type Method Description GridStaticCellType
getCellType()
Returns the type of content stored in this cell.
String
getColumnId()
Gets the column id where this cell is.
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.
String
getStyleName()
Returns the custom style name for this cell.
String
getText()
Returns the textual caption of this cell.
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.
-
-
-
Method Detail
-
getText
String getText()
Returns the textual caption of this cell.
Returns:
the header caption
-
setText
void setText(String text)
Sets the textual caption of this cell.
Parameters:
text
- the header caption to set, not null
-
getHtml
String getHtml()
Returns the HTML content displayed in this cell.
Returns:
the html
-
setHtml
void setHtml(String html)
Sets the HTML content displayed in this cell.
Parameters:
html
- the html to set
-
getComponent
Component getComponent()
Returns the component displayed in this cell.
Returns:
the component
-
setComponent
void setComponent(Component component)
Sets the component displayed in this cell.
Parameters:
component
- the component to set
-
getCellType
GridStaticCellType getCellType()
Returns the type of content stored in this cell.
Returns:
cell content type
-
getColumnId
String getColumnId()
Gets the column id where this cell is.
Returns:
column id for this cell
-
getStyleName
String getStyleName()
Returns the custom style name for this cell.
Returns:
the style name or null if no style name has been set
-
setStyleName
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
-
getDescription
String getDescription()
Gets the tooltip for the cell.
The tooltip is shown in the mode returned by
getDescriptionContentMode()
.Returns:
the tooltip text for this cell
Since:
8.4
-
setDescription
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 cellSince:
8.4
-
setDescription
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:
-
getDescriptionContentMode
ContentMode getDescriptionContentMode()
Gets the content mode for the tooltip.
Returns:
the content mode for the tooltip
Since:
8.4
See Also:
-
setDescriptionContentMode
void setDescriptionContentMode(ContentMode descriptionContentMode)
Sets the content mode for the tooltip.
Parameters:
descriptionContentMode
- the content mode for the tooltipSince:
8.4
See Also:
-
-