public interface ConverterRegistry
Modifier and Type | Method and Description |
---|---|
void |
addConverter(java.lang.Class<?> sourceType,
java.lang.Class<?> targetType,
Converter<?,?> converter)
Add a plain converter to this registry.
|
void |
addConverter(Converter<?,?> converter)
Add a plain converter to this registry.
|
void |
addConverter(GenericConverter converter)
Add a generic converter to this registry.
|
void |
addConverterFactory(ConverterFactory<?,?> factory)
Add a ranged converter factory to this registry.
|
void |
removeConvertible(java.lang.Class<?> sourceType,
java.lang.Class<?> targetType)
Remove any converters from
sourceType to targetType . |
void addConverter(Converter<?,?> converter)
java.lang.IllegalArgumentException
- if the parameterized types could not be resolvedvoid addConverter(java.lang.Class<?> sourceType, java.lang.Class<?> targetType, Converter<?,?> converter)
Allows for a Converter to be reused for multiple distinct pairs without having to create a Converter class for each pair.
void addConverter(GenericConverter converter)
void addConverterFactory(ConverterFactory<?,?> factory)
java.lang.IllegalArgumentException
- if the parameterized types could not be resolvedvoid removeConvertible(java.lang.Class<?> sourceType, java.lang.Class<?> targetType)
sourceType
to targetType
.sourceType
- the source typetargetType
- the target typeCopyright © 2021. All rights reserved.