Package io.micronaut.json.bind
Interface JsonBeanPropertyBinderExceptionHandler
@Internal
public interface JsonBeanPropertyBinderExceptionHandler
Exception handler interface that converts json binding exceptions to more specific
ConversionErrorExceptions.- Since:
- 3.1
-
Method Summary
Modifier and TypeMethodDescriptionOptional<io.micronaut.core.convert.exceptions.ConversionErrorException>toConversionError(@Nullable Object object, @NonNull Exception e) Attempt to convert the given exception to aConversionErrorException.
-
Method Details
-
toConversionError
Optional<io.micronaut.core.convert.exceptions.ConversionErrorException> toConversionError(@Nullable @Nullable Object object, @NonNull @NonNull Exception e) Attempt to convert the given exception to aConversionErrorException.- Parameters:
object- The object that was supposed to be updated, ornull.e- The exception that occurred during mapping.- Returns:
- The conversion error, or an empty value if default handling should be used.
-