Class VTextField

    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.vaadin.flow.component.textfield.GeneratedVaadinTextField

        com.vaadin.flow.component.textfield.GeneratedVaadinTextField.ChangeEvent<R extends com.vaadin.flow.component.textfield.GeneratedVaadinTextField<R,​?>>, com.vaadin.flow.component.textfield.GeneratedVaadinTextField.InvalidChangeEvent<R extends com.vaadin.flow.component.textfield.GeneratedVaadinTextField<R,​?>>
      • Nested classes/interfaces inherited from class com.vaadin.flow.component.AbstractField

        com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<C extends com.vaadin.flow.component.Component,​V extends Object>
      • Nested classes/interfaces inherited from interface com.vaadin.flow.component.BlurNotifier

        com.vaadin.flow.component.BlurNotifier.BlurEvent<C extends com.vaadin.flow.component.Component>
      • Nested classes/interfaces inherited from interface com.vaadin.flow.component.FocusNotifier

        com.vaadin.flow.component.FocusNotifier.FocusEvent<C extends com.vaadin.flow.component.Component>
      • Nested classes/interfaces inherited from interface com.vaadin.flow.component.HasValue

        com.vaadin.flow.component.HasValue.ValueChangeEvent<V extends Object>, com.vaadin.flow.component.HasValue.ValueChangeListener<E extends com.vaadin.flow.component.HasValue.ValueChangeEvent<?>>
    • Field Summary

      • Fields inherited from interface com.vaadin.flow.component.textfield.HasAutocapitalize

        AUTOCAPITALIZE_ATTRIBUTE
      • Fields inherited from interface com.vaadin.flow.component.textfield.HasAutocomplete

        AUTOCOMPLETE_ATTRIBUTE
      • Fields inherited from interface com.vaadin.flow.component.textfield.HasAutocorrect

        AUTOCORRECT_ATTRIBUTE
      • Fields inherited from interface com.vaadin.flow.data.value.HasValueChangeMode

        DEFAULT_CHANGE_TIMEOUT
    • Constructor Summary

      Constructors 
      Constructor Description
      VTextField()  
      VTextField​(com.vaadin.flow.component.HasValue.ValueChangeListener<? super com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<com.vaadin.flow.component.textfield.TextField,​String>> listener)  
      VTextField​(String label)  
      VTextField​(String label, com.vaadin.flow.component.HasValue.ValueChangeListener<? super com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<com.vaadin.flow.component.textfield.TextField,​String>> listener)  
      VTextField​(String label, String placeholder)  
      VTextField​(String label, String initialValue, com.vaadin.flow.component.HasValue.ValueChangeListener<? super com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<com.vaadin.flow.component.textfield.TextField,​String>> listener)  
      VTextField​(String label, String initialValue, String placeholder)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void initializeSettings()  
      void setValue​(String value)  
      VTextField withAutoselect​(boolean autoselect)  
      VTextField withClearButtonVisible​(boolean clearButtonVisible)  
      VTextField withMaxLength​(int maxLength)  
      VTextField withMinLength​(int minLength)  
      VTextField withPattern​(String pattern)  
      VTextField withPlaceholder​(String placeholder)  
      VTextField withPreventInvalidInput​(boolean preventInvalidInput)  
      VTextField withReadOnly​(boolean readOnly)  
      VTextField withRequired​(boolean required)  
      VTextField withThemeVariants​(com.vaadin.flow.component.textfield.TextFieldVariant... variants)  
      VTextField withTitle​(String title)  
      VTextField withValueChangeMode​(com.vaadin.flow.data.value.ValueChangeMode valueChangeMode)  
      VTextField withValueChangeTimeout​(int valueChangeTimeout)  
      • Methods inherited from class com.vaadin.flow.component.textfield.TextField

        getEmptyValue, getErrorMessage, getLabel, getMaxLength, getMinLength, getPattern, getPlaceholder, getTitle, getValue, getValueChangeMode, getValueChangeTimeout, isAutofocus, isAutoselect, isClearButtonVisible, isInvalid, isPreventInvalidInput, isRequired, onAttach, setAutofocus, setAutoselect, setClearButtonVisible, setErrorMessage, setInvalid, setLabel, setMaxLength, setMinLength, setPattern, setPlaceholder, setPreventInvalidInput, setRequired, setRequiredIndicatorVisible, setTitle, setValueChangeMode, setValueChangeTimeout, validate
      • Methods inherited from class com.vaadin.flow.component.textfield.GeneratedVaadinTextField

        addChangeListener, addInvalidChangeListener, addThemeVariants, addToInput, addToPrefix, addToSuffix, checkValidity, getAutocapitalizeString, getAutocompleteString, getAutocorrectString, getErrorMessageString, getLabelString, getListString, getMaxlengthDouble, getMinlengthDouble, getNameString, getPatternString, getPlaceholderString, getTitleString, isAutofocusBoolean, isAutoselectBoolean, isClearButtonVisibleBoolean, isDisabledBoolean, isInvalidBoolean, isPreventInvalidInputBoolean, isReadonlyBoolean, isRequiredBoolean, remove, removeAll, removeThemeVariants, setAutocapitalize, setAutocomplete, setAutocorrect, setDisabled, setList, setMaxlength, setMinlength, setName, setReadonly
      • Methods inherited from class com.vaadin.flow.component.AbstractSinglePropertyField

        getSynchronizationRegistration, hasValidValue, setPresentationValue, setSynchronizedEvent
      • Methods inherited from class com.vaadin.flow.component.AbstractField

        addValueChangeListener, isEmpty, setModelValue, valueEquals
      • Methods inherited from class com.vaadin.flow.component.Component

        addListener, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getLocale, getParent, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onDetach, onEnabledStateChanged, set, setElement, setId, setVisible
      • Methods inherited from interface com.vaadin.flow.component.AttachNotifier

        addAttachListener
      • Methods inherited from interface com.vaadin.flow.component.BlurNotifier

        addBlurListener
      • Methods inherited from interface com.vaadin.flow.component.CompositionNotifier

        addCompositionEndListener, addCompositionStartListener, addCompositionUpdateListener
      • Methods inherited from interface com.vaadin.flow.component.DetachNotifier

        addDetachListener
      • Methods inherited from interface com.vaadin.flow.component.Focusable

        addFocusShortcut, blur, focus, getTabIndex, setTabIndex
      • Methods inherited from interface com.vaadin.flow.component.FocusNotifier

        addFocusListener
      • Methods inherited from interface com.vaadin.flow.component.textfield.HasAutocapitalize

        getAutocapitalize, setAutocapitalize
      • Methods inherited from interface com.vaadin.flow.component.textfield.HasAutocomplete

        getAutocomplete, setAutocomplete
      • Methods inherited from interface com.vaadin.flow.component.textfield.HasAutocorrect

        isAutocorrect, setAutocorrect
      • Methods inherited from interface com.vaadin.flow.component.HasElement

        getElement
      • Methods inherited from interface com.vaadin.flow.component.HasEnabled

        isEnabled, setEnabled
      • Methods inherited from interface com.vaadin.flow.component.HasHelper

        getHelperComponent, getHelperText, setHelperComponent, setHelperText
      • Methods inherited from interface com.vaadin.flow.component.textfield.HasPrefixAndSuffix

        getPrefixComponent, getSuffixComponent, setPrefixComponent, setSuffixComponent
      • Methods inherited from interface com.vaadin.flow.component.HasSize

        getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFull
      • Methods inherited from interface com.vaadin.flow.component.HasStyle

        addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassName
      • Methods inherited from interface com.vaadin.flow.component.HasTheme

        addThemeName, addThemeNames, getThemeName, getThemeNames, hasThemeName, removeThemeName, removeThemeNames, setThemeName, setThemeName
      • Methods inherited from interface com.vaadin.flow.component.HasValidation

        getErrorMessage, isInvalid, setErrorMessage, setInvalid
      • Methods inherited from interface com.vaadin.flow.component.HasValue

        addValueChangeListener, clear, getEmptyValue, getOptionalValue, getValue, isEmpty
      • Methods inherited from interface com.vaadin.flow.component.HasValueAndElement

        isReadOnly, isRequiredIndicatorVisible, setReadOnly
      • Methods inherited from interface com.vaadin.flow.component.InputNotifier

        addInputListener
      • Methods inherited from interface com.vaadin.flow.component.KeyNotifier

        addKeyDownListener, addKeyDownListener, addKeyPressListener, addKeyPressListener, addKeyUpListener, addKeyUpListener
    • Constructor Detail

      • VTextField

        public VTextField()
      • VTextField

        public VTextField​(String label)
      • VTextField

        public VTextField​(String label,
                          String placeholder)
      • VTextField

        public VTextField​(String label,
                          String initialValue,
                          String placeholder)
      • VTextField

        public VTextField​(com.vaadin.flow.component.HasValue.ValueChangeListener<? super com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<com.vaadin.flow.component.textfield.TextField,​String>> listener)
      • VTextField

        public VTextField​(String label,
                          com.vaadin.flow.component.HasValue.ValueChangeListener<? super com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<com.vaadin.flow.component.textfield.TextField,​String>> listener)
      • VTextField

        public VTextField​(String label,
                          String initialValue,
                          com.vaadin.flow.component.HasValue.ValueChangeListener<? super com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<com.vaadin.flow.component.textfield.TextField,​String>> listener)
    • Method Detail

      • initializeSettings

        protected void initializeSettings()
      • withRequired

        public VTextField withRequired​(boolean required)
      • setValue

        public void setValue​(String value)
        Specified by:
        setValue in interface com.vaadin.flow.component.HasValue<com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<com.vaadin.flow.component.textfield.TextField,​String>,​String>
        Overrides:
        setValue in class com.vaadin.flow.component.textfield.TextField
      • withThemeVariants

        public VTextField withThemeVariants​(com.vaadin.flow.component.textfield.TextFieldVariant... variants)
      • withValueChangeMode

        public VTextField withValueChangeMode​(com.vaadin.flow.data.value.ValueChangeMode valueChangeMode)
      • withValueChangeTimeout

        public VTextField withValueChangeTimeout​(int valueChangeTimeout)
      • withAutoselect

        public VTextField withAutoselect​(boolean autoselect)
      • withPreventInvalidInput

        public VTextField withPreventInvalidInput​(boolean preventInvalidInput)
      • withClearButtonVisible

        public VTextField withClearButtonVisible​(boolean clearButtonVisible)
      • withMaxLength

        public VTextField withMaxLength​(int maxLength)
      • withMinLength

        public VTextField withMinLength​(int minLength)