public abstract class AbstractBeanJsonDeserializer<T,B extends InstanceBuilder<T>> extends JsonDeserializer<T>
JsonDeserializer for beans.| Constructor and Description |
|---|
AbstractBeanJsonDeserializer() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addIgnoredProperty(String propertyName)
Add an ignored property
|
protected void |
addProperty(String referenceName,
BackReferenceProperty<T,?> backReference)
Add a
BackReferenceProperty |
protected void |
addProperty(String propertyName,
BeanPropertyDeserializer<T,B,?> deserializer)
Add a
BeanPropertyDeserializer |
T |
deserializeObject(JsonReader reader,
JsonDeserializationContext ctx)
Deserializes all the properties of the bean.
|
T |
deserializeSubtype(JsonReader reader,
JsonDeserializationContext ctx,
String typeInfo) |
T |
doDeserialize(JsonReader reader,
JsonDeserializationContext ctx)
Deserializes a non-null JSON input into an object.
|
protected IdentityDeserializationInfo<?> |
getIdentityInfo() |
protected SuperclassDeserializationInfo<T> |
getSuperclassInfo() |
protected abstract boolean |
isInstantiable() |
protected abstract B |
newInstanceBuilder(JsonDeserializationContext ctx) |
void |
setBackReference(String referenceName,
Object reference,
T value,
JsonDeserializationContext ctx)
Set the back reference.
|
protected void |
setIdentityInfo(IdentityDeserializationInfo<?> identityInfo) |
protected void |
setSuperclassInfo(SuperclassDeserializationInfo<T> superclassInfo) |
deserializeprotected abstract boolean isInstantiable()
protected abstract B newInstanceBuilder(JsonDeserializationContext ctx)
protected void addProperty(String propertyName, BeanPropertyDeserializer<T,B,?> deserializer)
BeanPropertyDeserializerpropertyName - name of the propertydeserializer - deserializerprotected void addProperty(String referenceName, BackReferenceProperty<T,?> backReference)
BackReferencePropertyreferenceName - name of the referencebackReference - backReferenceprotected void addIgnoredProperty(String propertyName)
propertyName - name of the propertypublic T doDeserialize(JsonReader reader, JsonDeserializationContext ctx) throws IOException
JsonDeserializerdoDeserialize in class JsonDeserializer<T>reader - JsonReader used to read the JSON inputctx - Context for the full deserialization processIOException - if an error occurs reading the inputpublic final T deserializeObject(JsonReader reader, JsonDeserializationContext ctx) throws IOException
JsonReader must be in a json object.reader - readerctx - context of the deserialization processIOException - if an error occurs while reading a propertypublic final T deserializeSubtype(JsonReader reader, JsonDeserializationContext ctx, String typeInfo) throws IOException
IOExceptionpublic void setBackReference(String referenceName, Object reference, T value, JsonDeserializationContext ctx)
JsonDeserializersetBackReference in class JsonDeserializer<T>referenceName - name of the referencereference - reference to setvalue - value to set the reference to.ctx - Context for the full deserialization processJsonBackReferenceprotected final IdentityDeserializationInfo<?> getIdentityInfo()
protected final void setIdentityInfo(IdentityDeserializationInfo<?> identityInfo)
protected final SuperclassDeserializationInfo<T> getSuperclassInfo()
protected final void setSuperclassInfo(SuperclassDeserializationInfo<T> superclassInfo)
Copyright © 2013. All Rights Reserved.