Class DateTimePicker.DateTimePickerI18n
- All Implemented Interfaces:
Serializable
- Enclosing class:
- DateTimePicker
DateTimePicker
.- 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 typeLocalDateTime
.Gets the aria-label suffix for the date picker.Gets the error message displayed when the selected date and time are later than the maximum allowed date and time.Gets the error message displayed when the selected date and time are earlier than the minimum allowed date and time.Gets the error message displayed when the field is required but empty.Gets the aria-label suffix for the time picker.setBadInputErrorMessage
(String errorMessage) Sets the error message to display when the field contains user input that the server is unable to convert to typeLocalDateTime
.setDateLabel
(String dateLabel) Sets the aria-label suffix for the date picker.setMaxErrorMessage
(String errorMessage) Sets the error message to display when the selected date and time are later than the maximum allowed date and time.setMinErrorMessage
(String errorMessage) Sets the error message to display when the selected date and time are earlier than the minimum allowed time.setRequiredErrorMessage
(String errorMessage) Sets the error message to display when the field is required but empty.setTimeLabel
(String timeLabel) Sets the aria-label suffix for the time picker.
-
Constructor Details
-
DateTimePickerI18n
public DateTimePickerI18n()
-
-
Method Details
-
getDateLabel
Gets the aria-label suffix for the date picker.The date picker's final aria-label is a concatanation of the DateTimePicker's
DateTimePicker.getAriaLabel()
orDateTimePicker.getLabel()
methods and this suffix.- Returns:
- the value used as a suffix in the date picker aria-label.
-
setDateLabel
Sets the aria-label suffix for the date picker.The date picker's final aria-label is a concatanation of the DateTimePicker's
DateTimePicker.getAriaLabel()
orDateTimePicker.getLabel()
methods and this suffix.- Parameters:
dateLabel
- the value to be used as a suffix in the date picker aria-label.- Returns:
- this instance for method chaining
-
getTimeLabel
Gets the aria-label suffix for the time picker.The time picker's aria-label is a concatanation of the DateTimePicker's
DateTimePicker.getAriaLabel()
orDateTimePicker.getLabel()
methods and this suffix.- Returns:
- the value used as a suffix in the time picker aria-label.
-
setTimeLabel
Sets the aria-label suffix for the time picker.The time picker's aria-label is a concatanation of the DateTimePicker's
DateTimePicker.getAriaLabel()
orDateTimePicker.getLabel()
methods and this suffix.- Parameters:
timeLabel
- the value to be used as a suffix in the time picker aria-label.- Returns:
- this instance for method chaining
-
getBadInputErrorMessage
Gets the error message displayed when the field contains user input that the server is unable to convert to typeLocalDateTime
.- Returns:
- the error message or
null
if not set
-
setBadInputErrorMessage
Sets the error message to display when the field contains user input that the server is unable to convert to typeLocalDateTime
.Note, custom error messages set with
HasValidationProperties.setErrorMessage(String)
take priority over i18n error messages.- Parameters:
errorMessage
- the error message to set, ornull
to clear- Returns:
- this instance for method chaining
-
getRequiredErrorMessage
Gets the error message displayed when the field is required but empty.- Returns:
- the error message or
null
if not set - See Also:
-
setRequiredErrorMessage
Sets the error message to display when the field is required but empty.Note, custom error messages set with
HasValidationProperties.setErrorMessage(String)
take priority over i18n error messages.- Parameters:
errorMessage
- the error message ornull
to clear it- Returns:
- this instance for method chaining
- See Also:
-
getMinErrorMessage
Gets the error message displayed when the selected date and time are earlier than the minimum allowed date and time.- Returns:
- the error message or
null
if not set - See Also:
-
setMinErrorMessage
Sets the error message to display when the selected date and time are earlier than the minimum allowed time.Note, custom error messages set with
HasValidationProperties.setErrorMessage(String)
take priority over i18n error messages.- Parameters:
errorMessage
- the error message ornull
to clear it- Returns:
- this instance for method chaining
- See Also:
-
getMaxErrorMessage
Gets the error message displayed when the selected date and time are later than the maximum allowed date and time.- Returns:
- the error message or
null
if not set - See Also:
-
setMaxErrorMessage
Sets the error message to display when the selected date and time are later than the maximum allowed date and time.Note, custom error messages set with
HasValidationProperties.setErrorMessage(String)
take priority over i18n error messages.- Parameters:
errorMessage
- the error message ornull
to clear it- Returns:
- this instance for method chaining
- See Also:
-