|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.codehaus.jackson.map.DeserializationContext
org.codehaus.jackson.map.deser.StdDeserializationContext
public class StdDeserializationContext
Default implementation of DeserializationContext.
| Field Summary | |
|---|---|
protected ArrayBuilders |
_arrayBuilders
|
protected DateFormat |
_dateFormat
|
protected ObjectBuffer |
_objectBuffer
|
protected JsonParser |
_parser
|
| Fields inherited from class org.codehaus.jackson.map.DeserializationContext |
|---|
_config |
| Constructor Summary | |
|---|---|
StdDeserializationContext(DeserializationConfig config,
JsonParser jp)
|
|
| Method Summary | |
|---|---|
protected String |
_calcName(Class<?> cls)
|
protected String |
_desc(String desc)
|
protected String |
_valueDesc()
|
Calendar |
constructCalendar(Date d)
|
protected String |
determineClassName(Object instance)
|
ArrayBuilders |
getArrayBuilders()
Method for accessing object useful for building arrays of primitive types (such as int[]). |
protected DateFormat |
getDateFormat()
|
JsonParser |
getParser()
Accessor for getting access to the underlying JSON parser used for deserialization. |
JsonMappingException |
instantiationException(Class<?> instClass,
Exception e)
Helper method for constructing instantiation exception for specified type, to indicate problem with physically constructing instance of specified class (missing constructor, exception from constructor) |
ObjectBuffer |
leaseObjectBuffer()
Method that can be used to get access to a reusable ObjectBuffer, useful for efficiently constructing Object arrays and Lists. |
JsonMappingException |
mappingException(Class<?> targetClass)
Helper method for constructing generic mapping exception for specified type |
Date |
parseDate(String dateStr)
|
void |
returnObjectBuffer(ObjectBuffer buf)
Method to call to return object buffer previously leased with DeserializationContext.leaseObjectBuffer(). |
JsonMappingException |
unknownFieldException(Object instanceOrClass,
String fieldName)
Helper method for constructing exception to indicate that JSON Object field name did not map to a known property of type being deserialized. |
JsonMappingException |
weirdKeyException(Class<?> keyClass,
String keyValue,
String msg)
Helper method for constructing exception to indicate that given JSON Object field name was not in format to be able to deserialize specified key type. |
JsonMappingException |
weirdNumberException(Class<?> instClass,
String msg)
Helper method for constructing exception to indicate that input JSON Number was not suitable for deserializing into given type. |
JsonMappingException |
weirdStringException(Class<?> instClass,
String msg)
Method that will construct an exception suitable for throwing when some String values are acceptable, but the one encountered is not |
| Methods inherited from class org.codehaus.jackson.map.DeserializationContext |
|---|
getBase64Variant, getConfig, isEnabled |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final JsonParser _parser
protected ArrayBuilders _arrayBuilders
protected ObjectBuffer _objectBuffer
protected DateFormat _dateFormat
| Constructor Detail |
|---|
public StdDeserializationContext(DeserializationConfig config,
JsonParser jp)
| Method Detail |
|---|
public JsonParser getParser()
DeserializationContext
getParser in class DeserializationContextpublic final ObjectBuffer leaseObjectBuffer()
DeserializationContext
leaseObjectBuffer in class DeserializationContextpublic final void returnObjectBuffer(ObjectBuffer buf)
DeserializationContextDeserializationContext.leaseObjectBuffer().
returnObjectBuffer in class DeserializationContextbuf - Returned object bufferpublic final ArrayBuilders getArrayBuilders()
DeserializationContext
getArrayBuilders in class DeserializationContext
public Date parseDate(String dateStr)
throws IllegalArgumentException
parseDate in class DeserializationContextIllegalArgumentExceptionpublic Calendar constructCalendar(Date d)
constructCalendar in class DeserializationContextpublic JsonMappingException mappingException(Class<?> targetClass)
DeserializationContext
mappingException in class DeserializationContextprotected String _calcName(Class<?> cls)
public JsonMappingException instantiationException(Class<?> instClass,
Exception e)
DeserializationContext
instantiationException in class DeserializationContext
public JsonMappingException weirdStringException(Class<?> instClass,
String msg)
weirdStringException in class DeserializationContext
public JsonMappingException weirdNumberException(Class<?> instClass,
String msg)
DeserializationContext
weirdNumberException in class DeserializationContext
public JsonMappingException weirdKeyException(Class<?> keyClass,
String keyValue,
String msg)
DeserializationContext
weirdKeyException in class DeserializationContext
public JsonMappingException unknownFieldException(Object instanceOrClass,
String fieldName)
DeserializationContext
unknownFieldException in class DeserializationContextinstanceOrClass - Either value being populated (if one has been
instantiated), or Class that indicates type that would be (or
have been) instantiatedprotected String determineClassName(Object instance)
protected DateFormat getDateFormat()
protected String _valueDesc()
protected String _desc(String desc)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||