public abstract class TransformStrategy extends MLog
Abstract TransformStrategy class.
| Constructor and Description |
|---|
TransformStrategy() |
| Modifier and Type | Method and Description |
|---|---|
Object |
jsonToPojo(org.codehaus.jackson.JsonNode node)
jsonToPojo.
|
Object |
jsonToPojo(org.codehaus.jackson.JsonNode node,
Class<?> type)
jsonToPojo.
|
abstract Object |
jsonToPojo(org.codehaus.jackson.JsonNode node,
Class<?> type,
TransformHelper helper)
Transform the json into an object, some implementations need a type hint to create the object.
|
org.codehaus.jackson.JsonNode |
pojoToJson(Object obj)
pojoToJson.
|
abstract org.codehaus.jackson.JsonNode |
pojoToJson(Object obj,
TransformHelper helper)
Transform an object into an json representation.
|
public Object jsonToPojo(org.codehaus.jackson.JsonNode node) throws NotSupportedException
jsonToPojo.
node - a JsonNode object.Object object.NotSupportedException - if any.public Object jsonToPojo(org.codehaus.jackson.JsonNode node, Class<?> type) throws NotSupportedException
jsonToPojo.
node - a JsonNode object.type - a Class object.Object object.NotSupportedException - if any.public abstract Object jsonToPojo(org.codehaus.jackson.JsonNode node, Class<?> type, TransformHelper helper) throws NotSupportedException
node - The object datatype - The type hint, can also be null. If this is not supportet throw the exceptionhelper - The helper to create objectsNotSupportedException - Thrown if the object could not be created.public org.codehaus.jackson.JsonNode pojoToJson(Object obj) throws NotSupportedException
pojoToJson.
obj - a Object object.JsonNode object.NotSupportedException - if any.public abstract org.codehaus.jackson.JsonNode pojoToJson(Object obj, TransformHelper helper) throws NotSupportedException
obj - The object to transformhelper - a TransformHelper object.NotSupportedException - if any.Copyright © 2016. All Rights Reserved.