Package org.codehaus.jackson.map.exc
Class UnrecognizedPropertyException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.io.IOException
-
- org.codehaus.jackson.JsonProcessingException
-
- org.codehaus.jackson.map.JsonMappingException
-
- org.codehaus.jackson.map.exc.UnrecognizedPropertyException
-
- All Implemented Interfaces:
java.io.Serializable
public class UnrecognizedPropertyException extends JsonMappingException
SpecializedJsonMappingException
sub-class specifically used to indicate problems due to encountering a JSON property that could not be mapped to an Object property (via getter, constructor argument or field).- Since:
- 1.6
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.codehaus.jackson.map.JsonMappingException
JsonMappingException.Reference
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.Class<?>
_referringClass
Class that does not contain mapping for the unrecognized property.protected java.lang.String
_unrecognizedPropertyName
Note: redundant information since it is also included in the reference path.-
Fields inherited from class org.codehaus.jackson.map.JsonMappingException
_path
-
Fields inherited from class org.codehaus.jackson.JsonProcessingException
mLocation
-
-
Constructor Summary
Constructors Constructor Description UnrecognizedPropertyException(java.lang.String msg, JsonLocation loc, java.lang.Class<?> referringClass, java.lang.String propName)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static UnrecognizedPropertyException
from(JsonParser jp, java.lang.Object fromObjectOrClass, java.lang.String propertyName)
java.lang.Class<?>
getReferringClass()
Method for accessing type (class) that is missing definition to allow binding of the unrecognized property.java.lang.String
getUnrecognizedPropertyName()
Convenience method for accessing logical property name that could not be mapped.-
Methods inherited from class org.codehaus.jackson.map.JsonMappingException
_appendPathDesc, from, from, getMessage, getPath, prependPath, prependPath, prependPath, toString, wrapWithPath, wrapWithPath, wrapWithPath
-
Methods inherited from class org.codehaus.jackson.JsonProcessingException
getLocation
-
-
-
-
Field Detail
-
_referringClass
protected final java.lang.Class<?> _referringClass
Class that does not contain mapping for the unrecognized property.
-
_unrecognizedPropertyName
protected final java.lang.String _unrecognizedPropertyName
Note: redundant information since it is also included in the reference path.
-
-
Constructor Detail
-
UnrecognizedPropertyException
public UnrecognizedPropertyException(java.lang.String msg, JsonLocation loc, java.lang.Class<?> referringClass, java.lang.String propName)
-
-
Method Detail
-
from
public static UnrecognizedPropertyException from(JsonParser jp, java.lang.Object fromObjectOrClass, java.lang.String propertyName)
-
getReferringClass
public java.lang.Class<?> getReferringClass()
Method for accessing type (class) that is missing definition to allow binding of the unrecognized property.
-
getUnrecognizedPropertyName
public java.lang.String getUnrecognizedPropertyName()
Convenience method for accessing logical property name that could not be mapped. Note that it is the last path reference in the underlying path.
-
-