T - type of data table recordsE - the enum typepublic class EnumHeaderFilter<T,E extends Enum> extends Object implements ColumnHeaderFilterPlugin.HeaderFilter<T>
Select component| Constructor and Description |
|---|
EnumHeaderFilter(E[] values,
String allLabel)
Creates a filter from an array of enum values and a custom label for all option
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Clears the header filter component value
|
static <T,E extends Enum> |
create(E[] values)
Creates a filter from an array of enum values and default label ALL for all option
|
static <T,E extends Enum> |
create(E[] values,
String allLabel)
Creates a filter from an array of enum values and a custom label for all option
|
elemental2.dom.HTMLElement |
element() |
Select<String> |
getSelect() |
void |
init(SearchContext<T> searchContext,
ColumnConfig<T> columnConfig)
Initializes the header filter with the data table search context and the column config to
which the filter is being added
|
public static <T,E extends Enum> EnumHeaderFilter<T,E> create(E[] values)
T - type of data table recordsE - the enum typevalues - Array of enum valuespublic static <T,E extends Enum> EnumHeaderFilter<T,E> create(E[] values, String allLabel)
T - type of data table recordsE - the enum typevalues - Array of enum valuespublic void init(SearchContext<T> searchContext, ColumnConfig<T> columnConfig)
this will be called by the ColumnHeaderFilterPlugin
init in interface ColumnHeaderFilterPlugin.HeaderFilter<T>searchContext - SearchContextcolumnConfig - ColumnConfigpublic void clear()
this will be called by the ColumnHeaderFilterPlugin
clear in interface ColumnHeaderFilterPlugin.HeaderFilter<T>public elemental2.dom.HTMLElement element()
element in interface org.jboss.elemento.IsElement<elemental2.dom.HTMLElement>Copyright © 2019–2022 Dominokit. All rights reserved.