@Singleton public class ObjectNodeToConvertibleValuesConverter extends Object implements TypeConverter<com.fasterxml.jackson.databind.node.ObjectNode,ConvertibleValues>
ObjectNode to a ConvertibleValues instance.| Constructor and Description |
|---|
ObjectNodeToConvertibleValuesConverter(ConversionService<?> conversionService) |
| Modifier and Type | Method and Description |
|---|---|
Optional<ConvertibleValues> |
convert(com.fasterxml.jackson.databind.node.ObjectNode object,
Class<ConvertibleValues> targetType,
ConversionContext context)
Converts from the given source object type to the target type.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitconvert, ofpublic ObjectNodeToConvertibleValuesConverter(ConversionService<?> conversionService)
conversionService - To convert from JSON node to a ConvertibleValues instancepublic Optional<ConvertibleValues> convert(com.fasterxml.jackson.databind.node.ObjectNode object, Class<ConvertibleValues> targetType, ConversionContext context)
TypeConverterOptional.empty()
in case the object is not convertible by catching any necessary exceptions and failing gracefully.convert in interface TypeConverter<com.fasterxml.jackson.databind.node.ObjectNode,ConvertibleValues>object - The object typetargetType - The target type being converted tocontext - The ConversionContext