V - Value typepublic interface Input<V> extends ValueHolder<V>, ValueComponent<V>
Extends ValueHolder since handles a value, supporting ValueChangeListeners registration.
The actual UI Component which represents the input component can be obtained through ValueComponent.getComponent().
| Modifier and Type | Interface and Description |
|---|---|
static interface |
Input.InputFieldPropertyRenderer<T,F extends com.vaadin.data.HasValue<T> & com.vaadin.ui.Component>
|
static interface |
Input.InputPropertyRenderer<T>
|
ValueHolder.ValueChangeEvent<V>, ValueHolder.ValueChangeListener<V>| Modifier and Type | Method and Description |
|---|---|
void |
focus()
Sets the focus for this input component, if supported by concrete component implementation.
|
static <F extends com.vaadin.data.HasValue<T> & com.vaadin.ui.Component,T> |
from(F field)
Create a
Input component type from given HasValue component. |
boolean |
isReadOnly()
Returns whether this input component is in read-only mode or not.
|
boolean |
isRequired()
Gets whether the field is required, i.e. a required indicator symbol is visible.
|
void |
setReadOnly(boolean readOnly)
Sets the read-only mode of this input component.
|
void |
setRequired(boolean required)
Sets whether the required indicator symbol is visible.
|
addValueChangeListener, clear, getEmptyValue, getOptionalValue, getValue, isEmpty, setValuegetComponent, getValuevoid setReadOnly(boolean readOnly)
readOnly - the read-only mode of this input componentboolean isReadOnly()
false if the user can modify the value, true if notboolean isRequired()
true if the field as required, false otherwisevoid setRequired(boolean required)
required - true to set the field as required, false otherwisevoid focus()
static <F extends com.vaadin.data.HasValue<T> & com.vaadin.ui.Component,T> Input<T> from(F field)
Input component type from given HasValue component.T - Value typeF - HasValue component typefield - The field instance (not null)Input component which wraps the given fieldCopyright © 2017 The Holon Platform. All rights reserved.