Package jadex.extension.rs.publish.json
Class JsonResponseProcessor
- java.lang.Object
-
- jadex.transformation.jsonserializer.processors.AbstractJsonProcessor
-
- jadex.extension.rs.publish.json.JsonResponseProcessor
-
- All Implemented Interfaces:
ITraverseProcessor
public class JsonResponseProcessor extends jadex.transformation.jsonserializer.processors.AbstractJsonProcessor
jax.rs.Response processor.
-
-
Constructor Summary
Constructors Constructor Description JsonResponseProcessor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
isApplicable(java.lang.Object object, java.lang.reflect.Type type, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonReadContext context)
Test if the processor is applicable for reading.protected boolean
isApplicable(java.lang.Object object, java.lang.reflect.Type type, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonWriteContext context)
Test if the processor is applicable for writing.protected java.lang.Object
readObject(java.lang.Object object, java.lang.reflect.Type type, Traverser traverser, java.util.List<ITraverseProcessor> conversionprocessors, java.util.List<ITraverseProcessor> processors, IStringConverter converter, Traverser.MODE mode, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonReadContext context)
Read an object.protected java.lang.Object
writeObject(java.lang.Object object, java.lang.reflect.Type type, Traverser traverser, java.util.List<ITraverseProcessor> conversionprocessors, java.util.List<ITraverseProcessor> processors, IStringConverter converter, Traverser.MODE mode, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonWriteContext context)
Write an object.
-
-
-
Method Detail
-
isApplicable
protected boolean isApplicable(java.lang.Object object, java.lang.reflect.Type type, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonReadContext context)
Test if the processor is applicable for reading.- Specified by:
isApplicable
in classjadex.transformation.jsonserializer.processors.AbstractJsonProcessor
- Parameters:
object
- The object.targetcl
- If not null, the traverser should make sure that the result object is compatible with the class loader, e.g. by cloning the object using the class loaded from the target class loader.- Returns:
- True, if is applicable.
-
isApplicable
protected boolean isApplicable(java.lang.Object object, java.lang.reflect.Type type, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonWriteContext context)
Test if the processor is applicable for writing.- Specified by:
isApplicable
in classjadex.transformation.jsonserializer.processors.AbstractJsonProcessor
- Parameters:
object
- The object.targetcl
- If not null, the traverser should make sure that the result object is compatible with the class loader, e.g. by cloning the object using the class loaded from the target class loader.- Returns:
- True, if is applicable.
-
readObject
protected java.lang.Object readObject(java.lang.Object object, java.lang.reflect.Type type, Traverser traverser, java.util.List<ITraverseProcessor> conversionprocessors, java.util.List<ITraverseProcessor> processors, IStringConverter converter, Traverser.MODE mode, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonReadContext context)
Read an object.- Specified by:
readObject
in classjadex.transformation.jsonserializer.processors.AbstractJsonProcessor
- Parameters:
object
- The object.targetcl
- If not null, the traverser should make sure that the result object is compatible with the class loader, e.g. by cloning the object using the class loaded from the target class loader.- Returns:
- The processed object.
-
writeObject
protected java.lang.Object writeObject(java.lang.Object object, java.lang.reflect.Type type, Traverser traverser, java.util.List<ITraverseProcessor> conversionprocessors, java.util.List<ITraverseProcessor> processors, IStringConverter converter, Traverser.MODE mode, java.lang.ClassLoader targetcl, jadex.transformation.jsonserializer.processors.JsonWriteContext context)
Write an object.- Specified by:
writeObject
in classjadex.transformation.jsonserializer.processors.AbstractJsonProcessor
- Parameters:
object
- The object.targetcl
- If not null, the traverser should make sure that the result object is compatible with the class loader, e.g. by cloning the object using the class loaded from the target class loader.- Returns:
- The processed object.
-
-