com.vaadin.flow.component.textfield.
Class NumberField.NumberFieldI18n
All Implemented Interfaces:
Enclosing class:
The internationalization properties for NumberField.
See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the error message displayed when the field contains user input that the server is unable to convert to type
Number.Gets the error message displayed when the field value is greater than the maximum allowed value.
Gets the error message displayed when the field value is smaller than the minimum allowed value.
Gets the error message displayed when the field is required but empty.
Gets the error message displayed when the field value is not a multiple of the step value.
setBadInputErrorMessage(String errorMessage) Sets the error message to display when the field contains user input that the server is unable to convert to type
Number.setMaxErrorMessage(String errorMessage) Sets the error message to display when the field value is greater than the maximum allowed value.
setMinErrorMessage(String errorMessage) Sets the error message to display when the field value is smaller than the minimum allowed value.
setRequiredErrorMessage(String errorMessage) Sets the error message to display when the field is required but empty.
setStepErrorMessage(String errorMessage) Sets the error message to display when the field value is not a multiple of the step value.
-
Constructor Details
-
NumberFieldI18n
public NumberFieldI18n()
-
-
Method Details
-
getBadInputErrorMessage
Gets the error message displayed when the field contains user input that the server is unable to convert to type
Number.Specified by:
getBadInputErrorMessagein interfaceAbstractNumberFieldI18nReturns:
the error message or
nullif not set -
setBadInputErrorMessage
Sets the error message to display when the field contains user input that the server is unable to convert to type
Number.Note, custom error messages set with
NumberField.setErrorMessage(String)take priority over i18n error messages.Parameters:
errorMessage- the error message to set, ornullto clearReturns:
this instance for method chaining
-
getRequiredErrorMessage
Gets the error message displayed when the field is required but empty.
Specified by:
getRequiredErrorMessagein interfaceAbstractNumberFieldI18nReturns:
the error message or
nullif not setSee Also:
-
setRequiredErrorMessage
Sets the error message to display when the field is required but empty.
Note, custom error messages set with
NumberField.setErrorMessage(String)take priority over i18n error messages.Parameters:
errorMessage- the error message to set, ornullto clearReturns:
this instance for method chaining
See Also:
-
getMinErrorMessage
Gets the error message displayed when the field value is smaller than the minimum allowed value.
Specified by:
getMinErrorMessagein interfaceAbstractNumberFieldI18nReturns:
the error message or
nullif not setSee Also:
-
setMinErrorMessage
Sets the error message to display when the field value is smaller than the minimum allowed value.
Note, custom error messages set with
NumberField.setErrorMessage(String)take priority over i18n error messages.Parameters:
errorMessage- the error message to set, ornullto clearReturns:
this instance for method chaining
See Also:
-
getMaxErrorMessage
Gets the error message displayed when the field value is greater than the maximum allowed value.
Specified by:
getMaxErrorMessagein interfaceAbstractNumberFieldI18nReturns:
the error message or
nullif not setSee Also:
-
setMaxErrorMessage
Sets the error message to display when the field value is greater than the maximum allowed value.
Note, custom error messages set with
NumberField.setErrorMessage(String)take priority over i18n error messages.Parameters:
errorMessage- the error message to set, ornullto clearReturns:
this instance for method chaining
See Also:
-
getStepErrorMessage
Gets the error message displayed when the field value is not a multiple of the step value.
Specified by:
getStepErrorMessagein interfaceAbstractNumberFieldI18nReturns:
the error message or
nullif not setSee Also:
-
setStepErrorMessage
Sets the error message to display when the field value is not a multiple of the step value.
Note, custom error messages set with
NumberField.setErrorMessage(String)take priority over i18n error messages.Parameters:
errorMessage- the error message to set, ornullto clearReturns:
this instance for method chaining
See Also:
-