org.codehaus.jackson.map.deser
Class SettableBeanProperty
java.lang.Object
org.codehaus.jackson.map.deser.SettableBeanProperty
public final class SettableBeanProperty
- extends java.lang.Object
Class that represents a single settable property of a bean: contains
both type and name definitions, and reflection-based set functionality
|
Constructor Summary |
SettableBeanProperty(java.lang.String propName,
JavaType type,
java.lang.reflect.Method setter,
java.lang.reflect.Method getter)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
_valueDeserializer
protected JsonDeserializer<java.lang.Object> _valueDeserializer
_nullValue
protected java.lang.Object _nullValue
- Value to be used when 'null' literal is encountered in Json.
For most types simply Java null, but for primitive types must
be a non-null value (like Integer.valueOf(0) for int).
SettableBeanProperty
public SettableBeanProperty(java.lang.String propName,
JavaType type,
java.lang.reflect.Method setter,
java.lang.reflect.Method getter)
setValueDeserializer
public void setValueDeserializer(JsonDeserializer<java.lang.Object> deser)
getPropertyName
public java.lang.String getPropertyName()
getType
public JavaType getType()
hasValueDeserializer
public boolean hasValueDeserializer()
deserializeAndSet
public final void deserializeAndSet(JsonParser jp,
DeserializationContext ctxt,
java.lang.Object instance)
throws java.io.IOException,
JsonProcessingException
- Method called to deserialize appropriate value, given parser (and
context), and set it using appropriate method (a setter method).
- Throws:
java.io.IOException
JsonProcessingException
deserialize
public final java.lang.Object deserialize(JsonParser jp,
DeserializationContext ctxt)
throws java.io.IOException,
JsonProcessingException
- Throws:
java.io.IOException
JsonProcessingException
set
public final void set(java.lang.Object instance,
java.lang.Object value)
throws java.io.IOException
- Throws:
java.io.IOException
_throwAsIOE
protected void _throwAsIOE(java.lang.Exception e,
java.lang.Object value)
throws java.io.IOException
- Method that takes in exception of any type, and casts or wraps it
to an IOException or its subclass.
- Throws:
java.io.IOException
_throwAsIOE
protected java.io.IOException _throwAsIOE(java.lang.Exception e)
throws java.io.IOException
- Throws:
java.io.IOException
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Object