public class DesignLocalDateConverter extends Object implements Converter<String,LocalDate>
LocalDate
converter to be used by DesignAttributeHandler
.
Provides ISO-compliant way of storing date and time.Constructor and Description |
---|
DesignLocalDateConverter() |
Modifier and Type | Method and Description |
---|---|
Result<LocalDate> |
convertToModel(String value,
ValueContext context)
Converts the given value from model type to presentation type.
|
String |
convertToPresentation(LocalDate value,
ValueContext context)
Converts the given value from presentation type to model type.
|
public Result<LocalDate> convertToModel(String value, ValueContext context)
Converter
A converter can optionally use locale to do the conversion.
convertToModel
in interface Converter<String,LocalDate>
value
- The value to convert. Can be nullcontext
- The value context for the conversion.public String convertToPresentation(LocalDate value, ValueContext context)
Converter
A converter can optionally use locale to do the conversion.
convertToPresentation
in interface Converter<String,LocalDate>
value
- The value to convert. Can be nullcontext
- The value context for the conversion.Copyright © 2023 Vaadin Ltd. All rights reserved.