Package org.patternfly.component.form
Class FormSelect
- java.lang.Object
-
- org.patternfly.component.BaseComponent<E,B>
-
- org.patternfly.component.form.FormControl<HTMLElement,FormSelect>
-
- org.patternfly.component.form.FormSelect
-
- All Implemented Interfaces:
Attachable,Container<HTMLElement,FormSelect>,Finder<HTMLElement>,HasElement<HTMLElement,FormSelect>,HasHTMLElement<HTMLElement,FormSelect>,IsElement<HTMLElement>,TypedBuilder<HTMLElement,FormSelect>,Component,HasValue<String>,Modifiers.Disabled<HTMLElement,FormSelect>,Modifiers.Required<HTMLElement,FormSelect>
public class FormSelect extends FormControl<HTMLElement,FormSelect> implements HasValue<String>, Attachable
A form select embeds browser native select lists into a form.
-
-
Method Summary
-
Methods inherited from class org.patternfly.component.form.FormControl
disabled, validated
-
Methods inherited from class org.patternfly.component.BaseComponent
componentType, element
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jboss.elemento.Attachable
detach
-
Methods inherited from interface org.jboss.elemento.Container
add, add, add, addAll, addAll, addAll, addAll, addAll, addAll
-
Methods inherited from interface org.jboss.elemento.HasElement
add, apply, aria, aria, aria, attr, attr, attr, classList, classList, css, id, id, innerHtml, on, run, textContent, textNode, toggle, toggle, toggle, uniqueId
-
Methods inherited from interface org.jboss.elemento.HasHTMLElement
data, hidden, style, style, style, style, style, style, title
-
Methods inherited from interface org.patternfly.style.Modifiers.Disabled
disabled, isDisabled
-
Methods inherited from interface org.patternfly.style.Modifiers.Required
required
-
-
-
-
Method Detail
-
formSelect
public static FormSelect formSelect(String id)
-
formSelect
public static FormSelect formSelect(String id, String value)
-
attach
public void attach(MutationRecord mutationRecord)
- Specified by:
attachin interfaceAttachable
-
addGroups
public <T> FormSelect addGroups(Iterable<T> items, Function<T,FormSelectOptionGroup> display)
-
addGroup
public FormSelect addGroup(FormSelectOptionGroup group)
-
add
public FormSelect add(FormSelectOptionGroup group)
-
addOptions
public <T> FormSelect addOptions(Iterable<T> items, Function<T,FormSelectOption> display)
-
addOption
public FormSelect addOption(FormSelectOption option)
-
add
public FormSelect add(FormSelectOption option)
-
required
public FormSelect required(boolean required)
- Specified by:
requiredin interfaceModifiers.Required<HTMLElement,FormSelect>
-
value
public FormSelect value(String value)
Same as value(String, false)
-
value
public FormSelect value(String value, boolean fireEvent)
-
applyTo
public FormSelect applyTo(Consumer<HTMLElementBuilder<HTMLSelectElement>> consumer)
Provides access to the underlying select element using a fluent API style
-
that
public FormSelect that()
- Specified by:
thatin interfaceTypedBuilder<HTMLElement,FormSelect>
-
onChange
public FormSelect onChange(ChangeHandler<FormSelect,String> changeHandler)
Defines a change handler that is called when thevalue()of this select changes. Changes are detected by adding an event listener for input event to the select element.
-
selectElement
public HTMLElementBuilder<HTMLSelectElement> selectElement()
Returns the underlying input element
-
-