public class InvalidFormatException extends MismatchedInputException
MismatchedInputException
that is used when the underlying problem appears to be that
of bad formatting of a value to deserialize.JsonMappingException.Reference
Modifier and Type | Field and Description |
---|---|
protected Object |
_value
Underlying value that could not be deserialized into
target type, if available.
|
_targetType
_path, _processor
Constructor and Description |
---|
InvalidFormatException(com.fasterxml.jackson.core.JsonParser p,
String msg,
Object value,
Class<?> targetType) |
InvalidFormatException(String msg,
com.fasterxml.jackson.core.JsonLocation loc,
Object value,
Class<?> targetType)
Deprecated.
Since 2.7 Use variant that takes
JsonParser |
InvalidFormatException(String msg,
Object value,
Class<?> targetType)
Deprecated.
Since 2.7 Use variant that takes
JsonParser |
Modifier and Type | Method and Description |
---|---|
static InvalidFormatException |
from(com.fasterxml.jackson.core.JsonParser p,
String msg,
Object value,
Class<?> targetType) |
Object |
getValue()
Accessor for checking source value (String, Number usually) that could not
be deserialized into target type (
MismatchedInputException.getTargetType() ). |
from, from, from, getTargetType, setTargetType
_appendPathDesc, _buildMessage, from, from, from, from, from, from, from, fromUnexpectedIOE, getLocalizedMessage, getMessage, getPath, getPathReference, getPathReference, getProcessor, prependPath, prependPath, prependPath, toString, withCause, wrapWithPath, wrapWithPath, wrapWithPath
clearLocation, getLocation, getMessageSuffix, getOriginalMessage
addSuppressed, fillInStackTrace, getCause, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
protected final Object _value
@Deprecated public InvalidFormatException(String msg, Object value, Class<?> targetType)
JsonParser
@Deprecated public InvalidFormatException(String msg, com.fasterxml.jackson.core.JsonLocation loc, Object value, Class<?> targetType)
JsonParser
public static InvalidFormatException from(com.fasterxml.jackson.core.JsonParser p, String msg, Object value, Class<?> targetType)
public Object getValue()
MismatchedInputException.getTargetType()
).
Note that value may not be available, depending on who throws the exception
and when.Copyright © 2008–2024 FasterXML. All rights reserved.