Interface Converter<T>

Type Parameters:
T - the target type this converter converts to
All Known Implementing Classes:
BigDecimalConverter, BigIntegerConverter, BooleanConverter, ByteConverter, BytesConverter, CharConverter, DateConverter, DoubleConverter, FloatConverter, InstantConverter, IntegerConverter, LocalDateConverter, LocalDateTimeConverter, LongConverter, ShortConverter, ZonedDateTimeConverter
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface Converter<T>
Converts a value from any type to the target type T.
  • Method Summary

    Modifier and Type
    Method
    Description
    convert(Object value)
    Converts the given value to the target type.
  • Method Details

    • convert

      T convert(Object value) throws ConversionException
      Converts the given value to the target type.
      Parameters:
      value - the value to convert
      Returns:
      the converted value of type T
      Throws:
      ConversionException - if the value cannot be converted