public abstract static class FieldEvents.TextChangeEvent extends Component.Event
TextChangeEvents differ from Field.ValueChangeEvent
s so that they are
triggered repeatedly while the end user is filling the field.
ValueChangeEvents are not fired until the user for example hits enter or
focuses another field. Also note the difference that TextChangeEvents are
only fired if the change is triggered from the user, while
ValueChangeEvents are also fired if the field value is set by the
application code.
The FieldEvents.TextChangeNotifier
s implementation may decide when exactly
TextChangeEvents are fired. TextChangeEvents are not necessary fire for
example on each key press, but buffered with a small delay. The
TextField
component supports different modes for triggering
TextChangeEvents.
FieldEvents.TextChangeListener
,
FieldEvents.TextChangeNotifier
,
TextField#setTextChangeEventMode(com.vaadin.ui.TextField.TextChangeEventMode)
,
Serialized Formsource
Constructor and Description |
---|
TextChangeEvent(Component source) |
Modifier and Type | Method and Description |
---|---|
abstract int |
getCursorPosition() |
abstract String |
getText() |
getComponent
getConnector
getSource, toString
public TextChangeEvent(Component source)
public abstract String getText()
FieldEvents.TextChangeEvent
public abstract int getCursorPosition()
FieldEvents.TextChangeEvent
Copyright © 2022 Vaadin Ltd. All rights reserved.