Package com.storedobject.ui.util
Interface HtmlTemplate.ComponentCreator
- Enclosing class:
HtmlTemplate
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Represents a functional interface that provides methods for creating components
and SVG elements based on unique identifiers or tags. It is primarily used
within the context of HTML templates to dynamically generate components.
- Author:
- Syam
-
Method Summary
Modifier and TypeMethodDescriptioncom.vaadin.flow.component.ComponentCreates a component based on the given unique identifier.default com.vaadin.flow.component.ComponentcreateComponentForId(String id, String tag) Creates a component based on the given unique identifier and optionally a tag.default com.vaadin.flow.component.SvgcreateSvgForId(String id) Creates an SVG element based on the given unique identifier.
-
Method Details
-
createComponentForId
Creates a component based on the given unique identifier.- Parameters:
id- the unique identifier used to create the component- Returns:
- the created component associated with the provided identifier
-
createComponentForId
Creates a component based on the given unique identifier and optionally a tag.- Parameters:
id- the unique identifier used to create the componenttag- the tag used for additional customization or specification (currently unused in the implementation)- Returns:
- the created component associated with the provided identifier
-
createSvgForId
Creates an SVG element based on the given unique identifier.- Parameters:
id- the unique identifier used to create the SVG element- Returns:
- the created SVG element associated with the provided identifier, or null if no SVG element could be created
-