- All Known Implementing Classes:
DefaultConverterProvider
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A
ConverterProvider provides Converter implementations
for any combination of types <T> and
<U>.
ConverterProvider can be used together with
RecordMapper, e.g. when mapping JSON or XML data
types onto POJO types using third party libraries like Jackson, Gson, JAXB,
or others.
The general expectation is for a ConverterProvider to be side-effect
free. Two calls to provide(Class, Class) should always produce the
same Converter logic and thus conversion behaviour, irrespective of
context, other than the Configuration that hosts the
Configuration.converterProvider(). This effectively means that it is
possible for jOOQ to cache the outcome of a provide(Class, Class)
call within the context of a Configuration or any derived context,
such as an ExecuteContext, to greatly improve performance.
- Author:
- Lukas Eder
-
Method Summary
-
Method Details
-
provide
Provide a converter that can convert between<T>and<U>types.- Returns:
- The converter for
<T, U>, ornullif no such converter could be provided, in case of which jOOQ'sDefaultConverterProviderapplies.
-