ITEM - the type of the input object that can be used by the rendered
componentpublic class TextRenderer<ITEM> extends ComponentRenderer<com.vaadin.flow.component.Component,ITEM>
ItemLabelGenerator.| Constructor and Description |
|---|
TextRenderer()
Creates a new renderer instance using the default
ItemLabelGenerator: String::valueOf. |
TextRenderer(com.vaadin.flow.component.ItemLabelGenerator<ITEM> itemLabelGenerator)
Creates a new renderer instance using the provided
itemLabelGenerator. |
| Modifier and Type | Method and Description |
|---|---|
com.vaadin.flow.component.Component |
createComponent(ITEM item)
Creates a component for a given object model item.
|
protected com.vaadin.flow.dom.Element |
createElement(String item)
Creates a new
Element that represent the rendered item. |
render, setComponentRendererTag, updateComponentgetEventHandlers, getValueProviders, render, setEventHandler, setPropertypublic TextRenderer()
ItemLabelGenerator: String::valueOf.public TextRenderer(com.vaadin.flow.component.ItemLabelGenerator<ITEM> itemLabelGenerator)
itemLabelGenerator.itemLabelGenerator - the item label generatorpublic com.vaadin.flow.component.Component createComponent(ITEM item)
ComponentRenderercreateComponent in class ComponentRenderer<com.vaadin.flow.component.Component,ITEM>item - the model item, possibly nullprotected com.vaadin.flow.dom.Element createElement(String item)
Element that represent the rendered item.
By default the text is wrapped inside a <span> element.
Subclasses may override this method to return some other Element.
item - the item to renderCopyright © 2022. All rights reserved.